Resolve "Rider location caching" #1063

Merged
jankstudio merged 8 commits from 180-rider-location-caching into master 2019-05-28 03:24:23 +00:00
Showing only changes of commit 9503089642 - Show all commits

View file

@ -12,14 +12,10 @@ import json
class RiderLocationCache(object):
def run(self):
global client, redis_conn
client = mqtt.Client()
client.on_connect = on_connect
# client.on_publish = on_publish
client.on_message = on_message
redis_conn = redis.StrictRedis(host='localhost', port=6379, db=0)
#client.tls_set(
# "/etc/letsencrypt/live/resqaws.jankstudio.com/fullchain.pem", cert_reqs=ssl.CERT_NONE,
# tls_version=ssl.PROTOCOL_TLSv1)
@ -36,6 +32,8 @@ class RiderLocationCache(object):
#signal.signal(signal.SIGINT, sigint_handler)
client.loop_forever()
client = mqtt.Client()
redis_conn = redis.StrictRedis(host='localhost', port=6379, db=0)
def init_subscriptions(client):
print "subscribing to wildcard"