List of usage examples for org.springframework.data.redis.connection RedisConnection persist
@Nullable
Boolean persist(byte[] key);
From source file:com.zxy.commons.cache.RedisUtils.java
/** * Remove the expiration from given {@code key}. * <p>//from w w w. j a va2s.co m * See http://redis.io/commands/persist * * @param key key * @return Boolean */ public static Boolean persist(byte[] key) { return redisTemplate.execute(new RedisCallback<Boolean>() { @Override public Boolean doInRedis(RedisConnection redis) throws DataAccessException { return redis.persist(key); } }); }
From source file:com.zxy.commons.cache.RedisHelper.java
/** * Remove the expiration from given {@code key}. * <p>/* ww w .ja v a 2 s. com*/ * See http://redis.io/commands/persist * * @param key key * @return Boolean */ public Boolean persist(byte[] key) { return redisTemplate.execute(new RedisCallback<Boolean>() { @Override public Boolean doInRedis(RedisConnection redis) throws DataAccessException { return redis.persist(key); } }); }