Commit Graph

59 Commits

Author SHA1 Message Date
Mark Paluch
b0d139af2e DATAREDIS-665 - Upgrade to Lettuce 5.0 RC1.
Adapt to changes in Lettuce API.
2017-07-20 15:55:02 +02:00
Mark Paluch
54ba6e3494 DATAREDIS-663 - Inherit Project Reactor version from dependency management.
Adapt to BOM import in Spring Data Build pom.
2017-07-20 11:06:02 +02:00
Mark Paluch
475d1bbf41 DATAREDIS-646 - After release cleanups. 2017-06-14 17:14:08 +02:00
Mark Paluch
663bb4a182 DATAREDIS-646 - Prepare next development iteration. 2017-06-14 17:14:07 +02:00
Mark Paluch
55e055f8ea DATAREDIS-646 - Release version 2.0 M4 (Kay). 2017-06-14 17:03:48 +02:00
Mark Paluch
a468a2d43a DATAREDIS-646 - Prepare 2.0 M4 (Kay). 2017-06-14 17:03:00 +02:00
Mark Paluch
a403a530d3 DATAREDIS-574 - Introduce dedicated RedisClientConfiguration for Jedis & Lettuce.
We added Jedis-/LettuceClientConfiguration and mutable Jedis-/LettuceClientConfiguration to encapsulate Jedis/Lettuce specific client features. Those should be used for ConnectionFactory configuration.

Additionally we added RedisStandaloneConfiguration next to the existing configurations for Sentinel and Cluster.

Along the way we also removed superfluous test system properties and Gemfire specific hooks and truststore customization.

Original Pull Request: #236
2017-06-08 10:53:04 +02:00
Mark Paluch
45f1382e00 DATAREDIS-651 - Upgrade to Reactor 3.1 M2. 2017-06-01 10:03:07 +02:00
Mark Paluch
771c4d96da DATAREDIS-622 - After release cleanups. 2017-05-09 11:34:42 +02:00
Mark Paluch
24565a1632 DATAREDIS-622 - Prepare next development iteration. 2017-05-09 11:34:41 +02:00
Mark Paluch
ae2868cd11 DATAREDIS-622 - Release version 2.0 M3 (Kay). 2017-05-09 11:23:00 +02:00
Mark Paluch
7f22a6c434 DATAREDIS-622 - Prepare 2.0 M3 (Kay). 2017-05-09 11:22:12 +02:00
Mark Paluch
abea6fdef2 DATAREDIS-642 - Upgrade to Lettuce 5.0 M2. 2017-05-03 14:39:07 +02:00
Christoph Strobl
87d6aa2042 DATAREDIS-624 - Upgrade to Lettuce 5.0.0.BUILD-SNAPSHOT.
Upgrade to Lettuce using Reactor 3.1.0.BUILD-SNAPSHOT, requires change to io.lettuce:lettuce-core, so we also needed to change imports from com.lambdaworks.redis to io.lettuce.core.

Original pull request: #245.
2017-04-12 14:32:41 +02:00
Oliver Gierke
a09d0ba629 DATAREDIS-573 - After release cleanups. 2017-04-04 22:08:19 +02:00
Oliver Gierke
c7ea1f2c2b DATAREDIS-573 - Prepare next development iteration. 2017-04-04 22:08:16 +02:00
Oliver Gierke
03bc21edaa DATAREDIS-573 - Release version 2.0 M2 (Kay). 2017-04-04 21:12:35 +02:00
Oliver Gierke
9bcb4a9b36 DATAREDIS-573 - Prepare 2.0 M2 (Kay). 2017-04-04 21:12:02 +02:00
Mark Paluch
81657c530b DATAREDIS-602 - Provide Reactive Redis Template.
Add ReactiveRedisTemplate, add tests abd add SerializerFunction and DeserializerFunction for functional Redis argument serialization.

Introduce ReactiveRedisConnectionFactory and remove reactive RedisConnectionFactory methods to break the dependency to reactive types. We now no longer require Project Reactor for blocking Redis use. ReactiveRedisTemplate accepts ReactiveRedisConnectionFactory to operate on a reactive connection. The only implementation of ReactiveRedisConnectionFactory is LettuceConnectionFactory which requires by default Project Reactor.

Original Pull Request: #239
2017-04-03 18:30:48 +02:00
Christoph Strobl
f8eb3134e2 DATAREDIS-617 - Remove dependency to org.codehaus.jackson.
Remove already deprecated jackson 1 dependency and related RedisSerializer / HashMapper implementations.

Original pull request: #240.
2017-03-13 09:47:44 +01:00
Oliver Gierke
6322cf42bd DATAREDIS-568 - After release cleanups. 2016-11-23 10:59:11 +01:00
Oliver Gierke
b20943a8e8 DATAREDIS-568 - Prepare next development iteration. 2016-11-23 10:59:09 +01:00
Oliver Gierke
d866827e56 DATAREDIS-568 - Release version 2.0 M1 (Kay). 2016-11-23 10:35:49 +01:00
Oliver Gierke
39fcb5a93f DATAREDIS-568 - Prepare 2.0 M1 (Kay). 2016-11-23 10:35:09 +01:00
Oliver Gierke
7a7cca0de1 DATAREDIS-568 - Re-added release profile. 2016-11-23 10:33:20 +01:00
Mark Paluch
b172c237e4 DATAREDIS-525 - Polishing.
Enhance JavaDoc. Improve assertions. Reduce accepted collection-type boundary to Collection for commands that do not enforce a specific order. Add ByteUtil.getBytes(ByteBuffer) utility method. Reformat code. Extend documentation

Fix parameter ambiguity in LettuceConnection.watch().

Original pull request: #229.
2016-11-17 20:17:10 +01:00
Mark Paluch
62b1354e02 DATAREDIS-525 - Upgrade to lettuce 5.0.0.Beta1.
- Replace deprecated method usage by using newly introduced API.
- Improve converter names, remove unused code, fix generics.

Original pull request: #229.
2016-11-17 20:17:05 +01:00
Christoph Strobl
d257ae1074 DATAREDIS-525 - Add support for ReactiveRedisConnection & ReactiveRedisClusterConnection.
We introduced reactor based reactive connection support via ReactiveRedisConnection and ReactiveRedisClusterConnection.

A reactive connection can be obtained via the ConnectionFactory. This is currently only possible when using the Lettuce Redis driver.

Original pull request: #229.
2016-11-17 20:10:03 +01:00
Christoph Strobl
f6411b3811 DATAREDIS-567 - Remove Support for SRP and JRedis. 2016-11-07 15:34:12 +01:00
Christoph Strobl
186b6dd457 DATAREDIS-569 - Prepare 2.0 development.
Upgarde to Spring Data KeyValue 2.0.
2016-11-07 15:34:09 +01:00
Christoph Strobl
4be4ed0b28 DATAREDIS-528 - Upgrade to Lettuce 4.2.2.
We now support Lettuce 4.2.2.Final. Using Lettuce requires Java 8.

Original pull request: #222.
2016-10-12 15:45:38 +02:00
Oliver Gierke
a6ad1a516a DATAREDIS-487 - After release cleanups. 2016-07-27 14:32:38 +02:00
Oliver Gierke
2c1c872122 DATAREDIS-487 - Prepare next development iteration. 2016-07-27 14:32:36 +02:00
Oliver Gierke
e661201272 DATAREDIS-487 - Release version 1.8 M1 (Ingalls). 2016-07-27 13:52:13 +02:00
Oliver Gierke
316097ce06 DATAREDIS-487 - Prepare 1.8 M1 (Ingalls). 2016-07-27 13:51:38 +02:00
Mark Paluch
1a332c0f57 DATAREDIS-506 - Upgrade to Jedis 2.9.0.
We now support Jedis 2.9.0 with Redis Standalone SSL and Redis Cluster with passwords. The code is compatible with Jedis 2.8.0 when not using SSL or Redis Cluster with passwords.

Original Pull Request: #211
2016-07-26 15:48:03 +02:00
Oliver Gierke
f11bc83e46 DATAREDIS-484 - After release cleanups. 2016-04-06 16:37:03 +02:00
Oliver Gierke
6e5df14794 DATAREDIS-484 - Prepare next development iteration. 2016-04-06 16:37:00 +02:00
Oliver Gierke
59b6b93abc DATAREDIS-484 - Release version 1.7 GA (Hopper). 2016-04-06 16:35:59 +02:00
Oliver Gierke
96358c430d DATAREDIS-484 - Prepare 1.7 GA (Hopper). 2016-04-06 16:34:46 +02:00
Oliver Gierke
93bad424d1 DATAREDIS-475 - After release cleanups. 2016-03-18 11:16:08 +01:00
Oliver Gierke
41b6e8a171 DATAREDIS-475 - Prepare next development iteration. 2016-03-18 11:15:51 +01:00
Oliver Gierke
6e2d2683d1 DATAREDIS-475 - Release version 1.7 RC1 (Hopper). 2016-03-18 11:15:00 +01:00
Oliver Gierke
5d5ff81cd2 DATAREDIS-475 - Prepare 1.7 RC1 (Hopper). 2016-03-18 11:06:58 +01:00
Mark Paluch
77de777da8 DATAREDIS-479 - Upgrade to jedis to 2.8.1.
Update jedis driver to 2.8.1. Use binary method for SSCAN and implement ZSCAN and HSCAN methods. Move ScanOptions to ScanParams conversion to JedisConverters.

Original Pull Request: #178
2016-03-15 14:32:37 +01:00
Mark Paluch
754639d137 DATAREDIS-478 - Upgrade to lettuce 3.4.2.Final. 2016-03-15 08:15:07 +01:00
Mark Paluch
92274a8450 DATAREDIS-425 - Add JSR-310 support, CDI extension and Update reference documentation.
We ship converters for JSR-310 types (LocalDate/Time, ZonedDateTime, Period, Duration and ZoneId) to map between UTF-8-encoded byte[] and JDK 8 date/time types.

We also export Redis Repositories in a CDI environment. Repositories can be injected using @Inject. The CDI extension requires at least RedisOperations to be provided. Other beans like RedisKeyValueAdapter and RedisKeyValueTemplate can be provided by the user. If no RedisKeyValueAdapter/RedisKeyValueTemplate beans are found, the CDI extension creates own managed instances.

Original Pull Request: #156
2016-03-14 10:39:50 +01:00
Christoph Strobl
bd7728e6ad DATAREDIS-425 - Add Support for basic CRUD and finder Operations backed by Hashes and Sets.
We now enable storing domain object as a flat Redis 'HASH' and maintain additional 'SET' structures to enable finder operations on simple properties.

  @RedisHash("persons");
  class Person {

    @id String id;
    @Indexed String firstname;
    String lastname;

    Map<String, String> attributes;

    City city;

    @Reference Person mother;
  }

The above is stored in the HASH with key 'persons:1' as

  _class = org.example.Person
  id = 1
  firstname = rand
  lastname = al’thor
  attributes.[eye-color] = grey
  attributes.[hair-color] = red
  city.name = emond's field
  city.region = two rivers
  mother = persons:2

Complex types are flattened out to their full property path for each of the values provided. If the properties actual value type does not match the declared one the '_class' type hint is added to the entry.

  city._class = CityInAndor.class
  city.name = emond's field
  city.region = two rivers
  city.country = andor

Map and Collection like structures are stored with their key/index values as part of the property path. If the map/collection value type does not match the actutal objects one the '_class' type hint is added to the entry.

  list.[0]._class = DomainType.class
  list.[0].property1 = ...

  map.[key-1]._class = DomainType.class
  map.[key-1].property1 = ...

Properties marked with '@Reference' are stored as semantic references by just storing the key to the referenced object 'HASH' instead of embedding its values.

   mother = persons:2

Please note that referenced objects are not transitively updated/saved and that lazy loading of references will be part of future development.

A 'save' operation therefore executes the following:

  # flatten domain type and add as hash
  HMSET persons:1 id 1 firstname rand …

  # add the newly inserted entry to the list of all entries of that type
  SADD persons 1

  # index the firstname for finder lookup
  SADD persons.firstname:rand 1

Simple finder operation like 'findByFirstname' use 'SINTER' to find matching

  SINTER persons.firstname:rand
  HGETALL persons:1

Besides resolving an index via the '@Index' annotation we also allow to add custom configuration via the 'indexConfiguration' attribute of '@EnableRedisRepositories'.

  @Configuration
  @EnableRedisRepositories(indexConfiguration = CustomIndexConfiguration.class)
  class Config { }

  static class CustomIndexConfiguration extends IndexConfiguration {

    @Override
    protected Iterable<RedisIndexDefinition> initialConfiguration() {
      return Arrays.asList(
        new SimpleIndexDefinition("persons", "lastname"),
      );
    }
  }

The '@TimeToLive' annotation allows to define a property or method providing an expiration time when storing the key in redis.

@RedisHash
class Person {

  @Id String id;
  @TimeToLive Long ttl;
}

Original Pull Request: #156
2016-03-14 10:37:53 +01:00
Oliver Gierke
68da4a4ee5 DATAREDIS-447 - After release cleanups. 2016-02-12 15:43:57 +01:00
Oliver Gierke
2f07334363 DATAREDIS-447 - Prepare next development iteration. 2016-02-12 15:43:39 +01:00