Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
这就是javadoc提到JReJSON的定义的方式
JReJSON(String host, int port) Creates a client to the specific host/post a client to the specific host/post
但有提供密码的规定
连同主机和端口,因为只有两个参数不足以创建客户端,因为缺少身份验证,这是通过提供密码启用的
尝试使用JReJSON(Pool<Jedis> jedis)构造函数。
JReJSON(Pool<Jedis> jedis)
例如
new JReJSON(new JedisPool(host, port, user, password))
如果您的 Redis 版本早于 Redis 6 或者您不想使用该user参数:
user
new JReJSON(new JedisPool(host, port, null, password))