springboot2配置redis,键key上为什么有两个冒号::


user::1

{"id":"1","name":"张三","age":18}

RedisCache类createCacheKey方法
CacheKeyPrefix接口

	/**
	 * Creates a default {@link CacheKeyPrefix} scheme that prefixes cache keys with {@code cacheName} followed by double
	 * colons. A cache named {@code myCache} will prefix all cache keys with {@code myCache::}.
	 *
	 * @return the default {@link CacheKeyPrefix} scheme.
	 */
	static CacheKeyPrefix simple() {
		return name -> name + "::";
	}

 

你可能感兴趣的:(redis,springboot)