This wiki does not contain official documentation and is currently deprecated and read only. Please try reading the documentation on the Liferay Developer Network, the new site dedicated to Liferay documentation. DISCOVER Build your web site, collaborate with your colleagues, manage your content, and more. DEVELOP Build applications that run inside Liferay, extend the features provided out of the box with Liferay's APIs. DISTRIBUTE Let the world know about your app by publishing it in Liferay's marketplace. PARTICIPATE Become a part of Liferay's community, meet other Liferay users, and get involved in the open source project. Resin 4 tips
Deploying portal on Resin 4 #
After unzipping Resin 4 (with ant task) and deploying the portal to it, Resin fails to start, due to some
ClassNotDefinedExceptionsfor missing logging jars (slf4j.jar, log4j.jar).
The solution is to manually copy following jars to resin/lib folder:
- log4j.jar
- slf4j-api.jar
- slf4j-log4j12.jar
Note that it doesn't work to copy jars to ext-lib instead.
From recently, above jars are added automatically during the deployment task.
Some issues with Resin 4 #
At the time of writing this section (May, 2011), there are following Resin 4 issues:
- Problem with deploying portlets: http://forum.caucho.com/showthread.php?t=23501
- JSP precompilation causes web application initialization: http://bugs.caucho.com/view.php?id=4397
Avoid Resin 3 #
Resin 3 does not compile big JSP pages efficiently, so often a compile exception is thrown saying that 'try code block is too large':
code too large for try statement
try {
^For example,the following Control Panel pages can't be used with Resin 3:
- Document Library
- Image Gallery
- Calendar
- Server Administration
- Portal Instance
- Plugins Installations
Also, the same problem may appear on various admin pages, since they might be too large for Resin JSP compiler.
Solution for this issue is, obviously, to split these long pages into smaller chunks:) Unfortunately, it happened that these chunks can't form logical units, so splitting would give too much files that is hard to follow and maintain.
Install Mail session #
Some plugins require mail session to be installed in app server. For Resin add the following to resin.conf
<resource jndi-name="mail/MailSession" type="javax.mail.Session"> <init><mail.store.protocol>imap</mail.store.protocol> <mail.transport.protocol>smtp</mail.transport.protocol> <mail.imap.host>localhost</mail.imap.host> <mail.pop3.host>localhost</mail.pop3.host> <mail.smtp.host>localhost</mail.smtp.host> </init> </resource>
Deploying JSF portlets #
Some JSF portlets (like: sample-icefaces-ipc-ajax-push-portlet) can not be deployed on Resin due to following exception:
com.caucho.config.ConfigException: listener-class 'com.sun.faces.application.WebappLifecycleListener' does not implement any web-app listener interface.
This happens since Resin comes with its own JSF implementation: (resin-4.0.26/lib/jsf-mojarra-2.1.3.jar) that is loaded first.
To fix this, just remove the jsf-impl.jar from the deployed portlet or from the portlet war.
Using Resin 4 Professional #
Caucho's Resin 4 wiki has more recently updated information on setting up Liferay on Resin Professional . The instructions are mostly relevant to Resin Open Source also.