简体   繁体   中英

Getting response line error - Redigo Redis Client

I'm creating strings out of JSON serialized structs and running a PUBLISH command on a redis connection this this.

_, err := r.Do("PUBLISH", key, ncs)

This go service is used in to process/repurpose all of the messages that get sent on our chat application, and then pub sub the events back to the clients.

Every so often the redis connection spits an error after the doing a PUBLISH command and it's one of the following:

  • redigo: bad response line terminator
  • redigo: unexpected response line

Have not been able to make sense of these and the error keeps showing up, what do these responses mean? && why might they be occurring for me?

The application is accessing the connection concurrently. The allowed concurrency is discussed in the documentation . Consider using a pool .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM