1

I have various applications pushing messages into RabbitMQ and I want my sockjs-cyclone server to consume those messages and push them out to websocket clients. I'd like to use kombu as my RabbitMQ consumer library, but I can't figure out where to put my consumer and which parts of kombu's consumer interface I should use.

I am stuck on at least the following mental obstacles:

  • I apparently need to consume from inside of my SockJSConnection so that I have access to self.sendMessage
  • but I don't think I can use kombu's Connection.drain_events or SimpleQueue.get from anywhere in there because those are synchronous, blocking calls.

Is there a good way to integrate these two libraries?

CJ Gaconnet
  • 1,421
  • 1
  • 12
  • 18

0 Answers0