Redis: what‘s the difference between jedis and redistemplate?

DWQA Questions › Category: Database › Redis: what's the difference between jedis and redistemplate?

0Vote UpVote Down

esolve asked 1 year ago

How to choose to use?

Question Tags: javaredis

3 Answers

0Vote UpVote Down

Su Sheng answered 1 year ago

Jedis is officially recommended by redis as a Java oriented client to operate redis, while redistemplate is a high encapsulation of jedisapi in spring data redis.
Compared with jedis, spring data redis can easily replace the Java client of redis, which has more features of automatic connection pool management than jedis, and is easy to use with other spring frameworks, such as spring cache

0Vote UpVote Down

Ink is sweet answered 1 year ago

Redistemplate is a template for using redis in spring data redis.
Jedisconnectionfactory is a factory class for spring data redis to use redis through jedis.

That is to say, spring uses redis through redistemplate and gets it through jedis.

 

0Vote UpVote Down

anysoft answered 1 year ago

Jedis is an official framework for redis to encapsulate the Java operation redis API.
Redistemplate is the encapsulation of jedis and lettuce by spring framework. So that the spring framework system can be more convenient access to the function of redis.
Redistemplate supports jedis and lettuce

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值