Java RCP中插件项目中的基本POM.xml结构是什么。我有如下的POM.xml内容。有了这个内容,它能够启动产品,但maven构建不成功。如果我删除它的部分构建但应用程序无法启动。它显示以下错误消息:
org.osgi.framework.BundleException:包com.cerner.scrumdashboard的激活器com.cerner.scrumdashboard.Activator无效 在org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:171) 在org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:679) 在org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381) 在org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:299) 在org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:440) 在org.eclipse.osgi.internal.loader.BundleLoader.setLazyTrigger(BundleLoader.java:268) 在org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:236) 在org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1207) 在org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:174) 在org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905) 在org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243) 在org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55) 在org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:191) 在org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110) 在org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79) 在org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344) 在org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) 在org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622) 在org.eclipse.equinox.launcher.Main.basicRun(Main.java:577) 在org.eclipse.equinox.launcher.Main.run(Main.java:1410) 在org.eclipse.equinox.launcher.Main.main(Main.java:1386) 引起:java.lang.ClassNotFoundException:com.cerner.scrumdashboard.Activator 在org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:513) 在org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429) 在org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417) 在org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107) at java.lang.ClassLoader.loadClass(ClassLoader.java:358) 在org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:345) 在org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229) 在org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:164) ......还有24个 根异常: java.lang.ClassNotFoundException:com.cerner.scrumdashboard.Activator 在org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:513) 在org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429) 在org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417) 在org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107) at java.lang.ClassLoader.loadClass(ClassLoader.java:358) 在org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:345) 在org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229) 在org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:164) 在org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:679) 在org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381) 在org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:299) 在org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:440) 在org.eclipse.osgi.internal.loader.BundleLoader.setLazyTrigger(BundleLoader.java:268) 在org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:236) 在org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1207) 在org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:174) 在org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905) 在org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243) 在org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55) 在org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:191) 在org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110) 在org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79) 在org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:344) 在org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) 在org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:622) 在org.eclipse.equinox.launcher.Main.basicRun(Main.java:577) 在org.eclipse.equinox.launcher.Main.run(Main.java:1410) 在org.eclipse.equinox.launcher.Main.main(Main.java:1386)
POM.xml内容: http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0 com.cerner.scrumdashboard com.cerner.scrumdashboard 0.0.1-SNAPSHOT
<dependencies>
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>5.1.18</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.12</version>
</dependency>
</dependencies>
<!-- <build>
<sourceDirectory>src</sourceDirectory>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.1</version>
<configuration>
<fork>true</fork>
<executable>C:\Program Files\Java\jdk1.7.0_45\bin\javac.exe</executable>
</configuration>
</plugin>
</plugins>
</build> -->