You can find the full source code for this website in the Seam package in the directory /examples/wiki. It is licensed under the LGPL.
| Online: | 21 Members of 4505 |
| Forum: Seam Users |
20. Sep 2008, 02:28 CET | Link |
I'm trying to run the Tomcat with JBoss Embedded jpa booking example. I run the build and deploy the war. I then get the following error:
ERROR [catalina.core.ContainerBase.[Catalina].[localhost].[/jboss-seam-jpa]] Error configuring application listener of class com.sun.faces.config.ConfigureListener
java.lang.NoClassDefFoundError: javax/el/CompositeELResolver
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2357)
at java.lang.Class.getConstructor0(Class.java:2671)
at java.lang.Class.newInstance0(Class.java:321)
at java.lang.Class.newInstance(Class.java:303)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3618)
at org.apache.catalina.core.StandardContext.start(StandardContext.java:4104
I find this class exists in el-api.jar which is not in the classpath. So I add el-api.jar to the WEB-INF/lib directory. I then get the following error:
INFO: JSF1048: PostConstruct/PreDestroy annotations present. ManagedBeans methods marked with these annotations will have said annotations processed.
Sep 19, 2008 5:37:50 PM com.sun.faces.config.ConfigureListener installExpressionFactory
SEVERE: Error Instantiating ExpressionFactory
java.lang.ClassNotFoundException: com.sun.el.ExpressionFactoryImpl
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1332)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1181)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:164)
at com.sun.faces.config.ConfigureListener.installExpressionFactory(ConfigureListener.java:1521)
This library appears to be in el-ri.jar or JSP 2.1 jar. Am I doing something wrong? Is there a place that explains how to run seam applications on tomcat 5.5.x? Any help is greatly appreciated!
You seem to be missing the Sun EL libs. Check whether you have the el-api.jar and el-ri.jar in your classpath. I myself am running Seam on Tomcat 5.5.26 without any problems or extra setup steps.
Thanks for the response Alex. Are you using JBoss Embedded with Tomcat 5.5.26? I am able to get this to work with Tomcat 5.5 without JBoss Embedded. Using the Seam JPA example I run ant tomcat55 and everything works fine, but when I run ant jboss-embedded I get the above errors. So, I'm wondering if I'm porting a seam EJB application from JBoss to Tomcat will I need to pull out all my EJB components and convert them into POJOs?
No, I'm using POJO components, thus no (need of) JBoss Embedded. To me, the gains of using full EJBs don't outweight the troubles of setting up the EJB container.