RE: Bearerbox is not shutting down on command.
Nisan Bloch <[email protected]>
| Newsgroups | gmane.comp.mobile.kannel.devel |
|---|---|
| Message-ID | <[email protected]> |
Hi 05:47 PM 8/19/02 +0300, Oded Arbel wrote: > >If I understand whats going on here, then something like this happens : >the bearerbox waits for sms/wap boxes to connect to it - firing a handler >thread for each box connecting. all handler threads of the same type share >a single message queue (incoming_sms in case of an smsbox). now, since the >bearerbox creates handler threads with abandon and does not collect their >ids or anything, there is never a notion of "all handler threads have >terminated". There is a dummy list "flow_threads", that has producers added to it at the start of a thread and producers removed from it at the end. Bearerbox, waits on these for shutdown (bearerbox.c:501) My guess is that it is one of the smsc modules that are not shutting down properly. Do you have debug logs of the shutdown process, which threads exit? Nisan >so if there's a message in the queue but nobody is alive that extracts >messages from the queue - the message will stay in the queue forever and >none will be the wiser. If we had a "consumer" count on a list as we have >a "producer", it would be easy to work around - when the consumer count >drops to 0 , and we are in shutdown state - clear the queue and go home. > >-- >Oded Arbel >m-Wise mobile solutions ><mailto:[email protected]>[email protected] > >+972-9-9581711 (116) >+972-67-340014 > >::.. >The Key to life is 'fast forward'. there are some bad parts in life, and >the trick is to 'fast forward' through them to the good parts. > -- Fishizm