Redis Client lettuce 3.1 Final released

This release introduces support for SSL, enables lambda expressions on streaming channels and a lot of bugfixes and resilience changes.
lettuce extensibility is improved. You can override certain parts of the client to supply classes (connection classes) that behave the way you need by extending RedisClient or RedisClusterClient.
You can reset the internal connection state in case you run into broken connections (invalid connection state due to SSL tunneling or others) by calling the reset() method on your connection.

lettuce is now built with Java 8 but can be used with Java 6, 7 and 8. Java 6 and 7 support will be dropped with lettuce 4.0. The new lettuce-testcontainer project ensures until then. You can find the build results at https://travis-ci.org/mp911de/lettuce-testcontainer

lettuce is also now on Gitter. If you need any support, meet lettuce at https://gitter.im/mp911de/lettuce

SSL Support

SSL support for Redis means that you need a Redis that is behind some SSL tunnel (mostly stunnel). You can use this feature with Java 6, 7 and 8. The only issue using Java 6 is that you won’t be able to verify the Redis host name against the SSL certificate. Redis with SSL works only in a sane way when you use standalone Redis. Sentinel and Redis Cluster provide host and port details, and since Redis has no out-of-the-box SSL support you would always connect to the unencrypted ports even your first connection to Sentinel or Cluster was encrypted.

SSL and StartTLS are supported; Client certificates are not supported.

See https://github.com/mp911de/lettuce/wiki/SSL-Connections for details on SSL connections.

Enhancements

  • Change build environment to JDK8 #49
  • Allows lambda expressions on streaming channels enhancement #47
  • JavaDoc compatibility with Java 8 #39
  • Add cluster commands: Readonly, and clusterNodes #38 (for standalone) (Thanks to @taer)
  • Add RedisFuture return to RedisPubSubConnection API enhancement #34
  • Provide API and visibility in order to extend RedisClient and its connections #33
  • SSL support enhancement and improved channel initialization #28
  • Allow reset on internal connection state enhancement #25
  • Enhance lettuce resilience enhancement #24
  • Add jsr305 annotation lib #45

Fixes

  • Fix synchronized issue enhancement #44 (Thanks to @taer)
  • RedisClusterConnection stops operation after #42 (Thanks to @taer)
  • Fix time conversion for timeout settings #36 (Thanks to @taer)
  • Pool return no longer nulls connection #35 (Thanks to @taer)
  • Fix Method Signature RedisClient.connectPubSub bug #23
  • Fix URL parsing #32

lettuce requires a minimum of Java 8 to build and Java 6 run. It is tested continuously against Redis 3.0.

Links

Maven coordinates:

<dependency>
    <groupId>biz.paluch.redis</groupId>
    <artifactId>lettuce</artifactId>
    <version>3.1.Final</version>
</dependency>

<dependency>
    <groupId>biz.paluch.redis</groupId>
    <artifactId>lettuce</artifactId>
    <version>3.1.Final</version>
    <classifier>shaded</classifier>
</dependency>

Any feedback is appreciated or create issues on GitHub.

You may also enjoy…