Bug 431928 - Clean shutdown of broker.
Clean shutdown of broker.
Status: CLOSED CURRENTRELEASE
Product: Red Hat Enterprise MRG
Classification: Red Hat
Component: qpid-cpp (Show other bugs)
beta
All Linux
medium Severity high
: ---
: ---
Assigned To: messaging-bugs
Kim van der Riet
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2008-02-07 16:04 EST by Alan Conway
Modified: 2009-05-07 16:09 EDT (History)
1 user (show)

See Also:
Fixed In Version: qpidd-0.2-24.el5, qpidc-0.2-24.el5, and rhm-0.2-18.el5
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2008-02-29 11:46:55 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Alan Conway 2008-02-07 16:04:43 EST
Description of problem:

src/qpidd.cpp defines a signal handler to shut down the broker, however
calling Broker::shutdown() directly from the handler is not async-signal safe.

The handler should push a shutdown event into the             
epoll poller (making sure to use only async-safe functions!)             
and let a poller thread actually do the shutdown.   

Requires extension of the Poller to allow polling for non-socket events,
e.g. allow arbitrary file descriptors.
Comment 1 Alan Conway 2008-02-07 16:31:36 EST
Better solution from astitcher: stopping the poller is async-signal safe, and
causes main() to return so the Broker dtor is called. Move all other shutdown
code (logging, management shutdown) to the broker dtor or to main() after
Broker::run()  
Comment 2 Mike Bonnet 2008-02-29 11:46:55 EST
Fixed in qpidd-0.2-24.el5, qpidc-0.2-24.el5, and rhm-0.2-18.el5

Note You need to log in before you can comment on or make changes to this bug.