Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Getting Error from Redigo while job queuing #113

Open
shreyas-srinivas opened this issue Oct 15, 2018 · 2 comments
Open

Getting Error from Redigo while job queuing #113

shreyas-srinivas opened this issue Oct 15, 2018 · 2 comments

Comments

@shreyas-srinivas
Copy link

shreyas-srinivas commented Oct 15, 2018

I'm getting the following error while queuing jobs
redigo: bad response line terminator (possible server error or unsupported concurrent read by application)

I'm sure it cannot be because of concurrency as redispool is being used.
has anyone else faced this issue?

I'm using a sharded redis cluster from redis-labs. Initially, I was getting CROSS slot issue, so wrapped the namespace with curly braces. Now I'm facing this issue.

This error only comes when I use EnqueueUnique and EnqueueUniqueIn and does not occur when I use just Enqueue

@darkpssngr
Copy link

I figured out what the issue is. At least I think I did. Since UniqueJob serializes the map into a json string and append it with the key, there are flower braces in the key which makes the redis cluster consider that as a tag and results in a CROSS Slot error. But for some reason it does not propogate as a CROSS SLOT error. But I was able to reproduce the error after I ran the monitor command and tried the command that ran on the server.

I think the best way to solve this is to base64 encode the map data and use that in the key instead of the json string. Please let me know what your thoughts are on this?

@darkpssngr
Copy link

#93

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants