Skip to content
This repository was archived by the owner on Apr 3, 2019. It is now read-only.
This repository was archived by the owner on Apr 3, 2019. It is now read-only.

Stops publishing after a time #85

@davidmir

Description

@davidmir

Hi, I'm using tornado-redis to publish GPS locations (from a smartphone). It works fine, but after a time the messages stops to publish on Redis but the Tornado receives the message.
I'm using the SockJSSubscriber (for web browsers subscribers) and i'm connecting to Redis with a connection pool.

Connection Pool:
CONNECTION_POOL = tornadoredis.ConnectionPool(max_connections=10, wait_for_available=True)

Subscriber variable:
with tornadoredis.Client(host=settings.REDIS_HOST, port=settings.REDIS_PORT), connection_pool=CONNECTION_POOL) as conn:
self.subscriber = pubsub.SockJSSubscriber(conn)

Subscribe channel (Web browsers):
with tornadoredis.Client(host=settings.REDIS_HOST, port=settings.REDIS_PORT), connection_pool=CONNECTION_POOL) as conn:
self.subscriber.subscribe(self.channel, self)
self.subscribed = True

Publish to channel (Smartphones via websocket):
with tornadoredis.Client(host=settings.REDIS_HOST, port=settings.REDIS_PORT), connection_pool=CONNECTION_POOL) as conn:
self.subscriber.publish(self.channel_organization, post_data) //HERE! After a time this messages are not published to Redis

This problem can be a problem in my implementation? Or the connection to Redis can be broken and the client can no longer do publish messages?

Thanks in advance

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions