Skip to content

Commit eb1d320

Browse files
GenericJackson3RedisSerializer
1 parent 79b6618 commit eb1d320

File tree

5 files changed

+1156
-2
lines changed

5 files changed

+1156
-2
lines changed

src/main/antora/modules/ROOT/pages/redis/template.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -365,7 +365,7 @@ Multiple implementations are available (including two that have been already men
365365
* javadoc:org.springframework.data.redis.serializer.JdkSerializationRedisSerializer[], which is used by default for javadoc:org.springframework.data.redis.cache.RedisCache[] and javadoc:org.springframework.data.redis.core.RedisTemplate[].
366366
* the `StringRedisSerializer`.
367367

368-
However, one can use `OxmSerializer` for Object/XML mapping through Spring {spring-framework-docs}/data-access.html#oxm[OXM] support or javadoc:org.springframework.data.redis.serializer.Jackson3JsonRedisSerializer[] or javadoc:org.springframework.data.redis.serializer.GenericJackson2JsonRedisSerializer[] for storing data in https://en.wikipedia.org/wiki/JSON[JSON] format.
368+
However, one can use `OxmSerializer` for Object/XML mapping through Spring {spring-framework-docs}/data-access.html#oxm[OXM] support or javadoc:org.springframework.data.redis.serializer.Jackson3JsonRedisSerializer[] or javadoc:org.springframework.data.redis.serializer.GenericJackson3JsonRedisSerializer[] for storing data in https://en.wikipedia.org/wiki/JSON[JSON] format.
369369

370370
Do note that the storage format is not limited only to values.
371371
It can be used for keys, values, or hashes without any restrictions.

src/main/java/org/springframework/data/redis/hash/Jackson3HashMapper.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -466,7 +466,7 @@ private static class HashMapperModule extends JacksonModule {
466466

467467
@Override
468468
public String getModuleName() {
469-
return "spring-data-hash-mapper-module";
469+
return "spring-data-redis-hash-mapper-module";
470470
}
471471

472472
@Override

src/main/java/org/springframework/data/redis/serializer/GenericJackson2JsonRedisSerializer.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,9 @@
7171
* @see org.springframework.data.redis.serializer.JacksonObjectWriter
7272
* @see com.fasterxml.jackson.databind.ObjectMapper
7373
* @since 1.6
74+
* @deprecated since 4.0 in favor of {@link GenericJackson3JsonRedisSerializer}
7475
*/
76+
@Deprecated(since = "4.0", forRemoval = true)
7577
public class GenericJackson2JsonRedisSerializer implements RedisSerializer<Object> {
7678

7779
private final JacksonObjectReader reader;

0 commit comments

Comments
 (0)