Uploaded image for project: 'Ignite'
  1. Ignite
  2. IGNITE-4916 Hibernate support improvement
  3. IGNITE-4760

Hibernate L2 cache stores value in wrong cache

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 2.1
    • hibernate
    • None

    Description

      Issue is reported here:
      http://apache-ignite-developers.2346864.n4.nabble.com/issue-with-Hibernate-2L-cache-region-factory-ignite-1-8-td14912.html

      First it is necessary add JUnit test reproducing issue (see existing tests in IgniteHibernateTestSuite).

      Currently Hibernate access strategies track updates using thread locals, and it looks like updates for different caches can be mixed. I think per-cache thread local can fix issue for HibernateNonStrictAccessStrategy, but per-cache thread local can not be used for HibernateReadWriteAccessStrategy, since it is assumed that all updates should be part of the same cross-cache ignite transaction.

      So possible fix:

      • use per-cache thread local for HibernateNonStrictAccessStrategy (or somehow track target cache in HibernateNonStrictAccessStrategy)
      • use single thread local for HibernateReadWriteAccessStrategy

      Attachments

        Issue Links

          Activity

            People

              javaller Vadim Opolski
              sboikov Semen Boikov
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: