Uploaded image for project: 'Aries'
  1. Aries
  2. ARIES-1018

JPA container throws Exception when stopped without a JPA-Provider present

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • None
    • JPA
    • None

    Description

      To reproduce unpack the latest karaf-snapshot and install the JPA-feature:

      feature:install jpa
      

      and install a bundle containing a persistence-unit.

      stop the JPA Container bundle.

      
      

      This happens since aries-util was upgraded to 1.1.0. The issue did not occur with util-1.0.0.
      I investigated a bit and found the problem:

      In util-1.1.0 the BundleHookBundleTracker was changed to untrack all bundles when it's closed. In util-1.0 closing did essentially nothing but setting a closed-flag.

      So when using JPA Container with util-1.1.0 the persistence-units are destroyed without ever being created.

      This also happens when having a JPA Provider (like OpenJPA) installed, but when it's stopped before the the JPA-Container Bundle is stopped (the usual case).

      Attachments

        1. fix-exception.patch
          0.9 kB
          Christoph Gritschenberger

        Issue Links

          Activity

            People

              jbonofre Jean-Baptiste Onofré
              christophg Christoph Gritschenberger
              Votes:
              4 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: