WebSphere 8 Support for Vaadin 6.6.4?

Howdy,

I just wondered, if anyone has been successful in running Vaadin applications on the IBM WebSphere 8 Platform? I tried to run a small custom made Vaadin application on the WebSphere Application Server for Developers V8 32bit (http://www.ibm.com/developerworks/downloads/ws/wasdevelopers) and it produced the exception trace shown later in this post.

Afterwards I tried to deploy the official Vaadin test application (vaadin-demo-6.6.4.war) on the Application Server, but that produced the same result. Both of these applications run fine for instance inside Tomcat.

I also tried to add gwt user dependencies to the libraries, but that does not seem to work as everything needed should be in vaadin-6.6.4.jar, right?

Of Course this could be somehow related to other factors in the environment (CentOs 6), but any help would be appreciated,
Janne

Stack Trace:

Application E Terminal error:
java.lang.NoClassDefFoundError: com.google.gwt.user.client.ui.PopupPanel
at java.lang.ClassLoader.defineClassImpl(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:260)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:69)
at com.ibm.ws.classloader.CompoundClassLoader._defineClass(CompoundClassLoader.java:828)
at com.ibm.ws.classloader.CompoundClassLoader.localFindClass(CompoundClassLoader.java:743)
at com.ibm.ws.classloader.CompoundClassLoader.loadClass(CompoundClassLoader.java:566)
at java.lang.ClassLoader.loadClass(ClassLoader.java:612)
at java.lang.ClassLoader.defineClassImpl(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:260)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:69)
at com.ibm.ws.classloader.CompoundClassLoader._defineClass(CompoundClassLoader.java:828)
at com.ibm.ws.classloader.CompoundClassLoader.localFindClass(CompoundClassLoader.java:743)
at com.ibm.ws.classloader.CompoundClassLoader.loadClass(CompoundClassLoader.java:566)
at java.lang.ClassLoader.loadClass(ClassLoader.java:612)
at java.lang.Class.forNameImpl(Native Method)
at java.lang.Class.forName(Class.java:166)
at com.ibm.oti.reflect.AnnotationParser.parseClass(AnnotationParser.java:203)
at com.ibm.oti.reflect.AnnotationParser.parseElementValue(AnnotationParser.java:156)
at com.ibm.oti.reflect.AnnotationParser.parseAnnotation(AnnotationParser.java:131)
at com.ibm.oti.reflect.AnnotationParser.parseAnnotations(AnnotationParser.java:57)
at java.lang.Class.getDeclaredAnnotations(Class.java:1652)
at java.lang.Class.getAnnotations(Class.java:1615)
at java.lang.Class.getAnnotation(Class.java:1589)
at java.lang.Class.isAnnotationPresent(Class.java:1683)
at com.vaadin.terminal.gwt.server.JsonPaintTarget.hasClientWidgetMapping(JsonPaintTarget.java:1051)
at com.vaadin.terminal.gwt.server.JsonPaintTarget.getTag(JsonPaintTarget.java:1026)
at com.vaadin.ui.AbstractComponent.paint(AbstractComponent.java:708)
at com.vaadin.terminal.gwt.server.AbstractCommunicationManager.writeUidlResponce(AbstractCommunicationManager.java:954)
at com.vaadin.terminal.gwt.server.AbstractCommunicationManager.paintAfterVariableChanges(AbstractCommunicationManager.java:841)
at com.vaadin.terminal.gwt.server.AbstractCommunicationManager.doHandleUidlRequest(AbstractCommunicationManager.java:767)
at com.vaadin.terminal.gwt.server.CommunicationManager.handleUidlRequest(CommunicationManager.java:296)
at com.vaadin.terminal.gwt.server.AbstractApplicationServlet.service(AbstractApplicationServlet.java:501)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:668)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1147)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:722)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:449)
at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:178)
at com.ibm.ws.webcontainer.filter.WebAppFilterChain.invokeTarget(WebAppFilterChain.java:125)
at com.ibm.ws.webcontainer.filter.WebAppFilterChain.doFilter(WebAppFilterChain.java:77)
at com.ibm.ws.webcontainer.filter.WebAppFilterManager.doFilter(WebAppFilterManager.java:919)
at com.ibm.ws.webcontainer.filter.WebAppFilterManager.invokeFilters(WebAppFilterManager.java:1016)
at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3639)
at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:304)
at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:950)
at com.ibm.ws.webcontainer.WSWebContainer.handleRequest(WSWebContainer.java:1659)
at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:195)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:452)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewRequest(HttpInboundLink.java:511)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.processRequest(HttpInboundLink.java:305)
at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:83)
at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165)
at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161)
at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138)
at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204)
at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:775)
at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1648)
Caused by: java.lang.ClassNotFoundException: com.google.gwt.user.client.ui.PopupPanel
at java.net.URLClassLoader.findClass(URLClassLoader.java:434)
at com.ibm.ws.bootstrap.ExtClassLoader.findClass(ExtClassLoader.java:198)
at java.lang.ClassLoader.loadClass(ClassLoader.java:646)
at com.ibm.ws.bootstrap.ExtClassLoader.loadClass(ExtClassLoader.java:113)
at java.lang.ClassLoader.loadClass(ClassLoader.java:612)
at com.ibm.ws.classloader.ProtectionClassLoader.loadClass(ProtectionClassLoader.java:62)
at com.ibm.ws.classloader.ProtectionClassLoader.loadClass(ProtectionClassLoader.java:58)
at com.ibm.ws.classloader.CompoundClassLoader.loadClass(CompoundClassLoader.java:596)
at java.lang.ClassLoader.loadClass(ClassLoader.java:612)
at com.ibm.ws.classloader.CompoundClassLoader.loadClass(CompoundClassLoader.java:564)
at java.lang.ClassLoader.loadClass(ClassLoader.java:612)
… 58 more

Hi

It seems that WebSphere 7 on Linux works fine with the Vaadin Demo Application.

Janne

Hello,

I’ve not tried using WebSphere (frankly, I’d rather poke myself in the eyes repeatedly with a fork), but I’ve done a very quick bit of research. Looking at that stacktrace,

java.lang.NoClassDefFoundError: com.google.gwt.user.client.ui.PopupPanel
[...]
at java.lang.Class.forName(Class.java:166)
at com.ibm.oti.reflect.AnnotationParser.parseClass(AnnotationParser.java:203)
at com.ibm.oti.reflect.AnnotationParser.parseElementValue(AnnotationParser.java:156)
at com.ibm.oti.reflect.AnnotationParser.parseAnnotation(AnnotationParser.java:131)
at com.ibm.oti.reflect.AnnotationParser.parseAnnotations(AnnotationParser.java:57)
at java.lang.Class.getDeclaredAnnotations(Class.java:1652)
at java.lang.Class.getAnnotations(Class.java:1615)
at java.lang.Class.getAnnotation(Class.java:1589)
at java.lang.Class.isAnnotationPresent(Class.java:1683)
at com.vaadin.terminal.gwt.server.JsonPaintTarget.hasClientWidgetMapping(JsonPaintTarget.java:1051)

this shows that the Vaadin is checking to see if a class has a ClientWidget annotation (this is used in Vaadin for something technical to tie the “Client” sIde and “Server Side” portions of UI COde together). It appears that the IBM JVM (used by Weblogic) attempts to load classes referenced in an Annotation.

This is not specific to Vaadin -
Seam has the same problem

This issue also appears to almost identical to a problem that appears on GlassFish, which has been coded around in Vaadin for ticket
#3920

I would suggest that the fix for #3920 be extended to cope with the IBM JVM (it currently checks for the GlassFish classloader, and does a hinky workaround), as I think this will prevent Vaadin running in any J2EE Webserver on an IBM JVM (not just Websphere), which would be a bad thing IMHO - I’m thinking of IBM big iron machines such as s390, zSeries and iSeries, all of which can only run an IBM JVM (and which we will probably have to deploy on at some point!)

In the short term, you might be able to get away with adding the gwt-user.jar to the Websphere classpath, although I couldn’t be sure.

Cheers,

Charles.

Howdy,

Spoon, fork or I guess any other kitchen utensil would probably be in order for the eye poking :wink: Thank you for the very quick response and explanation.

I tried including the gwt jars already, but unfortunately that causes another exception (i.e., “gwt meant only to be used as compiled JS”) and therefore does not work. However, this is not a problem in my current scenario as I can use the WebSphere version 7 for the deployment.

Probably though this problem needs to be addressed sooner or later, since at least in Finland WebSphere (or WebSphere Portal) is a fairly prominent application platform.

Cheers and again thanks for the response
Janne

Hello,

I have been evaluating Vaadin on WebSphere 8 and have encountered the same problem as described here. I would like to know whether you are going to provide a work around as you have done for Glassfish?

Thanks

Vaadin should support “IBM WebSphere Application Server, version 6.1 or later”. So this can be considered a bug, please create report at dev.vaadin.com.


#7479
created.

Has anyone here tested the fix provided in the ticket?
It doesnt seem to work in my machine.
You can see the exception i get at
#7479

I’ve not tested it, as I don’t have a Websphere 8 environment to test on.

The problem is fixed in http://dev.vaadin.com/ticket/7479

Another problem is that if i try to use CDI with Vaadin in Websphere 8 (as described in https://vaadin.com/wiki/-/wiki/Main/Creating%20JEE6%20Vaadin%20Applications)
i get the same type of exceptions.

I don’t know if this is something that Vaadin developers can fix or it is Websphere 8 JVM fault.

Caused by: java.lang.NoClassDefFoundError: com.google.gwt.user.client.ui.SimplePanel
at java.lang.ClassLoader.defineClassImpl(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:260)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:69)
at com.ibm.ws.classloader.CompoundClassLoader._defineClass(CompoundClassLoader.java:828)
at com.ibm.ws.classloader.CompoundClassLoader.localFindClass(CompoundClassLoader.java:743)
at com.ibm.ws.classloader.CompoundClassLoader.loadClass(CompoundClassLoader.java:566)
at java.lang.ClassLoader.loadClass(ClassLoader.java:612)
at java.lang.Class.forNameImpl(Native Method)
at java.lang.Class.forName(Class.java:166)
at com.ibm.oti.reflect.AnnotationParser.parseClass(AnnotationParser.java:203)
at com.ibm.oti.reflect.AnnotationParser.parseElementValue(AnnotationParser.java:156)
at com.ibm.oti.reflect.AnnotationParser.parseAnnotation(AnnotationParser.java:131)
at com.ibm.oti.reflect.AnnotationParser.parseAnnotations(AnnotationParser.java:57)
at java.lang.Class.getDeclaredAnnotations(Class.java:1652)
at java.lang.Class.getAnnotations(Class.java:1615)
at java.lang.Class.getAnnotation(Class.java:1589)
at com.ibm.wsspi.injectionengine.InjectionProcessor.processClassAnnotation(InjectionProcessor.java:906)
at com.ibm.wsspi.injectionengine.InjectionProcessor.processAllAnnotations(InjectionProcessor.java:737)
at com.ibm.ws.injectionengine.AbstractInjectionEngine.processAnnotations(AbstractInjectionEngine.java:684)
at com.ibm.ws.injectionengine.AbstractInjectionEngine.processInjectionMetaData(AbstractInjectionEngine.java:457)
at com.ibm.ws.injectionengine.AbstractInjectionEngine.processInjectionMetaData(AbstractInjectionEngine.java:380)
at com.ibm.ws.webbeans.services.ResourceInjectionServiceImpl.initialize(ResourceInjectionServiceImpl.java:103)
at com.ibm.ws.webbeans.services.JCDIComponentImpl.deployedObjectStart(JCDIComponentImpl.java:376)
at com.ibm.ws.webbeans.services.JCDIComponentImpl.stateChanged(JCDIComponentImpl.java:438)
at com.ibm.ws.runtime.component.ApplicationMgrImpl.stateChanged(ApplicationMgrImpl.java:1083)
at com.ibm.ws.runtime.component.DeployedApplicationImpl.fireDeployedObjectEvent(DeployedApplicationImpl.java:1352)
at com.ibm.ws.runtime.component.DeployedModuleImpl.setState(DeployedModuleImpl.java:247)
at com.ibm.ws.runtime.component.DeployedModuleImpl.start(DeployedModuleImpl.java:635)
at com.ibm.ws.runtime.component.DeployedApplicationImpl.start(DeployedApplicationImpl.java:967)
… 48 more
Caused by: java.lang.ClassNotFoundException: com.google.gwt.user.client.ui.SimplePanel
at java.net.URLClassLoader.findClass(URLClassLoader.java:434)
at com.ibm.ws.bootstrap.ExtClassLoader.findClass(ExtClassLoader.java:198)
at java.lang.ClassLoader.loadClass(ClassLoader.java:646)
at com.ibm.ws.bootstrap.ExtClassLoader.loadClass(ExtClassLoader.java:113)
at java.lang.ClassLoader.loadClass(ClassLoader.java:612)
at com.ibm.ws.classloader.ProtectionClassLoader.loadClass(ProtectionClassLoader.java:62)
at com.ibm.ws.classloader.ProtectionClassLoader.loadClass(ProtectionClassLoader.java:58)
at com.ibm.ws.classloader.CompoundClassLoader.loadClass(CompoundClassLoader.java:564)
at java.lang.ClassLoader.loadClass(ClassLoader.java:612)
at com.ibm.ws.classloader.CompoundClassLoader.loadClass(CompoundClassLoader.java:564)
at java.lang.ClassLoader.loadClass(ClassLoader.java:612)
… 77 more