def sendEvent(self):
     e = self.makeRandomEvent()
     message = e.dumps()
     RabbitMQ.sendMessage(message, RabbitMQ.exchange_event, e.ceType)
     print "sent", message
 def sendMessageHandler(self, item):
     message, exchange, key = item
     L.d2(message)
     RabbitMQ.sendMessage(message, exchange, key)
     del message
 def sendAnnotatedEventHandler(self, annotatedevent):
     key = self.getEventDescription().messagebus.routingKey
     message = annotatedevent.serialize(format='n3')
     RabbitMQ.sendMessage(message, self.exchange, key)