Skip to content

Instantly share code, notes, and snippets.

@rtau-t24
Created June 28, 2012 05:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rtau-t24/3009399 to your computer and use it in GitHub Desktop.
Save rtau-t24/3009399 to your computer and use it in GitHub Desktop.
Program hang when channel.close()
from __future__ import with_statement
from kombu.entity import Queue, Exchange
if __name__ == '__main__':
from kombu.connection import Connection
from tasks import hello_task
connection = Connection('pika://guest:guest@localhost:5672/')
print "Got connection"
channel=connection.channel()
print "Got channel"
channel.close()
print "Closed channel"
connection.release()
print "Closed connection"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment