cancel
Showing results for 
Search instead for 
Did you mean: 

Activiti Explorer 5.16.4 deployment to Weblogic Java 6

ivan_activiti
Champ in-the-making
Champ in-the-making
I am trying to deploy activiti-webapp-explorer2 5.16.4 module to Weblogic running on Java 6 and I am getting the following exception:

java.lang.ClassNotFoundException: javax.servlet.ServletRegistration$Dynamic

The same exception appears with activiti-explorer.war from activiti-5.16.4\wars folder. I had Explorer 5.16.3 running with no issues. What am I missing?

Thanks,
–Ivan
10 REPLIES 10

jbarrez
Star Contributor
Star Contributor
version 15.16.4 switched to Spring Java config instead of XML (see https://github.com/Activiti/Activiti/blob/master/modules/activiti-webapp-explorer2/src/main/java/org...)

So it seems like this class is missing on Weblogic Smiley Sad Which version of WebLogic is this?

This seems to be consistent though: http://stackoverflow.com/questions/9531853/dynamic-add-servlet-in-weblogic-12c-not-work

So it seems for Weblogic another way of initializing must be used … But i can't find immediately what that option should be (except reverting to XML)

ivan_activiti
Champ in-the-making
Champ in-the-making
We are on Weblogic 10.3.6.0.

ralferic
Champ in-the-making
Champ in-the-making
I ran into that very same problem. As far as i can see, this is because activity now requires Servlet 3.0. (Please see Stacktrace below) Tomcat 6 is Servlet 2.5 only. The new WebConfigurer-class uses ServletRegistration.Dynamic, which is not available in Servlet-API 2.5. I would have expected this to be clearly documented. Even worse: activity installation guide is referring to Tomcat 6 and requires quite a bit of changes for Tomcat 7. An installtion guide that can not possibly work really does give me second thougths about using activity.

SCHWERWIEGEND: Error configuring application listener of class org.activiti.explorer.servlet.WebConfigurer
java.lang.NoClassDefFoundError: javax/servlet/ServletRegistration$Dynamic
at java.lang.Class.getDeclaredMethods0(Native Method)
at java.lang.Class.privateGetDeclaredMethods(Class.java:2539)
at java.lang.Class.getDeclaredMethods(Class.java:1860)
at org.apache.catalina.util.DefaultAnnotationProcessor.processAnnotations(DefaultAnnotationProcessor.java:226)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4153)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4705)
at org.apache.catalina.manager.ManagerServlet.start(ManagerServlet.java:1276)
at org.apache.catalina.manager.HTMLManagerServlet.start(HTMLManagerServlet.java:625)
at org.apache.catalina.manager.HTMLManagerServlet.doGet(HTMLManagerServlet.java:136)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.filters.CsrfPreventionFilter.doFilter(CsrfPreventionFilter.java:193)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:563)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:859)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:602)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)
at java.lang.Thread.run(Thread.java:701)
Caused by: java.lang.ClassNotFoundException: javax.servlet.ServletRegistration$Dynamic
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1680)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1526)
… 27 more

ralferic
Champ in-the-making
Champ in-the-making
Sorry, i referred to Tomcat 6. But as far as i know, Weblogic 10.3.6.0 is also Servlet 2.5.

jbarrez
Star Contributor
Star Contributor
We are aware of it and will update our docs in the 5.17 release. We didn't test it on Websphere (limited team and time, you know the drill) There is nothing wrong with using 5.16.3 at the moment though.

> An installtion guide that can not possibly work really does give me second thougths about using activity.

Ok, it's a free world and your choice. Alternatively, you could also step in and help us out here. We've got a limited amount of people and a limited amount of time and we would welcome for sure any patches that make it run on current websphere servers!

Also: it's Activiti with a i.

priya1
Champ in-the-making
Champ in-the-making
Do you have any plans to make Activiti 5.17 or 5.16.4 backward compatible  to suport Servlet 2.5

jbarrez
Star Contributor
Star Contributor
No, currently no plans. Unless somebody provides a patch to make it working on these app servers (while still working on the new ones)  ..(servlet 3 is also already from 2009)

ndup0nt
Champ in-the-making
Champ in-the-making
I'm thinking about creating such a patch.

From what I see in the source code :
* activiti-explorer (the project) relies on servlet 2.5 API
* the web.xml is also compliant with servlet 2.5
* only a few classes in activiti-webapp-explorer2 actually relies on Servlet 3.0

It looks like the only point is that the DispatcherServlet is programmatically configured (using Servlet 3.0) instead of web.xml. So basically I would only have to change this ? Am I missing something ?

jbarrez
Star Contributor
Star Contributor
That is a correct analysis.

We would for sure welcome such a patch!