after saving the value of redis in Java, the value cannot be fetched. You can save it to redis, but the value of key taken out is null
.@Autowired
private JedisClient jedisClient;
//redis redis
jedisClient.hset("INDEX_CONTENT", cid+"", JsonUtils.objectToJson(list));
// jsonNull
String json = jedisClient.hget(INDEX_CONTENT, cid+"");
xml profile for redis
<!-- redis -->
<bean id="jedisPool" class="redis.clients.jedis.JedisPool">
<constructor-arg name="host" value="192.168.87.128"/>
<constructor-arg name="port" value="6379"/>
</bean>
<!-- spring -->
<bean id="jedisClientPool" class="com.taotao.jedis.JedisClientPool"/>
excuse me, this problem lies in the scanning place