开发者

Hibernate Cache and JdbcTemplate

开发者 https://www.devze.com 2023-01-12 13:08 出处:网络
Will the Hibernate caching(1st, 2nd, or Query) work when I use JdbcTemplate? I got to know that the caching is one of the advantage in using ORM instead of traditional JDBC. So, If I got to use Hibe开

Will the Hibernate caching(1st, 2nd, or Query) work when I use JdbcTemplate?

I got to know that the caching is one of the advantage in using ORM instead of traditional JDBC. So, If I got to use Hibe开发者_运维知识库rnate's JdbcTemplate, still can I enjoy the benefits of hibernate caching?


Since you're bypassing your hibernate altogether, you have to implement/configure those things yourself.


No, if you use JdbcTemplate you will be bypassing the cache entirely and will thus need to invalidate it.

0

精彩评论

暂无评论...
验证码 换一张
取 消