示例#1
0
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)
示例#2
0
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)
示例#3
0
 def request(self, body):
     msg_request = Message("zeno_master_queue", "GPS", "Operation", body)
     producer.request(msg_request)
     consumer.reply(self.on_response)