I gave that a whirl...specifically, I changed the bootFeatures to the following:

        <feature>jdbc</feature>

        <feature>transaction</feature>

        <feature>jpa</feature>

        <feature>openjpa/${openjpa.version}</feature>

        <feature>hearsay-commons</feature>

        <!-- <feature>hearsay-dao</feature>         -->


Upon startup of the custom distro, I see the following from a list command:

151 | Resolved |  80 | 2.4.0              | OpenJPA Aggregate Jar


There is an exception in the karaf.log:

org.apache.karaf.features.internal.util.MultiException: Error restarting bundles

    at 
org.apache.karaf.features.internal.service.Deployer.deploy(Deployer.java:844)[7:org.apache.karaf.features.core:4.0.3]

    at 
org.apache.karaf.features.internal.service.FeaturesServiceImpl.doProvision(FeaturesServiceImpl.java:1079)[7:org.apache.karaf.features.core:4.0.3]

    at 
org.apache.karaf.features.internal.service.FeaturesServiceImpl$1.call(FeaturesServiceImpl.java:975)[7:org.apache.karaf.features.core:4.0.3]

    at java.util.concurrent.FutureTask.run(FutureTask.java:266)[:1.8.0_45]

    at 
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)[:1.8.0_45]

    at 
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)[:1.8.0_45]

    at java.lang.Thread.run(Thread.java:745)[:1.8.0_45]

Caused by: org.osgi.framework.BundleException: Activator start error in bundle 
org.apache.openjpa [151].

    at 
org.apache.felix.framework.Felix.activateBundle(Felix.java:2276)[org.apache.felix.framework-5.4.0.jar:]

    at 
org.apache.felix.framework.Felix.startBundle(Felix.java:2144)[org.apache.felix.framework-5.4.0.jar:]

    at 
org.apache.felix.framework.BundleImpl.start(BundleImpl.java:998)[org.apache.felix.framework-5.4.0.jar:]

    at 
org.apache.felix.framework.BundleImpl.start(BundleImpl.java:984)[org.apache.felix.framework-5.4.0.jar:]

    at 
org.apache.karaf.features.internal.service.FeaturesServiceImpl.startBundle(FeaturesServiceImpl.java:1189)[7:org.apache.karaf.features.core:4.0.3]

    at 
org.apache.karaf.features.internal.service.Deployer.deploy(Deployer.java:836)[7:org.apache.karaf.features.core:4.0.3]

    ... 6 more

Caused by: java.lang.NoClassDefFoundError: javax/transaction/SystemException

    at 
org.apache.openjpa.persistence.osgi.PersistenceActivator.start(PersistenceActivator.java:61)

    at 
org.apache.felix.framework.util.SecureAction.startActivator(SecureAction.java:697)

    at org.apache.felix.framework.Felix.activateBundle(Felix.java:2226)

    ... 11 more

Caused by: java.lang.ClassNotFoundException: javax.transaction.SystemException 
not found by org.apache.openjpa [151]

    at 
org.apache.felix.framework.BundleWiringImpl.findClassOrResourceByDelegation(BundleWiringImpl.java:1574)[org.apache.felix.framework-5.4.0.jar:]

    at 
org.apache.felix.framework.BundleWiringImpl.access$400(BundleWiringImpl.java:79)[org.apache.felix.framework-5.4.0.jar:]

    at 
org.apache.felix.framework.BundleWiringImpl$BundleClassLoader.loadClass(BundleWiringImpl.java:2018)[org.apache.felix.framework-5.4.0.jar:]

    at java.lang.ClassLoader.loadClass(ClassLoader.java:357)[:1.8.0_45]


However, the transaction packages are visible:

karaf@root()> exports | grep javax.transaction

javax.transaction.xa                                                            
                       | 0.0.0            | 0   | org.apache.felix.framework

javax.transaction.xa                                                            
                       | 1.1.0            | 119 | 
org.apache.geronimo.specs.geronimo-jta_1.1_spec

javax.transaction.xa                                                            
                       | 1.2.0            | 30  | javax.transaction-api

javax.transaction                                                               
                       | 0.0.0            | 0   | org.apache.felix.framework

javax.transaction                                                               
                       | 1.1.0            | 119 | 
org.apache.geronimo.specs.geronimo-jta_1.1_spec

javax.transaction                                                               
                       | 1.2.0            | 30  | javax.transaction-api


Regards,
Jason

On 11/30/2015 10:31 AM, Christian Schneider wrote:
On 30.11.2015 16:13, Jason Reilly wrote:
Thanks Christian,



Then in the pom.xml for building the custom distribution, I have the following relevant bootFeatures:

        <feature>aries-blueprint</feature>

        <feature>cxf</feature>

        <feature>jdbc</feature>

        <feature>transaction-api/1.1.0</feature>
This is wrong. You need to install the "transaction" feature. This is just the API. Also for transaction you do not need to specify a version. The feature will install the old and the new transaction blueprint bundle.


        <feature>jpa/1.0.4</feature>
Also not sure about this one. As you use the annotations there you could as well install the "jpa" feature which will give you the new 2.x version.

<feature>openjpa/${openjpa.version}</feature>


Christian


Reply via email to