github redis/node-redis v.2.6.0

latest releases: redis@4.6.13, client@1.5.14, redis@4.6.12...
7 years ago

We proudly present:

Fixed pub sub, better error handling, camelCase and big number support, improved performance, fire and forget commands, bug fixes and more.

This is the combined changelog of all pre-releases of the 2.6 release plus the additional changes. If you want to see the individual changelogs, please have a look.

Features

  • Added name property to all Redis functions (Node.js >= 4.0)
  • Added support for the new CLIENT REPLY ON|OFF|SKIP command (Redis v.3.2)
  • Added support for camelCase
  • The Node.js landscape default is to use camelCase. node_redis is a bit out of the box here
    but from now on it is possible to use both, just as you prefer!
  • If there's any documented variable missing as camelCased, please open a issue for it
  • Improve error handling significantly
  • Improved stack traces in development and debug mode
  • Only emit an error if the error has not already been handled in a callback
  • Improved unspecific error messages e.g. "Connection gone from end / close event"
  • Added args to command errors to improve identification of the error
  • Added origin to errors if there's e.g. a connection error
  • Added ReplyError class. All Redis errors are from now on going to be of that class
  • Added AbortError class. A subclass of AbortError. All unresolved and by node_redis rejected commands are from now on of that class
  • Added AggregateError class. If a unresolved and by node_redis rejected command has no callback and
    this applies to more than a single command, the errors for the commands without callback are aggregated
    to a single error that is emitted in debug_mode in that case.
  • Added message_buffer / pmessage_buffer events. That event is always going to emit a buffer
  • Listening to the message event at the same time is always going to return the same message as string
  • Added callback option to the duplicate function
  • Monitor and pub sub mode now work together with the offline queue
  • All commands that were send after a connection loss are now going to be send after reconnecting
  • Activating monitor mode does now work together with arbitrary commands including pub sub mode
  • Pub sub mode is completly rewritten and all known issues fixed
  • Added string_numbers option to get back strings instead of numbers
  • Quit command is from now on always going to end the connection properly
  • Added type validations for client.send_command arguments
  • Updated redis-parser dependency (changelog)
  • The JS parser is from now on the new default as it is a lot faster than the hiredis parser
  • This is no BC as there is no changed behavior for the user at all but just a performance improvement. Explicitly requireing the Hiredis parser is still possible.
  • Updated redis-commands dependency (changelog)

Bugfixes

  • Fixed v.2.5.0 auth command regression (under special circumstances a reconnect would not authenticate properly)
  • Fixed special handled functions in batch and multi context not working the same as without (e.g. select and info)
  • Be aware that not all commands work in combination with transactions but they all work with batch
  • Fixed address always set to 127.0.0.1:6379 in case host / port is set in the tls options instead of the general options
  • Fixed client.send_command not working properly with every command and every option
  • Fixed pub sub mode unsubscribing from all channels not respected while reconnecting
  • Fixed pub sub mode events in combination with the string_numbers option emitting the number of channels not as number
  • Fixed calling monitor command while other commands are still running
  • Fixed monitor and pub sub mode not working together
  • Fixed monitor mode not working in combination with the offline queue
  • Fixed pub sub mode not working in combination with the offline queue
  • Fixed pub sub mode resubscribing not working with non utf8 buffer channels
  • Fixed pub sub mode crashing if calling unsubscribe / subscribe in various combinations
  • Fixed pub sub mode emitting unsubscribe even if no channels were unsubscribed
  • Fixed pub sub mode emitting a message without a message published
  • Fixed quit command not ending the connection and resulting in further reconnection if called while reconnecting

The quit command did not end connections earlier if the connection was down at that time and this could have
lead to strange situations, therefor this was fixed to end the connection right away in those cases.

Deprecations

  • The parser option is deprecated and should be removed. The built-in Javascript parser is a lot faster than the hiredis parser and has more features

Don't miss a new node-redis release

NewReleases is sending notifications on new releases.