Combination hibernate @Transactional & ehcache @Cacheable always creates DB transaction

后端 未结 1 987
感情败类
感情败类 2021-02-08 10:44

While doing loadtesting on our application I noticed that if you use @Transactional and @Cacheable annotions that hibernate always creates a database transaction. Is there an ea

1条回答
  •  礼貌的吻别
    2021-02-08 11:23

    You need to change relative order of @Transactional and @Cacheable aspects.

    It can be configured using order attribute of and . See 8.2.4.7 Advice ordering for the meaning of order values.

    0 讨论(0)
提交回复
热议问题