XuQingping created IGNITE-10586:
-----------------------------------

             Summary: Ignite OSGI issues
                 Key: IGNITE-10586
                 URL: https://issues.apache.org/jira/browse/IGNITE-10586
             Project: Ignite
          Issue Type: Bug
          Components: osgi
    Affects Versions: 2.7, 2.6
            Reporter: XuQingping


 
 
When using the Ignite OSGI feature in Eclipse RCP, there are a lot of Issues:
1.Ignite-core 
   1) The cache-api-1.0.0.jar package that is included is not fully exported 
(for example, no export: javax.cache.configuration), it should be replaced 
with: org.apache.servicemix.bundles.javax-cache-api-1.1.0_1 .jar 
    2) References to unpublished packages such as com.sun.management, which 
need to be added at runtime 
       
-Dorg.osgi.framework.system.packages.extra=com.sun.management,sun.misc,sun.nio.ch
 
2.ignite-spring 
   1) The spring-xxxxx-4.3.16.RELEASE.jar series that comes with it is not 
an OSGI packaged version and should be replaced with the corresponding 
org.apache.servicemix.bundles version ([http://repo1.maven.org/maven2/org/]
Apache/servicemix/bundles/ Download version 4.3.16) 
   2) Even if replaced with the org.apache.servicemix.bundles version, since 
the org.apache.servicemix.bundles does not reference the ignite-core plugin, 
it cannot be dynamically created IgniteConfiguration when loading the Ignite 
configuration from the file(OSGI Bundles can only use Java classes exported 
by other OSGIBundles that they depend on (or import) (and these 
servicemix.bundles obviously have neither dependencies nor import any Ignite 
related types)). 

 Error message : 
 
{code:java}
class org.apache.ignite.IgniteException: Failed to create Ignite component 
(consider adding ignite-spring module to classpath) [component=SPRING, 
cls=org.apache.ignite.internal.util.spring.IgniteSpringHelperImpl]
        at 
org.apache.ignite.internal.util.IgniteUtils.convertException(IgniteUtils.java:1025)
        at org.apache.ignite.Ignition.start(Ignition.java:401)
        at ignite.examp.IgniteExampBase.startStdClient(IgniteExampBase.java:72)
        at 
ignite.examp.cluster.IgniteComputeExamp.main(IgniteComputeExamp.java:50)
        at 
ignite.examp.eclipse.IgniteExamp_Application.start(IgniteExamp_Application.java:23)
        at 
org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
        at 
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
        at 
org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
        at 
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:388)
        at 
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:243)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
        at java.lang.reflect.Method.invoke(Unknown Source)
        at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:653)
        at org.eclipse.equinox.launcher.Main.basicRun(Main.java:590)
        at org.eclipse.equinox.launcher.Main.run(Main.java:1499)
        at org.eclipse.equinox.launcher.Main.main(Main.java:1472)
Caused by: class org.apache.ignite.IgniteCheckedException: Failed to create 
Ignite component (consider adding ignite-spring module to classpath) 
[component=SPRING, 
cls=org.apache.ignite.internal.util.spring.IgniteSpringHelperImpl]
        at 
org.apache.ignite.internal.IgniteComponentType.componentException(IgniteComponentType.java:320)
        at 
org.apache.ignite.internal.IgniteComponentType.create0(IgniteComponentType.java:296)
        at 
org.apache.ignite.internal.IgniteComponentType.create(IgniteComponentType.java:207)
        at 
org.apache.ignite.internal.IgnitionEx.loadConfigurations(IgnitionEx.java:769)
        at org.apache.ignite.internal.IgnitionEx.start(IgnitionEx.java:1032)
        at org.apache.ignite.internal.IgnitionEx.start(IgnitionEx.java:982)
        at org.apache.ignite.Ignition.start(Ignition.java:398)
        ... 16 more
Caused by: java.lang.ClassNotFoundException: 
org.apache.ignite.internal.util.spring.IgniteSpringHelperImpl cannot be found 
by com.cimstech.xlibs.ignite_1.0.0
        at 
org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:484)
        at 
org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:395)
        at 
org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:387)
        at 
org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:150)
        at java.lang.ClassLoader.loadClass(Unknown Source)
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Unknown Source)
        at 
org.apache.ignite.internal.IgniteComponentType.create0(IgniteComponentType.java:282)
        ... 21 more
{code}
 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to