def main(): # process GPS info producer.request(gps_info) print consumer.reply(__QUEUE__) # send msg # producer.request(send_data) # print consumer.reply(__QUEUE__, 60) # change config producer.request(set_new_config_a) print consumer.reply(__QUEUE__, 60)
def request(self, body): msg_request = Message("zeno_master_queue", "GPS", "Operation", body) producer.request(msg_request) consumer.reply(self.on_response)