Uses of Interface
org.springframework.data.redis.serializer.RedisSerializer
Package
Description
Connection package providing low-level abstractions for interacting with the various Redis 'drivers'/libraries.
Redis specific converters used for sending data and parsing responses.
Data structures and interfaces to interact with Redis Streams.
Core package for integrating Redis with Spring concepts.
Query package for Redis template.
Lua script execution abstraction.
Base package for Redis message listener / pubsub container facility
Message listener adapter package.
Serialization/Deserialization package for converting Object to (and from) binary data.
-
Uses of RedisSerializer in org.springframework.data.redis.connection
ModifierConstructorDescriptionDefaultStringRedisConnection
(RedisConnection connection, RedisSerializer<String> serializer) Constructs a newDefaultStringRedisConnection
instance. -
Uses of RedisSerializer in org.springframework.data.redis.connection.convert
Modifier and TypeMethodDescriptionstatic <V> Converter<GeoResults<RedisGeoCommands.GeoLocation<byte[]>>,
GeoResults<RedisGeoCommands.GeoLocation<V>>> Converters.deserializingGeoResultsConverter
(RedisSerializer<V> serializer) Converter
capable of deserializingGeoResults
. -
Uses of RedisSerializer in org.springframework.data.redis.connection.stream
Modifier and TypeMethodDescriptiondefault <K,
HK, HV> MapRecord<K, HK, HV> ByteBufferRecord.deserialize
(RedisSerializer<? extends K> streamSerializer, RedisSerializer<? extends HK> fieldSerializer, RedisSerializer<? extends HV> valueSerializer) Deserializekey
with the streamSerializer, field names with the fieldSerializer and values with the valueSerializer.default <T> MapRecord<T,
T, T> ByteBufferRecord.deserialize
(RedisSerializer<T> serializer) default <K,
HK, HV> MapRecord<K, HK, HV> ByteRecord.deserialize
(RedisSerializer<? extends K> streamSerializer, RedisSerializer<? extends HK> fieldSerializer, RedisSerializer<? extends HV> valueSerializer) Deserializekey
with the streamSerializer, field names with the fieldSerializer and values with the valueSerializer.default <T> MapRecord<T,
T, T> ByteRecord.deserialize
(RedisSerializer<T> serializer) default ByteRecord
MapRecord.serialize
(RedisSerializer<?> serializer) default ByteRecord
MapRecord.serialize
(RedisSerializer<? super S> streamSerializer, RedisSerializer<? super K> fieldSerializer, RedisSerializer<? super V> valueSerializer) Serializekey
with the streamSerializer, field names with the fieldSerializer and values with the valueSerializer. -
Uses of RedisSerializer in org.springframework.data.redis.core
Modifier and TypeMethodDescriptionRedisTemplate.getDefaultSerializer()
Returns the default serializer used by this template.RedisOperations.getHashKeySerializer()
RedisTemplate.getHashKeySerializer()
Returns the hashKeySerializer.RedisOperations.getHashValueSerializer()
RedisTemplate.getHashValueSerializer()
Returns the hashValueSerializer.RedisOperations.getKeySerializer()
RedisTemplate.getKeySerializer()
Returns the key serializer used by this template.RedisTemplate.getStringSerializer()
Returns the stringSerializer.RedisOperations.getValueSerializer()
RedisTemplate.getValueSerializer()
Returns the value serializer used by this template.Modifier and TypeMethodDescriptionRedisOperations.exec
(RedisSerializer<?> valueSerializer) Execute a transaction, using the providedRedisSerializer
to deserialize any results that are byte[]s or Collections of byte[]s.RedisTemplate.exec
(RedisSerializer<?> valueSerializer) <T> T
RedisOperations.execute
(RedisScript<T> script, RedisSerializer<?> argsSerializer, RedisSerializer<T> resultSerializer, List<K> keys, Object... args) Executes the givenRedisScript
, using the providedRedisSerializer
s to serialize the script arguments and result.<T> T
RedisTemplate.execute
(RedisScript<T> script, RedisSerializer<?> argsSerializer, RedisSerializer<T> resultSerializer, List<K> keys, Object... args) RedisOperations.executePipelined
(RedisCallback<?> action, RedisSerializer<?> resultSerializer) Executes the given action object on a pipelined connection, returning the results using a dedicated serializer.RedisOperations.executePipelined
(SessionCallback<?> session, RedisSerializer<?> resultSerializer) Executes the given Redis session on a pipelined connection, returning the results using a dedicated serializer.RedisTemplate.executePipelined
(RedisCallback<?> action, RedisSerializer<?> resultSerializer) RedisTemplate.executePipelined
(SessionCallback<?> session, RedisSerializer<?> resultSerializer) void
RedisTemplate.setDefaultSerializer
(RedisSerializer<?> serializer) Sets the default serializer to use for this template.void
RedisTemplate.setHashKeySerializer
(RedisSerializer<?> hashKeySerializer) Sets the hash key (or field) serializer to be used by this template.void
RedisTemplate.setHashValueSerializer
(RedisSerializer<?> hashValueSerializer) Sets the hash value serializer to be used by this template.void
RedisTemplate.setKeySerializer
(RedisSerializer<?> serializer) Sets the key serializer to be used by this template.void
RedisTemplate.setStringSerializer
(RedisSerializer<String> stringSerializer) Sets the string value serializer to be used by this template (when the arguments or return types are always strings).void
RedisTemplate.setValueSerializer
(RedisSerializer<?> serializer) Sets the value serializer to be used by this template.<T,
S> List<T> RedisOperations.sort
(SortQuery<K> query, BulkMapper<T, S> bulkMapper, RedisSerializer<S> resultSerializer) <T> List<T>
RedisOperations.sort
(SortQuery<K> query, RedisSerializer<T> resultSerializer) Sort the elements forquery
applyingRedisSerializer
.<T,
S> List<T> RedisTemplate.sort
(SortQuery<K> query, BulkMapper<T, S> bulkMapper, RedisSerializer<S> resultSerializer) <T> List<T>
RedisTemplate.sort
(SortQuery<K> query, RedisSerializer<T> resultSerializer) -
Uses of RedisSerializer in org.springframework.data.redis.core.query
Modifier and TypeMethodDescriptionstatic <K> SortParameters
QueryUtils.convertQuery
(SortQuery<K> query, RedisSerializer<String> stringSerializer) -
Uses of RedisSerializer in org.springframework.data.redis.core.script
Modifier and TypeMethodDescriptionprotected RedisSerializer
DefaultScriptExecutor.keySerializer()
Modifier and TypeMethodDescriptionprotected <T> T
DefaultScriptExecutor.deserializeResult
(RedisSerializer<T> resultSerializer, Object result) protected <T> T
DefaultScriptExecutor.eval
(RedisConnection connection, RedisScript<T> script, ReturnType returnType, int numKeys, byte[][] keysAndArgs, RedisSerializer<T> resultSerializer) <T> T
DefaultScriptExecutor.execute
(RedisScript<T> script, RedisSerializer<?> argsSerializer, RedisSerializer<T> resultSerializer, List<K> keys, Object... args) <T> T
ScriptExecutor.execute
(RedisScript<T> script, RedisSerializer<?> argsSerializer, RedisSerializer<T> resultSerializer, List<K> keys, Object... args) Executes the givenRedisScript
, using the providedRedisSerializer
s to serialize the script arguments and result.protected byte[][]
DefaultScriptExecutor.keysAndArgs
(RedisSerializer argsSerializer, List<K> keys, Object[] args) -
Uses of RedisSerializer in org.springframework.data.redis.listener
Modifier and TypeMethodDescriptionvoid
RedisMessageListenerContainer.setTopicSerializer
(RedisSerializer<String> serializer) Sets the serializer for converting theTopic
s into low-level channels and patterns. -
Uses of RedisSerializer in org.springframework.data.redis.listener.adapter
Modifier and TypeMethodDescriptionvoid
MessageListenerAdapter.setSerializer
(RedisSerializer<?> serializer) Set the serializer that will convert incoming raw Redis messages to listener method arguments.void
MessageListenerAdapter.setStringSerializer
(RedisSerializer<String> serializer) Sets the serializer used for converting the channel/pattern to a String. -
Uses of RedisSerializer in org.springframework.data.redis.serializer
Modifier and TypeClassDescriptionclass
Generic Jackson 2-basedRedisSerializer
that mapsobjects
to and from JSON using dynamic typing.class
Generic String to byte[] (and back) serializer.class
class
Java SerializationRedisSerializer
.class
Serializer adapter on top of Spring's O/X Mapping.class
SimpleString
to byte[] (and back) serializer.Modifier and TypeMethodDescriptionstatic RedisSerializer<byte[]>
RedisSerializer.byteArray()
Obtain aRedisSerializer
that passes thrubyte[]
.static RedisSerializer<Object>
RedisSerializer.java()
Obtain aRedisSerializer
using java serialization.static RedisSerializer<Object>
RedisSerializer.java
(ClassLoader classLoader) Obtain aRedisSerializer
using java serialization with the givenClassLoader
.static RedisSerializer<Object>
RedisSerializer.json()
Obtain aRedisSerializer
that can read and write JSON using Jackson.static RedisSerializer<String>
RedisSerializer.string()
Modifier and TypeMethodDescriptionstatic <T> Collection<T>
SerializationUtils.deserialize
(Collection<byte[]> rawValues, RedisSerializer<T> redisSerializer) static <T> List<T>
SerializationUtils.deserialize
(List<byte[]> rawValues, RedisSerializer<T> redisSerializer) static <HK,
HV> Map<HK, HV> SerializationUtils.deserialize
(Map<byte[], byte[]> rawValues, RedisSerializer<HK> hashKeySerializer, RedisSerializer<HV> hashValueSerializer) static <T> Map<T,
T> SerializationUtils.deserialize
(Map<byte[], byte[]> rawValues, RedisSerializer<T> redisSerializer) static <T> Set<T>
SerializationUtils.deserialize
(Set<byte[]> rawValues, RedisSerializer<T> redisSerializer) static <T> RedisElementReader<T>
RedisElementReader.from
(RedisSerializer<T> serializer) Create newRedisElementReader
using givenRedisSerializer
.static <T> RedisElementWriter<T>
RedisElementWriter.from
(RedisSerializer<T> serializer) Create newRedisElementWriter
using givenRedisSerializer
.static <T> RedisSerializationContext<T,
T> RedisSerializationContext.fromSerializer
(RedisSerializer<T> serializer) Creates a newRedisSerializationContext
using the givenRedisSerializer
.static <T> RedisSerializationContext.SerializationPair<T>
RedisSerializationContext.SerializationPair.fromSerializer
(RedisSerializer<T> serializer) Creates aRedisSerializationContext.SerializationPair
adapter givenRedisSerializer
.RedisSerializationContext.RedisSerializationContextBuilder.hashKey
(RedisSerializer<?> serializer) Set the hash keyRedisSerializationContext.SerializationPair
given aRedisSerializer
.RedisSerializationContext.RedisSerializationContextBuilder.hashValue
(RedisSerializer<?> serializer) Set the hash valueRedisSerializationContext.SerializationPair
given aRedisSerializer
.RedisSerializationContext.RedisSerializationContextBuilder.key
(RedisSerializer<K> serializer) Set the keyRedisSerializationContext.SerializationPair
given aRedisSerializer
.static <K,
V> RedisSerializationContext.RedisSerializationContextBuilder<K, V> RedisSerializationContext.newSerializationContext
(RedisSerializer<?> defaultSerializer) Creates a newRedisSerializationContext.RedisSerializationContextBuilder
using a given defaultRedisSerializer
.RedisSerializationContext.RedisSerializationContextBuilder.string
(RedisSerializer<String> serializer) Set the stringRedisSerializationContext.SerializationPair
given aRedisSerializer
.RedisSerializationContext.RedisSerializationContextBuilder.value
(RedisSerializer<V> serializer) Set the valueRedisSerializationContext.SerializationPair
given aRedisSerializer
. -
Uses of RedisSerializer in org.springframework.data.redis.stream
Modifier and TypeMethodDescriptionStreamMessageListenerContainer.StreamMessageListenerContainerOptions.getHashKeySerializer()
StreamMessageListenerContainer.StreamMessageListenerContainerOptions.getHashValueSerializer()
StreamMessageListenerContainer.StreamMessageListenerContainerOptions.getKeySerializer()
Modifier and TypeMethodDescription<HK,
HV> StreamMessageListenerContainer.StreamMessageListenerContainerOptionsBuilder<K, MapRecord<K, HK, HV>> StreamMessageListenerContainer.StreamMessageListenerContainerOptionsBuilder.hashKeySerializer
(RedisSerializer<HK> serializer) Configure a hash key serializer.<HK,
HV> StreamMessageListenerContainer.StreamMessageListenerContainerOptionsBuilder<K, MapRecord<K, HK, HV>> StreamMessageListenerContainer.StreamMessageListenerContainerOptionsBuilder.hashValueSerializer
(RedisSerializer<HV> serializer) Configure a hash value serializer.<NK,
NV extends Record<NK, ?>>
StreamMessageListenerContainer.StreamMessageListenerContainerOptionsBuilder<NK,NV> StreamMessageListenerContainer.StreamMessageListenerContainerOptionsBuilder.keySerializer
(RedisSerializer<NK> serializer) Configure a key serializer.StreamMessageListenerContainer.StreamMessageListenerContainerOptionsBuilder.serializer
(RedisSerializer<T> serializer) Configure a key, hash key and hash value serializer.