Skip to content

RedisTemplate operations types

The RedisTemplate in Spring Data Redis provides two distinct categories of operations for interacting with a Redis datastore. These categories determine how operations are bound to specific keys.^[600-developer-spring-springboot-data-redis.md]

Operation Categories

The two primary types of operations are:

  • Key Type Operations: These operations allow you to execute commands for a specific data structure (such as Hash, List, Set, etc.) without explicitly binding the operation instance to a specific key in advance.
  • Key Bound Operations: These operations are bound to a specific key. This binding allows the command to be executed against the associated key without needing to specify the key again in the method call^[600-developer-spring-springboot-data-redis.md].

Sources

  • 600-developer-spring-springboot-data-redis.md