Tuesday, March 27, 2012

Liferay Portal Development Configuration

In an effort to do bug fixes and figure out certain things going wrong without our liferay install, I decided to set up liferay in such a way where I could place breakpoints and change code on the fly. This allows me to create patches in the form of updated class files and replace the class files in the final liferay release(s) to fix bugs unofficialy.

In order to set up the debugging environment the following steps should be taken.

Step 1: Install a Liferay Bundle. I would recommend installing the same version of Liferay that you are acutally using in your production environment. In my case, this is liferay version 6.1, Tomcat Bundle. The latest bundles can be downloaded here.

Step 2: download the latest Liferay IDE. This is an instance of the Eclipse IDE WTP bundled with certain plugins to give it special Liferay functionality, such as being able to start a Liferay Server instance. You may download the latest version of the Liferay IDE here.

Step 3: Install the latest SVN plugin for Eclipse. The easiest way to do this is to select (in the Liferay IDE) "help" -> "Install New Software..." -> and then select "Indigo - http://download.eclipse.org/releases/indigo" as your item in the "Work with:" field. This item may be different depending on your version of the Liferay IDE, but the name will correspond with the name of the Eclipse IDE version that the Liferay IDE is based on. Once the available categories are done loading, simply expand the collaboration section, select "Subversive SVN Team Provider" and proceed to follow the directions after selecting either "next" or "finish." You will also be prompted to install an SVN connector at some point; at this step, simply pick one connector that best matches your enviroment and proceed with the installation. After these steps are all complete and Liferay IDE has restarted, you should be able to add a new SVN server to browse the Liferay source code. You can get more information on the required URLs here. For my version the URL for Liferay's repo is http://svn.liferay.com/repos/public/ and the login credentials are:

user: guest

Step 4: Check out the liferay source code into your workspace. Simply navigate the Liferay SVN server to the TAG matching your target deployment version (this should also be the same version of Liferay that you have specified as the server instance). Select the branch and check out the entire contents.

Step 5:At this time you are ready to define a new Liferay server instance within the Liferay IDE. Select "Create a new Liferay Server" from the toolbar and follow the on screen instructions. Once the server is created, open the server view and tell the server to start. After the server has started, select the option "Open Liferay Portal Home" from the server's available action list.

Now, whenever liferay throws an exception your way, you should be able to access the related code, modify the code, and create your own patches as needed.


johnbritto said...

I found your blog perfect for my needs. It contains wonderful and helpful posts. I have read most of them and learned a lot from them. You are doing some great work. Thank you for making such a nice website.
portal development

Anonymous said...

Wow great information about toolbar development. Hire toolbar developer exhaustive analysis is capable of reshaping toolbar solutions with accuracy and precision. Here, cutting-edge technology in collaboration with cost-efficient methods is the stand-out corner for toolbar developer.

Iffi said...
This comment has been removed by a blog administrator.
John Buyer said...

Great! Thank u for sharing!
Digital Marketing Services in Chennai

Sadhana Rathore said...

I gathered lots of information from your blog and it helped me a lot. Keep posting more.
Python Classes in Chennai
Python Training Institute in Chennai
ccna Training in Chennai
ccna course in Chennai
R Training in Chennai
R Programming Training in Chennai
Python Training in T Nagar
Python Training in Adyar

sushmi reddy said...

Nice information, valuable and excellent design, as share good stuff with good ideas and concepts, lots of great information and inspiration, both of which I need, thanks to offer such a helpful information here.
Oracle Training | Online Course | Certification in chennai | Oracle Training | Online Course | Certification in bangalore | Oracle Training | Online Course | Certification in hyderabad | Oracle Training | Online Course | Certification in pune | Oracle Training | Online Course | Certification in coimbatore