#33 ✓hold
Jay Phillips

Call Threads waiting for with_next_message() hang indefinitely

Reported by Jay Phillips | August 29th, 2008 @ 02:12 AM

When a dialplan Thread is sleeping due to with_next_message(), a call hangup will NOT kill the Thread. The Thread stays alive for as long as the process does.

For the time being, this can be worked-around by manually catching hangups via AMI and sending a message to the dialplan which causes it to exit gracefully.

The framework-level solution I believe is to subclass the Queue class and use this custom subclass in for Call#inbox(). It will override the Queue#<<() method with an implementation that checks for the :cancel symbol and sets a property in the Queue subclass to disable any further use of with_next_message() by raising an exception. The :cancel message is still passed along to the Queue.

The documentation of with_next_message() (and its supporting methods) should mention that :cancel can be sent at any time.

Comments and changes to this ticket

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

Shared Ticket Bins

People watching this ticket

Attachments

Tags

Pages