8000 When a redis server drops an already established connection, it fails loudly · Issue #16 · getsentry/rb · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
8000
When a redis server drops an already established connection, it fails loudly #16
Open
@mattrobenolt

Description

@mattrobenolt

This can be tested by setting CONFIG SET timeout 1 in Redis, then running:

from time import sleep
from rb import Cluster

cluster = Cluster({0:{'host': '127.0.0.1', 'port': 6379}})

with cluster.map() as c:
    c.get('foo')

sleep(2)

with cluster.map() as c:
    c.get('foo')

Yells with redis.exceptions.ConnectionError: Error while trying to write requests to redis..

The problem is the first poll on the socket is a close event before any data has been written to the socket.

We should detect this and attempt to reconnect.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

    0