Fórum
PrimeFaces on Liferay 7
Matteo Gnocchi, modificado 7 Anos atrás.
PrimeFaces on Liferay 7
Junior Member Postagens: 29 Data de Entrada: 29/03/16 Postagens Recentes
Hi!
I'm trying to use PrimeFaces 6 on Liferay 7 (Tomcat Bundle).
I was able to develop a simple portlet following the com.liferay.faces.demo.primefaces.users.portlet demo.
The deployment ends without errors (says: Context initialized for contextPath=[/o/primefaces6-portlet]).
My trouble starts when I try to put the portlet on the portal and I get this error (no messages on log file):
java.lang.LinkageError: loader constraint violation: when resolving overridden method "com.liferay.faces.util.jsp.internal.PageContextStringImpl.getELContext()Ljavax/el/ELContext;" the class loader (instance of org/eclipse/osgi/internal/loader/EquinoxClassLoader) of the current class, com/liferay/faces/util/jsp/internal/PageContextStringImpl, and its superclass loader (instance of org/eclipse/osgi/internal/loader/EquinoxClassLoader), have different Class objects for the type javax/el/ELContext used in the signature
Can you help me?
Thx
I'm trying to use PrimeFaces 6 on Liferay 7 (Tomcat Bundle).
I was able to develop a simple portlet following the com.liferay.faces.demo.primefaces.users.portlet demo.
The deployment ends without errors (says: Context initialized for contextPath=[/o/primefaces6-portlet]).
My trouble starts when I try to put the portlet on the portal and I get this error (no messages on log file):
java.lang.LinkageError: loader constraint violation: when resolving overridden method "com.liferay.faces.util.jsp.internal.PageContextStringImpl.getELContext()Ljavax/el/ELContext;" the class loader (instance of org/eclipse/osgi/internal/loader/EquinoxClassLoader) of the current class, com/liferay/faces/util/jsp/internal/PageContextStringImpl, and its superclass loader (instance of org/eclipse/osgi/internal/loader/EquinoxClassLoader), have different Class objects for the type javax/el/ELContext used in the signature
Can you help me?
Thx
Vernon Singleton, modificado 7 Anos atrás.
RE: PrimeFaces on Liferay 7
Expert Postagens: 315 Data de Entrada: 14/01/13 Postagens Recentes
Hi Matteo,
Are you using Liferay 7 ga2?
What are the contents of the WEB-INF/lib for your portlet war?
Could you post the contents of your war's web.xml file?
Did you try building and deploying the Primefaces User portlet?
Looking forward to helping you with this.
Thanks,
Vernon
Are you using Liferay 7 ga2?
What are the contents of the WEB-INF/lib for your portlet war?
Could you post the contents of your war's web.xml file?
Did you try building and deploying the Primefaces User portlet?
Looking forward to helping you with this.
Thanks,
Vernon
Matteo Gnocchi, modificado 7 Anos atrás.
RE: PrimeFaces on Liferay 7
Junior Member Postagens: 29 Data de Entrada: 29/03/16 Postagens Recentes
Hi Vernon
Many thanks for your help!
com.liferay.faces.alloy-3.0.0-SNAPSHOT.jar
com.liferay.faces.bridge.ext-4.0.0-SNAPSHOT.jar
com.liferay.faces.portal-3.0.0-SNAPSHOT.jar
commons-fileupload-1.3.1.jar
jsf-api-2.1.29-05.jar
log4j-1.2.14.jar
com.liferay.faces.bridge.api-3.0.0-20160621.234649-27.jar
com.liferay.faces.bridge.impl-3.0.0-20160622.191403-61.jar
com.liferay.faces.util-2.0.0-20160614.202022-8.jar
commons-io-2.2.jar
jsf-impl-2.1.29-05.jar
primefaces-6.0.jar
<web-app xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" version="3.0">
<context-param>
<param-name>com.sun.faces.expressionFactory</param-name>
<param-value>org.jboss.el.ExpressionFactoryImpl</param-value>
</context-param>
<context-param>
<param-name>javax.faces.PROJECT_STAGE</param-name>
<param-value>Development</param-value>
</context-param>
<context-param>
<param-name>facelets.SKIP_COMMENTS</param-name>
<param-value>true</param-value>
</context-param>
<context-param>
<param-name>primefaces.FONT_AWESOME</param-name>
<param-value>true</param-value>
</context-param>
<servlet>
<servlet-name>Faces Servlet</servlet-name>
<servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
</web-app>
At the moment not yet
Many thanks for your help!
What are the contents of the WEB-INF/lib for your portlet war?
com.liferay.faces.alloy-3.0.0-SNAPSHOT.jar
com.liferay.faces.bridge.ext-4.0.0-SNAPSHOT.jar
com.liferay.faces.portal-3.0.0-SNAPSHOT.jar
commons-fileupload-1.3.1.jar
jsf-api-2.1.29-05.jar
log4j-1.2.14.jar
com.liferay.faces.bridge.api-3.0.0-20160621.234649-27.jar
com.liferay.faces.bridge.impl-3.0.0-20160622.191403-61.jar
com.liferay.faces.util-2.0.0-20160614.202022-8.jar
commons-io-2.2.jar
jsf-impl-2.1.29-05.jar
primefaces-6.0.jar
Could you post the contents of your war's web.xml file?
<web-app xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" version="3.0">
<context-param>
<param-name>com.sun.faces.expressionFactory</param-name>
<param-value>org.jboss.el.ExpressionFactoryImpl</param-value>
</context-param>
<context-param>
<param-name>javax.faces.PROJECT_STAGE</param-name>
<param-value>Development</param-value>
</context-param>
<context-param>
<param-name>facelets.SKIP_COMMENTS</param-name>
<param-value>true</param-value>
</context-param>
<context-param>
<param-name>primefaces.FONT_AWESOME</param-name>
<param-value>true</param-value>
</context-param>
<servlet>
<servlet-name>Faces Servlet</servlet-name>
<servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
</web-app>
Did you try building and deploying the Primefaces User portlet?
At the moment not yet
Vernon Singleton, modificado 7 Anos atrás.
RE: PrimeFaces on Liferay 7
Expert Postagens: 315 Data de Entrada: 14/01/13 Postagens Recentes
Hi Matteo,
Thanks for your clear response.
The first thing that I see is that you are using jsf-impl-2.1.29-05.jar , but Liferay 7 is only supporting JSF 2.2 for now. You can look here at the Liferay Faces Version Scheme. You will see that Liferay 7 will require master branch (version 5.0.x) com.liferay.faces.bridge.ext-5.0.0.jar for Liferay 7.0.x, and hence JSF 2.2.
I have not had a chance to go through your web.xml yet, but let's get the dependency versions fixed first. You should be able to follow the versions in version scheme.
Hope that helps.
- Vernon
Thanks for your clear response.
Matteo Gnocchi:
...
com.liferay.faces.alloy-3.0.0-SNAPSHOT.jar
com.liferay.faces.bridge.ext-4.0.0-SNAPSHOT.jar
com.liferay.faces.portal-3.0.0-SNAPSHOT.jar
commons-fileupload-1.3.1.jar
jsf-api-2.1.29-05.jar
log4j-1.2.14.jar
com.liferay.faces.bridge.api-3.0.0-20160621.234649-27.jar
com.liferay.faces.bridge.impl-3.0.0-20160622.191403-61.jar
com.liferay.faces.util-2.0.0-20160614.202022-8.jar
commons-io-2.2.jar
jsf-impl-2.1.29-05.jar
primefaces-6.0.jar
The first thing that I see is that you are using jsf-impl-2.1.29-05.jar , but Liferay 7 is only supporting JSF 2.2 for now. You can look here at the Liferay Faces Version Scheme. You will see that Liferay 7 will require master branch (version 5.0.x) com.liferay.faces.bridge.ext-5.0.0.jar for Liferay 7.0.x, and hence JSF 2.2.
I have not had a chance to go through your web.xml yet, but let's get the dependency versions fixed first. You should be able to follow the versions in version scheme.
Hope that helps.
- Vernon
Matteo Gnocchi, modificado 7 Anos atrás.
RE: PrimeFaces on Liferay 7
Junior Member Postagens: 29 Data de Entrada: 29/03/16 Postagens Recentes
Hi Vernon
Following the new "Liferay Faces Version Scheme" I was able to add all the correct libraries.
Furthermore I found an error in my web.xml (due to an old configuration for liferay 6.2).
Now my primefaces6 portlet works on Liferay 7.
Thanks for your precious help!
Following the new "Liferay Faces Version Scheme" I was able to add all the correct libraries.
Furthermore I found an error in my web.xml (due to an old configuration for liferay 6.2).
Now my primefaces6 portlet works on Liferay 7.
Thanks for your precious help!
Vernon Singleton, modificado 7 Anos atrás.
RE: PrimeFaces on Liferay 7
Expert Postagens: 315 Data de Entrada: 14/01/13 Postagens Recentes
Hi Matteo,
Yay!
Glad that things are working for you now.
I hope you continue to enjoy developing using Liferay Faces!
- Vernon
Matteo Gnocchi:
Now my primefaces6 portlet works on Liferay 7.
Yay!
Glad that things are working for you now.
I hope you continue to enjoy developing using Liferay Faces!
- Vernon