Re: ERR Protocol error: expected '$', got '

1,300 views
Skip to first unread message

Jonathan Leibiusky

unread,
Jul 5, 2012, 7:01:43 AM7/5/12
to jedis...@googlegroups.com
It seems like there is a connection problem between your application and redis.
We need a way to reproduce this, so we can check where and what is the problem.

On Sat, Jun 30, 2012 at 3:04 AM, Lucas Nicodemus <jetbla...@gmail.com> wrote:
redis.clients.jedis.exceptions.JedisDataException: ERR Protocol error: expected '$', got '

      at redis.clients.jedis.Protocol.processError(Protocol.java:59)
      at redis.clients.jedis.Protocol.process(Protocol.java:66)
      at redis.clients.jedis.Protocol.read(Protocol.java:131)
      at redis.clients.jedis.Connection.getObjectMultiBulkReply(Connection.java:206)
      at redis.clients.jedis.JedisPubSub.process(JedisPubSub.java:88)
      at redis.clients.jedis.JedisPubSub.proceed(JedisPubSub.java:83)
      at redis.clients.jedis.Jedis.subscribe(Jedis.java:1971)
 
(followed by)

redis.clients.jedis.exceptions.JedisConnectionException: It seems like server has closed the connection

      at redis.clients.util.RedisInputStream.readLine(RedisInputStream.java:90)
      at redis.clients.jedis.Protocol.processError(Protocol.java:58)
      at redis.clients.jedis.Protocol.process(Protocol.java:66)
      at redis.clients.jedis.Protocol.read(Protocol.java:131)
      at redis.clients.jedis.Connection.getObjectMultiBulkReply(Connection.java:206)
      at redis.clients.jedis.JedisPubSub.process(JedisPubSub.java:88)
      at redis.clients.jedis.JedisPubSub.proceed(JedisPubSub.java:83)
      at redis.clients.jedis.Jedis.subscribe(Jedis.java:1971)
 

 I'm simply calling the subscribe function on a directly created Jedis instance. This only happens sporadically, though, and appears to have no correlation to anything I've done in code.

Things of note: I'm creating a Jedis object directly - not using the connection pool - because I know of no good way to subscribe to a channel through a JedisPool (and when attempted, I couldn't even get the JedisPool to connect to the instance itself).

Redis version: 2.4.15, though I've tried it on 2.2.15 and I can reproduce the same issue after literally terminating and starting the class again in the same sporadic fashion.
Jedis version: 2.1.0

Reply all
Reply to author
Forward
0 new messages