VMware {code} Community
vromanowski
Enthusiast
Enthusiast

Another 'Import-Package could not be resolved' issue.

I’ve been unable to fix this issue despite all the references to it in the SDK docs. I’m trying to get a pre-existing web app working with the Web Client, following the instructions under Integration of Existing Web Application.

An Import-Package could not be resolved. Resolver error data <Import-Package: org.apache.wicket.protocol.http.WicketFilter; version="0.0.0">. Caused by missing constraint in bundle <com.micron.rssdmui.rssdm-ui_1.0.0> constraint: <Import-Package: org.apache.wicket.protocol.http.WicketFilter; version="0.0.0">

I've followed all the steps under vsphere-client-sdk/docs/FAQ.html


How to use 3rd party java libraries?

This section states that as an alternative to using bundler/OSGI bundles you can nest your dependencies within the plugin.

I've included all my jar file dependencies at the root level of my war file like the instructions say (although I also tried WEB-INF/lib).

I've also added Bundle-ClassPath and Import-Package to my manifest as required.

Here is what my manifest file looks like: (omitted company name, .etc)

Manifest-Version: 1.0

Ant-Version: Apache Ant 1.9.4

Created-By: 1.8.0_45-b14 (Oracle Corporation)

Bundle-Name: <plugin>-ui

Bundle-SymbolicName: com.<company>.<plugin>.<plugin>-ui

Bundle-Version: 1.0.0

Web-ContextPath: vsphere-client/<plugin>

Import-Package: org.apache.wicket.protocol.http.WicketFilter

Bundle-ClassPath: .,wicket-core-1.5.8.jar

The relevant parts of my war file looks like this:

WEB-INF

    web.xml

META-INF

    MANIFEST.MF

wicket-core-1.5.8.jar

How to solve most ClassNotFoundException or similar errors?

As above, I think I've correctly put the dependency in my bundle's manifest.

Bundle installation fails because "An Import-Package could not be resolved"

I don't think the Import-Packages metadata is wrong, and there's only one plugin package/bundle so I don't think it's an issue with the order of packages being deployed. It mentions that version="0.0.0" is an indication that MANIFEST.MF is missing, but I've checked the contents of the war file I'm generating.


Are there any suggestions? I can attempt to use the bundler tool if I have to, but this web app is relatively simple and I should be able to include a few jar files in it without all this trouble 😕

Reply
0 Kudos
20 Replies
laurentsd
VMware Employee
VMware Employee

Since it's impossible to know exactly how your project is setup the best is to isolate this 3rd party jar problem by adding it to one of the SDK samples and reproduce the issue. Then you can tell us what to change in the SDK sample to see the same issue and we may be able to help you.

Reply
0 Kudos
vromanowski
Enthusiast
Enthusiast

I've made it through the Import-Package errors by OSGi-ifying some of our dependencies that weren't.

I'm currently stuck on this issue though, if you have any ideas. I get this error if I supply Wicket as a stand-alone bundle or if I embed it inside my war and add it to the bundle classpath.

[2015-07-31T06:45:25.200Z] [ERROR] start-signalling-1            o.a.c.c.C.[Catalina].[localhost].[/vsphere-client/rssdm-ui]       Exception starting filter rssdm java.lang.NoClassDefFoundError: org.apache.wicket.protocol.http.WicketFilter not found from bundle [com.micron.rssdmui.rssdm-ui_1.0.0 [274]]

  at org.eclipse.gemini.web.tomcat.internal.loading.BundleDelegatingClassLoader.findClass(BundleDelegatingClassLoader.java:107)

  at org.eclipse.gemini.web.tomcat.internal.loading.BundleDelegatingClassLoader.loadClass(BundleDelegatingClassLoader.java:139)

  at java.lang.ClassLoader.loadClass(Unknown Source)

  at org.eclipse.gemini.web.tomcat.internal.loading.ChainedClassLoader.doLoadClass(ChainedClassLoader.java:174)

  at org.eclipse.gemini.web.tomcat.internal.loading.ChainedClassLoader.loadClass(ChainedClassLoader.java:164)

  at org.eclipse.gemini.web.tomcat.internal.loading.BundleWebappClassLoader.loadClass(BundleWebappClassLoader.java:298)

  at java.lang.ClassLoader.loadClass(Unknown Source)

  at org.apache.catalina.core.DefaultInstanceManager.loadClass(DefaultInstanceManager.java:529)

  at org.apache.catalina.core.DefaultInstanceManager.loadClassMaybePrivileged(DefaultInstanceManager.java:511)

  at org.apache.catalina.core.DefaultInstanceManager.newInstance(DefaultInstanceManager.java:139)

  at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:258)

  at org.apache.catalina.core.ApplicationFilterConfig.<init>(ApplicationFilterConfig.java:105)

  at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4809)

  at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5485)

  at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)

  at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)

  at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)

  at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:632)

  at org.eclipse.gemini.web.tomcat.internal.TomcatServletContainer.startWebApplication(TomcatServletContainer.java:125)

  at org.eclipse.gemini.web.internal.StandardWebApplication.start(StandardWebApplication.java:109)

  at org.eclipse.virgo.web.core.internal.WebBundleLifecycleListener.onStarted(WebBundleLifecycleListener.java:122)

  at org.eclipse.virgo.kernel.install.artifact.internal.StandardArtifactStateMonitor.onStarted(StandardArtifactStateMonitor.java:271)

  at org.eclipse.virgo.kernel.install.artifact.internal.AbstractInstallArtifact.asyncStartSucceeded(AbstractInstallArtifact.java:319)

  at org.eclipse.virgo.kernel.install.artifact.internal.AbstractInstallArtifact.access$0(AbstractInstallArtifact.java:316)

  at org.eclipse.virgo.kernel.install.artifact.internal.AbstractInstallArtifact$StateMonitorSignal.signalSuccessfulCompletion(AbstractInstallArtifact.java:252)

  at org.eclipse.virgo.nano.core.internal.BundleStartTracker$1.run(BundleStartTracker.java:140)

  at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)

  at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)

  at java.lang.Thread.run(Unknown Source)

Caused by: org.eclipse.virgo.kernel.osgi.framework.ExtendedNoClassDefFoundError: javax/servlet/Filter in KernelBundleClassLoader: [bundle=com.micron.rssdmui.rssdm-ui_1.0.0] in KernelBundleClassLoader: [bundle=com.micron.rssdmui.rssdm-ui_1.0.0]

  at org.eclipse.virgo.kernel.userregion.internal.equinox.KernelBundleClassLoader.loadClass(KernelBundleClassLoader.java:152)

  at java.lang.ClassLoader.loadClass(Unknown Source)

  at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:340)

  at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)

  at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1212)

  at org.eclipse.gemini.web.tomcat.internal.loading.BundleDelegatingClassLoader.findClass(BundleDelegatingClassLoader.java:91)

  ... 28 common frames omitted

Caused by: org.eclipse.virgo.kernel.osgi.framework.ExtendedNoClassDefFoundError: javax/servlet/Filter in KernelBundleClassLoader: [bundle=com.micron.rssdmui.rssdm-ui_1.0.0]

  at org.eclipse.virgo.kernel.userregion.internal.equinox.KernelBundleClassLoader.defineClass(KernelBundleClassLoader.java:255)

  at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.defineClassHoldingLock(ClasspathManager.java:632)

  at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.defineClass(ClasspathManager.java:607)

  at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findClassImpl(ClasspathManager.java:568)

  at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findLocalClassImpl(ClasspathManager.java:492)

  at org.eclipse.osgi.baseadaptor.loader.ClasspathManager.findLocalClass(ClasspathManager.java:465)

  at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.findLocalClass(DefaultClassLoader.java:216)

  at org.eclipse.osgi.internal.loader.BundleLoader.findLocalClass(BundleLoader.java:395)

  at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:464)

  at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:421)

  at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:412)

  at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)

  at org.eclipse.virgo.kernel.userregion.internal.equinox.KernelBundleClassLoader.loadClass(KernelBundleClassLoader.java:146)

  ... 33 common frames omitted

Caused by: java.lang.NoClassDefFoundError: javax/servlet/Filter

  at java.lang.ClassLoader.defineClass1(Native Method)

  at java.lang.ClassLoader.defineClass(Unknown Source)

  at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.defineClass(DefaultClassLoader.java:188)

  at org.eclipse.virgo.kernel.userregion.internal.equinox.KernelBundleClassLoader.defineClass(KernelBundleClassLoader.java:251)

  ... 45 common frames omitted

Caused by: org.eclipse.virgo.kernel.osgi.framework.ExtendedClassNotFoundException: javax.servlet.Filter in KernelBundleClassLoader: [bundle=com.micron.rssdmui.rssdm-ui_1.0.0]

  at org.eclipse.virgo.kernel.userregion.internal.equinox.KernelBundleClassLoader.loadClass(KernelBundleClassLoader.java:150)

  at java.lang.ClassLoader.loadClass(Unknown Source)

  ... 49 common frames omitted

Caused by: java.lang.ClassNotFoundException: javax.servlet.Filter

  at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:501)

  at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:421)

  at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:412)

  at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)

  at org.eclipse.virgo.kernel.userregion.internal.equinox.KernelBundleClassLoader.loadClass(KernelBundleClassLoader.java:146)

  ... 50 common frames omitted

Reply
0 Kudos
laurentsd
VMware Employee
VMware Employee

> Exception starting filter rssdm java.lang.NoClassDefFoundError: org.apache.wicket.protocol.http.WicketFilter not found from bundle [com.micron.rssdmui.rssdm-ui_1.0.0 [274]]


Check that the bundle's MANIFEST.MF contains package "org.apache.wicket.protocol.http" in the list of exported packages.

Reply
0 Kudos
Peter_Ivanov
VMware Employee
VMware Employee

Hi,

Few comments from my side:

1. From your initial post I can see the following:

Import-Package: org.apache.wicket.protocol.http.WicketFilter

You should not include the class name. You need only the package:

Import-Package: org.apache.wicket.protocol.http

2. I see that wicket-core depends on wicket-util and wicket-request. So you might need to add those too in your was and manifest.

3. In your stack trace I see the following

Caused by: java.lang.ClassNotFoundException: javax.servlet.Filter

  at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:501)

This means that it is not the WicketFilter that cannot be found. It is the javax.servlet.Filter that cannot be found and WicketFilter implements that:

publicclass WicketFilter implements Filter

Please add javax.servlet to your Import-Packages and try again.

Reply
0 Kudos
vromanowski
Enthusiast
Enthusiast

It looks like I'm getting pretty close, but there's another class loading issue. It looks like BundleWebappClassLoader can't find my web application class, even though com.micron.rssdm.gui.web it is in my export packages?

[2015-08-05T00:28:29.202Z] [ERROR] start-signalling-2            o.a.c.c.C.[Catalina].[localhost].[/vsphere-client/rssdm-ui]       Exception starting filter rssdm org.apache.wicket.WicketRuntimeException: Unable to create application of class com.micron.rssdm.gui.web.RSSDMWebApplication

  at org.apache.wicket.protocol.http.ContextParamWebApplicationFactory.createApplication(ContextParamWebApplicationFactory.java:85)

  at org.apache.wicket.protocol.http.ContextParamWebApplicationFactory.createApplication(ContextParamWebApplicationFactory.java:49)

  at org.apache.wicket.protocol.http.WicketFilter.init(WicketFilter.java:337)

  at org.apache.wicket.protocol.http.WicketFilter.init(WicketFilter.java:312)

  at org.apache.catalina.core.ApplicationFilterConfig.initFilter(ApplicationFilterConfig.java:279)

  at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:260)

  at org.apache.catalina.core.ApplicationFilterConfig.<init>(ApplicationFilterConfig.java:105)

  at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4809)

  at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5485)

  at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)

  at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)

  at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)

  at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:632)

  at org.eclipse.gemini.web.tomcat.internal.TomcatServletContainer.startWebApplication(TomcatServletContainer.java:125)

  at org.eclipse.gemini.web.internal.StandardWebApplication.start(StandardWebApplication.java:109)

  at org.eclipse.virgo.web.core.internal.WebBundleLifecycleListener.onStarted(WebBundleLifecycleListener.java:122)

  at org.eclipse.virgo.kernel.install.artifact.internal.StandardArtifactStateMonitor.onStarted(StandardArtifactStateMonitor.java:271)

  at org.eclipse.virgo.kernel.install.artifact.internal.AbstractInstallArtifact.asyncStartSucceeded(AbstractInstallArtifact.java:319)

  at org.eclipse.virgo.kernel.install.artifact.internal.AbstractInstallArtifact.access$0(AbstractInstallArtifact.java:316)

  at org.eclipse.virgo.kernel.install.artifact.internal.AbstractInstallArtifact$StateMonitorSignal.signalSuccessfulCompletion(AbstractInstallArtifact.java:252)

  at org.eclipse.virgo.nano.core.internal.BundleStartTracker$1.run(BundleStartTracker.java:140)

  at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)

  at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)

  at java.lang.Thread.run(Unknown Source)

Caused by: java.lang.ClassNotFoundException: com.micron.rssdm.gui.web.RSSDMWebApplication

  at org.eclipse.gemini.web.tomcat.internal.loading.BundleWebappClassLoader.loadClass(BundleWebappClassLoader.java:312)

  at java.lang.ClassLoader.loadClass(Unknown Source)

  at java.lang.Class.forName0(Native Method)

  at java.lang.Class.forName(Unknown Source)

  at org.apache.wicket.protocol.http.ContextParamWebApplicationFactory.createApplication(ContextParamWebApplicationFactory.java:71)

  ... 23 common frames omitted

Reply
0 Kudos
Peter_Ivanov
VMware Employee
VMware Employee

It will be helpful if you provide the full stack traces.

Also if you could post the whole MANIFEST.MF file, that would really help me resolve your problem faster.

From the stack trace you've pasted

at java.lang.Class.forName(Unknown Source)

  at org.apache.wicket.protocol.http.ContextParamWebApplicationFactory.createApplication(ContextParamWebApplicationFactory.java:71)

seems that wicket library uses Class.forName to instantiate your class.

One important question:

How do you consume the apache wicket library? Do you include it in your jar/war file? Do you copy it in the repository? This is very important because the class loading behavior is different.

Another important question:

Do you get this error during bundle deployment (i.e. on startup) or when you login the client and go to your view?

I assume it is the later considering that there is a BundleWebappClassLoader... but just to double-check.

Reply
0 Kudos
Peter_Ivanov
VMware Employee
VMware Employee

OK, now I answered myself some of the questions from your initial post.

So you include the wicket.jar in your project. But is it a war or a jar?

Import-Package: org.apache.wicket.protocol.http.WicketFilter

Bundle-ClassPath: .,wicket-core-1.5.8.jar

If you include the jar in your bundle and add it to the Bundle-ClassPath, then you should NOT include it in the Import-Package.

Reply
0 Kudos
Peter_Ivanov
VMware Employee
VMware Employee

I am reading between the lines again Smiley Happy So you have a war file with wicket.jar embedded.


Let's focus on these questions:

1. Do you get this error during bundle deployment (i.e. on startup) or when you login the client and go to your view?

2. Please post the full stack traces.

3. Please post the whole MANIFEST.MF file (you can sanitize it of course).

Reply
0 Kudos
Peter_Ivanov
VMware Employee
VMware Employee

One more thing to try:

Can you verify that you have your classes (com.micron.rssdm.gui.web.RSSDMWebApplication) actually in your war file? I guess they will be under WEB-INF/classes.

Then add the 'classes' to your Bundle-ClassPath in the MANIFEST.MF file:

     Bundle-ClassPath: .,wicket-core-1.5.8.jar, classes




Reply
0 Kudos
vromanowski
Enthusiast
Enthusiast

Really appreciate you taking time to help! I've attached a large portion of the log, manifest and web.xml - replaced our company/domain with <removed>.

Also the manifest at the top of this post is no longer what I've been using as you'll see from the attachment - I used a program called Bundlor to generate the manifest.

I'll answer all your questions in order

How do you consume the apache wicket library? Do you include it in your jar/war file? Do you copy it in the repository? This is very important because the class loading behavior is different.

I've tried doing it both ways, but I seem to get further along by embedding the wicket jars inside my war file. When I had the Wicket jars external, I had them listed in the plugin-package xml in the proper order.

Do you get this error during bundle deployment (i.e. on startup) or when you login the client and go to your view?

I actually seem to be getting the error on startup/bundle deployment.

So you include the wicket.jar in your project. But is it a war or a jar? If you include the jar in your bundle and add it to the Bundle-ClassPath, then you should NOT include it in the Import-Package.

War file. I don't see any wicket packages in my Import-Package list, only in the Export-Package list and in the Bundle-ClassPath.

Can you verify that you have your classes (com.micron.rssdm.gui.web.RSSDMWebApplication) actually in your war file?

The class is definitely in the WAR file, I can see it when drilling in.

Then add the 'classes' to your Bundle-ClassPath in the MANIFEST.MF file:

I just tried appending 'classes' to my Bundle-ClassPath but I still get the same stack trace

Reply
0 Kudos
Peter_Ivanov
VMware Employee
VMware Employee

Hi,

I created a sample bundle that uses Wicket.

I used this example: Hello World! | Apache Wicket

My MANIFEST.MF is fairly simple:

Manifest-Version: 1.0

Export-Package: com.vmware.wicket;version="6.0.0"

Bundle-ClassPath: .

Bundle-SymbolicName: com.vmware.wicket.test

Bundle-Name: wicket-test

Build-Jdk: 1.7.0_21

Bundle-Version: 6.0.0

Web-ContextPath: vsphere-client/wicket

Bundle-ManifestVersion: 2

Import-Package: javax.crypto,javax.crypto.spec,javax.imageio,javax.ser

vlet;version="[3.0,4)",javax.servlet.http;version="[3.0,4)",javax.swi

ng.event,javax.swing.text,javax.swing.tree,javax.xml.parsers,javax.xm

l.transform,javax.xml.transform.stream,org.slf4j;version="[1.6,2)",

org.w3c.dom,org.xml.sax

And this is the project structure:

Screen Shot 2015-08-07 at 4.23.52 PM.png

The Import-Package was generated by the maven bundle plugin.

Reply
0 Kudos
Peter_Ivanov
VMware Employee
VMware Employee

I even deleted to Export-Package from the manifest and it is still working. And it makes sense because the class is in the same bundle as wicket.jar.

Reply
0 Kudos
Peter_Ivanov
VMware Employee
VMware Employee

I played around with the bundle manifest. It seems that you can export package com.foo without actually having this package in your bundle. And the virgo server will con complain about it...

I looked at the files that you have uploaded.

1. web.xml - seems fine.

2. MANIFEST.MF - If your plugin will consist of only one bundle, you don't really need to export anything.

Please be extra careful when using automated generation of manifests. You should not export packages from the nested jars.

For example I can see that your bundle exposes:

org.apache.wicket;version="1.0.0";uses:="........"

com.vmware.vim.cf;version="1.0.0";uses:="com.vmware.vim25,com.vmware.vim25.mo",

com.vmware.vim.rest;version="1.0.0";uses:="javax.net.ssl,javax.xml.xpath",

com.vmware.vim25;version="1.0.0";uses:="com.vmware.vim25.ws",

com.vmware.vim25.mo;version="1.0.0";uses:="com.vmware.vim25"


You must not do that! Configure the bundlor to exclude those package you the generated manifest.


3. vsphere_client_virgo.log

Caused by: java.lang.ClassNotFoundException: com.<removed>.rssdm.gui.web.RSSDMWebApplication

  at org.eclipse.gemini.web.tomcat.internal.loading.BundleWebappClassLoader.loadClass(BundleWebappClassLoader.java:312)

  at java.lang.ClassLoader.loadClass(Unknown Source)

  at java.lang.Class.forName0(Native Method)

  at java.lang.Class.forName(Unknown Source)

  at org.apache.wicket.protocol.http.ContextParamWebApplicationFactory.createApplication(ContextParamWebApplicationFactory.java:71)

  ... 23 common frames omitted


Can you tell me where is this file in your bundle?

Can you send me your war file to look at its structure? You can remove all the code except RSSDMWebApplication.class.

The problem doesn't seem to be in the manifest...



Reply
0 Kudos
vromanowski
Enthusiast
Enthusiast

I attached a stripped down war file.

I want to make a note that I also have tried putting all the jar files under /WEB-INF/lib but it doesn't seem to make a difference compared to having them at the root of the war file 😕

Reply
0 Kudos
Peter_Ivanov
VMware Employee
VMware Employee

Hi,

I managed to successfully deploy your code. I modified your manifest a bit, but the problem IMO is not there.

I have created my custom RSSDMWebApplication class in order to remove the dependencies to other classes (see attached).

According to me the problem is in the RSSDMWebApplication$1.class. This should be some inner class that extends ResourceReference.

Can you try to make that inner class static? Or even better create a regular class for it?

I don't have your original code, but the problem seems similar to this one:

http://stackoverflow.com/questions/27764018/why-does-class-newinstance-always-throw-an-exception

Reply
0 Kudos
Peter_Ivanov
VMware Employee
VMware Employee

I managed to reproduce your problem. If you have your  RSSDMWebApplication class like this:

public class RSSDMWebApplication extends WebApplication {

public RSSDMWebApplication() {

     super();

     ResourceReference ref = new ResourceReference("some key") {

        @Override

        public IResource getResource() {

           // TODO Auto-generated method stub

           return null;

        }

      };

  }

}

When this class is built, it results in two class files:

RSSDMWebApplication.class

RSSDMWebApplication$1.class

Then when I deploy the war file I receive the same error as you do:

Caused by: java.lang.ClassNotFoundException: com.micron.rssdm.gui.web.RSSDMWebApplication

  at org.eclipse.gemini.web.tomcat.internal.loading.BundleWebappClassLoader.loadClass(BundleWebappClassLoader.java:312)

  at java.lang.ClassLoader.loadClass(ClassLoader.java:356)

  at java.lang.Class.forName0(Native Method)

  at java.lang.Class.forName(Class.java:266)

  at org.apache.wicket.protocol.http.ContextParamWebApplicationFactory.createApplication(ContextParamWebApplicationFactory.java:71)

  ... 23 common frames omitted

So the solution is to remove this anonymous class into a separate file.

vromanowski: Please let me know if this is your case and if the solution works for you.

Reply
0 Kudos
vromanowski
Enthusiast
Enthusiast

OK I tried that, I actually removed that inner class as it wasn't needed any longer. I made sure there wasn't an addition anonymous class file in the .war file.

I tried again and updated the manifest to only have the one package in the export packages. Same exact exception though.

I think tomorrow I'll have some more time to mess around with it more... feels like we're so close...

Reply
0 Kudos
Peter_Ivanov
VMware Employee
VMware Employee

Please try to deploy my war file and see if it works for you.

It works with empty RSSDMWebApplication class, i.e. the class is in the class path and is visible by the class loader. The problem should be either in the implementation or in the referenced classes.

I would recommend to start with something very simple and gradually add more and more classes.

At this point there is nothing more that I can do without debugging your code. You could send it privately only to me.


Please post any update that you have.

Reply
0 Kudos
vromanowski
Enthusiast
Enthusiast

I got your war to deploy without any errors. Is there a way I can send the war to you privately? I don't see a message option

edit: even if i strip everything out of our RSSDMWebApplication class, it still throws the exception

Reply
0 Kudos