Announcement Announcement Module
Collapse
No announcement yet.
Hibernate, 2nd level cache, and transactions Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Hibernate, 2nd level cache, and transactions

    Hey all,

    I'm trying to get the 2nd level caching working in Hibernate. I'm using Hibernate 3 and the Hibernate 3 dao support in spring. For the second level cache I plan to use ehcache. I'm using the Spring HibernateTransactionManager for my TransactionProxyFactoryBean transaction manager.

    What I can't figure out is what to set as the hibernate.transaction.manager_lookup_class in the Hibernate configuration. I'd rather avoid the need to run a full blown application server like JBoss so I don't want to have to switch to a JtaTransactionManager and use JNDI everywhere.

    Is there a way I can do this without using an application server? What transaction manager should I be using and what should I use for the transaction manager lookup class in the hibernate config?

    Thanks in advance,
    Rich

  • #2
    See the samples from Spring project - the transaction manager lookup is used inside an application server as the transactions are usually handles by the server manager - in your case if you don't specify it, it will not be used.

    Comment


    • #3
      I looked at the samples from the Spring project but don't see anything applicable.

      Is there no way to use a 2nd level cache with hibernate and spring unless it's in an application server?

      Comment

      Working...
      X