File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Portals and Portlets and the fly likes Liferay Portal performance tuning Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Portals and Portlets
Bookmark "Liferay Portal performance tuning" Watch "Liferay Portal performance tuning" New topic
Author

Liferay Portal performance tuning

fahd helwani
Ranch Hand

Joined: Jul 18, 2006
Posts: 63

Hi Mr. Sezov

it's great chance to have you on JavaRanch forums, I do have the following question regarding Liferay.

A while ago I used to develop portlets for Liferay, and we published many portals and developed several portlets on these portals, the problem that all the customers complained about was the low performance "slow portals, the pages opened slower than any other CMS" and we looked around for way to improve the portal performance.

my question in this manner is as the following: what is/are the bottle nicks that need(s) to be monitored, tuned or improved in order to improve the overall performance of the portal? is there any perferred stack in terms of OS, DBMS, Application server...etc that got better performance than others?

I looked into the book index and I'm not sure if there is something related to performance tuning.

thank you for your time.
Fahd


SCJP 5 (80%), SCWCD 5 (85%), SCBCD 5 (80%), CAPM, SCEA/OCMJEA
Raja Pal
Ranch Hand

Joined: Jul 12, 2004
Posts: 92
Hi Fahd, I am learning liferay on my own. Was curious from your post and would request you to share some tips on what liferay is good at doing and what isn't as good? Any good pointers to get up and running with a DIY guide? I did visit the liferay.com website, BTW. Apart from performance any other issues you faced like integrating to SQL Server, SPS, etc?


Java Pal - Your friend in technology and innovation...India.
Nestor Mata
Greenhorn

Joined: Nov 07, 2006
Posts: 15
Hi Richard Sezov,

Is there any way to set up page or partial cache's on LifeRay?
Maybe this is a good way to improve performance.

Best regards,
Nestor
fahd helwani
Ranch Hand

Joined: Jul 18, 2006
Posts: 63

Hi Raja,

I didn't have the chance to run Liferay using MS SQL server as a DBMS, but I assume it won't be a big problem since Liferay supports several DBMSs including SQL server.

as for my experience: I would really like to point you to some guides but my experience is quite old "I used to develop for Liferay 5", anyway if you got any specific request I think lots of people here can help "including me"

as for the partial page loading: there is a mechanism to update parts of the pages of the portal, and since Liferay supports jQuery I would say that using AJAX calls to refresh parts of the page would be easy to do.

at the end: sorry for my short answers which I hope to be helpful, eventually my experience with Liferay is not comparable to the book author
Rich Sezov
Author
Greenhorn

Joined: Dec 13, 2006
Posts: 17
Hi,

Liferay has many ways it can be tuned. It's hard to say exactly what might have affected your particular installations. From a code standpoint, if you're deploying Liferay into a situation where performance is key, out of the gate, EE will perform faster than CE. Liferay implements new features, puts them into CE, gives them bug fixes, and then performance optimizes them for EE. So generally, every new CE release gets the performance optimizations from the previous release, but not the ones for the current release.

I did a presentation on this several Liferay symposiums back; I'll give you the main points from that presentation:

1. Adjust the server's thread pool and JDBC connection pool. You have to use a profiler and tune to the right number.

2. Turn off unused servlet filters. This can be done through the portal-ext.properties file.

3. Tune your JVM parameters. Again, you need a profiler for this.

4. Tune Liferay's cache. If your site makes heavy use of CMS objects, but not so much wiki objects, you will want to tune the CMS cache appropriately.

5. Change the Lucene index writer interval. If you're doing mostly reads, make it low. If you're doing mostly writes make it high.

6. If search is a big part of your site, offload it with Solr, and use the Solr plugin.

7. Optimize the counter increment (counter.increment in portal-ext.properties). Set it to a higher number to reduce database calls.

8. Use a CDN for static content (cdn.host).

9. If you can't use a CDN, use a web server to serve your static resources. This is done via three steps: 1) set theme.virtual.path to your Apache root, 2) Set the <virtual-path> property in your theme, and 3) Set your server proxy to exclude from the proxy the path to the theme.

10. Use Liferay's tag libraries for your code. They already include optimizations, such as the auto-creation of CSS/JS sprites for your images.

11. Use a Read-writer database. This is one database optimized for reads, and one database optimized for writes. Properties are jdbc.read.* and jdbc.write.*.

12. Use Liferay's sharding support.

Hope this helps!

--Rich
fahd helwani
Ranch Hand

Joined: Jul 18, 2006
Posts: 63

Thank you Rich for such detailed information: this is very informative and useful.

Thank you again
Raja Pal
Ranch Hand

Joined: Jul 12, 2004
Posts: 92
Thank you Fahd.

Rich, you have been an angel..Thanks for those resources you shared!
Rich Sezov
Author
Greenhorn

Joined: Dec 13, 2006
Posts: 17
Happy to help!
 
Don't get me started about those stupid light bulbs.
 
subject: Liferay Portal performance tuning
 
Similar Threads
how to deploy a portal to public web host
Performance of Sun Java Portal Server
Migrating to Portals & Portlets
* Welcome Jonas Yuan
What is needed to use portals/portlets?