Moved to Liferay Faces - English Category

Antonio Markci, modified 5 Years ago. New Member Post: 1 Join Date: 7/23/20 Recent Posts
I am migrating a Liferay-Plugin from 6.2.5 to 7.3.2. It's an JSF Portlet with Alloy UI.After the deployment on the Liferay Server i get the following NullpointerException: 

org.osgi.framework.ServiceException: Exception in com.liferay.portal.osgi.web.servlet.context.helper.internal.ServletContextHelperRegistrationServiceFactory.getService()
Caused by: java.lang.NullPointerException    
at com.liferay.portal.kernel.util.PropsUtil.get(PropsUtil.java:31)    
at com.liferay.portal.kernel.servlet.filters.invoker.InvokerFilter.<clinit>(InvokerFilter.java:350)  
... 123 more

With Debugging I figured out that the static variable _props has the value null. Has anyone an solution how to fix this?
thumbnail
Kyle Joseph Stiemann, modified 5 Years ago. Liferay Master Posts: 760 Join Date: 1/14/13 Recent Posts
Moved to Liferay Faces - English Category
thumbnail
Neil Griffin, modified 5 Years ago. Liferay Legend Posts: 2655 Join Date: 7/27/05 Recent Posts
Hi Antonio,
Thanks for asking your question. We definitely support migration of JSF portlets from Liferay 6.2.x to Liferay 7.x, along with support for AlloyUI (assuming that you are using the Liferay Faces Alloy component suite).
When errors like this occur, I find that it's easiest to start with something simple that works, and then slowly add stuff to it, redeploying after each addition until it breaks.
To that end, I would recommend that you visit the liferayfaces.org site. On the home page you will find some dropdowns for Liferay Portal Version, JSF version, Component Suite, etc. Make your selections from the dropdown lists and then copy the "mvn archetype:generate" command (that appears to the right of the dropdown lists) to the command line and execute the command. That will generate a project that you can build with "mvn clean plackage" and then you can copy the resulting .war artifact to $LIFERAY_HOME/deploy.

After you get that working, then you start adding parts of your JSF portlet to it until it doesn't deploy correctly anymore. That should reveal the problem.
Kind Regards,
Neil