2 Replies Latest reply on Sep 13, 2006 7:16 AM by dudududu

    EJB3.0 cache

    dudududu Novice

      I am using hibernate with 2nd level cahce and i've some quesions regarding the concurrent cache strategy:

      1) I've 2 entities Event and EventText
      for each Event there are many EventText

      EventText is an entity that I am only inserting(never update/delete) but it hold one Event
      and Event is an entity that can be changed once in few weeks , can I use READ_ONLY for EventText?

      2)now what about queries? I would like to query i.e. all Events that contains EventText.type=1 , can I cache this query?
      I thought to put TRANSACTIONAL cache on the Event entity and cache this queries , does it make sense?