SlideShare a Scribd company logo
Liferay Developer Best Practices March 31 st  2011 Rivet Logic Corporation 1800 Alexander Bell Drive Suite 400 Reston, VA 20191 Ph: 703.955.3480  Fax: 703.234.7711 Presented By Alaaeldin El-Nattar Principal Architect Rivet Logic Corporation
Rivet Logic Overview Award-winning professional services focused on enabling: Collaboration and Community Platforms Enterprise and Web Content Management Next Generation Websites  Using Leading Open Source Software Company Facts Founded 2005, Consistently Profitable, Employee-owned Headquartered in Reston, VA Regional Offices in Boston, New York City, LA Near-shore Development Center in Costa Rica 40+ Consultants Copyright © 2008. Rivet Logic Corporation. All rights reserved.
Rivet Logic and Liferay Certified Partner since 2006 Conduct all Public Training on East Coast USA  Contributor (software, documentation, forums, training material) Host of first ever East Coast User Conference in 2009 20+ Liferay projects underway or completed Copyright © 2008. Rivet Logic Corporation. All rights reserved.
Best Practices What are best practices? “ A  best practice  is a technique, method, process, activity, incentive, or reward that is believed to be more effective at delivering a particular outcome  than  any  other  technique,  method,  process,  etc. when applied to a particular condition or circumstance. ” – Wikipedia Why is it not easy to follow them? Why should we follow them? Copyright © 2010. Rivet Logic Corporation. All rights reserved.
Motivation Better maintenance Better flexibility Higher confidence A great differentiator Copyright © 2010. Rivet Logic Corporation. All rights reserved.
Liferay Best Practices Best practices at three levels Architecture Design/Development Deployment/Operations Copyright © 2010. Rivet Logic Corporation. All rights reserved.
Copyright © 2009. Rivet Logic Corporation. All rights reserved. ARCHITECTURE
Architecture Best Practices Essentials Understanding Liferay’s architecture and roadmap Ability to map real life IA into Communities/Organizations Use what you have Organization hierarchies can be very useful Educate the client e.g. Control Panel is powerful but one must be told why  Copyright © 2010. Rivet Logic Corporation. All rights reserved.
Architecture Best Practices Disciplines Do your best to understand the client’s business model Walk and talk like they do Terminology matters Be 100% transparent Be “Agile” Maintain a clear upgrade path Copyright © 2010. Rivet Logic Corporation. All rights reserved.
Copyright © 2009. Rivet Logic Corporation. All rights reserved. DESIGN / DEVELOPMENT
Design/Development Best Practices Use Expandos for extending models where possible Quick apps can be written using the Liferay WCM and Expandos Think about the pros and cons Copyright © 2010. Rivet Logic Corporation. All rights reserved. Note: This list is not in any particular order http://www.liferay.com/web/raymond.auge/blog/-/blogs/expandos-ii-refactor-of-a-previous-post-for-6-0
Design/Development Best Practices Don’t forget that you can use custom SQL in your plugins Consider caching if custom query is called often Copyright © 2010. Rivet Logic Corporation. All rights reserved. http://www.liferay.com/community/forums/-/message_boards/message/4912728 http://www.liferay.com/community/wiki/-/wiki/Main/Service+Builder+Finders
Design/Development Best Practices Portlet resource permissions in Plugin SDK Important for portlet flexibility Understand the three portlet permission levels Copyright © 2010. Rivet Logic Corporation. All rights reserved. http://www.liferay.com/community/forums/-/message_boards/message/4887808
Design/Development Best Practices You can access Liferay services directly in velocity No need for custom velocity variables Helps when building WCM applications  Copyright © 2010. Rivet Logic Corporation. All rights reserved. http://www.liferay.com/community/forums/-/message_boards/message/4885934
Design/Development Best Practices Before you customize look at portal.properties Use hooks to override properties if you can If hooks don’t allow you to override a property use portal-ext.properties Copyright © 2010. Rivet Logic Corporation. All rights reserved.
Design/Development Best Practices Localization is made simple by Liferay Any database column can be localized Copyright © 2010. Rivet Logic Corporation. All rights reserved. http://www.liferay.com/community/forums/-/message_boards/message/4857873 <column name=&quot;title&quot; type=&quot;String&quot;  localized=&quot;true&quot;  />
Design/Development Best Practices Understand how Liferay counters work Look at  com/liferay/counter/service.xml Override if necessary See  counter-spring.xml Copyright © 2010. Rivet Logic Corporation. All rights reserved. http://www.liferay.com/community/forums/-/message_boards/message/4850927 http://www.liferay.com/community/forums/-/message_boards/message/4841385
Design/Development Best Practices Know when/how to share services between portlets Place service JAR in WEB-INF/lib of each plugin Allows for hot deployable plugins Copyright © 2010. Rivet Logic Corporation. All rights reserved. http://www.liferay.com/community/forums/-/message_boards/message/4686465 http://www.liferay.com/web/juan.fernandez/blog/-/blogs/liferay-modules-communication
Design/Development Best Practices Know how to upgrade your portlets Use Liferay’s UpgradeProcess Use a hook plugin and an Upgrade class Copyright © 2010. Rivet Logic Corporation. All rights reserved. http://www.liferay.com/web/ryan.park/blog/-/blogs/implementing-upgradingprocess-for-your-liferay-portlets!?_33_redirect=%2Fweb%2Fryan.park%2Fblog
Design/Development Best Practices Build your integration layers as services Use Service Builder Standardize development methodology Copyright © 2010. Rivet Logic Corporation. All rights reserved.
Design/Development Best Practices Understand the pros and cons of search/indexing options Solr vs Local Index Copyright © 2010. Rivet Logic Corporation. All rights reserved. http://issues.liferay.com/browse/LPS-15006 http://svn.liferay.com/changelog/plugins?cs=71516
Copyright © 2009. Rivet Logic Corporation. All rights reserved. DEPLOYMENT / OPERATIONS
Deployment/Ops Best Practices Document everything DEV vs QA vs PROD HINT: Use properties  files per environment portal-dev.properties portal-qa.properties portal-prod.properties Copyright © 2010. Rivet Logic Corporation. All rights reserved.
Deployment/Ops Best Practices Deploy Liferay as a service Windows Tomcat can be installed as a service Unix Use init scripts Distro dependant Copyright © 2010. Rivet Logic Corporation. All rights reserved.
Deployment/Ops Best Practices Know how to do hardware sizing Ask the right questions How many concurrent users What are the real life use cases Translate use cases to Liferay functionality Map functionality to resource utilization File system Database Copyright © 2010. Rivet Logic Corporation. All rights reserved. ?
Deployment/Ops Best Practices Performance tuning Profile the portal Tweak the JVM Have a scalability plan Copyright © 2010. Rivet Logic Corporation. All rights reserved.
Deployment/Ops Best Practices High-Availability deployment quirks Clustered cache is affected by underlying network HTTP session replication is usually overkill Educate the client Copyright © 2010. Rivet Logic Corporation. All rights reserved. You can count on me
Summary Best practices span the entire software development lifecycle Try to keep up Liferay is always changing Always promote best practices Copyright © 2009. Rivet Logic Corporation. All rights reserved.
Q & A Copyright © 2010. Rivet Logic Corporation. All rights reserved.
rivetlogic.com blogs.rivetlogic.com forge.rivetlogic.com youtube.com/rivetlogic twitter.com/rivetlogic Learn more… Copyright © 2010. Rivet Logic Corporation. All rights reserved.

More Related Content

What's hot (20)

PDF
Liferay DevCon 2014: Lliferay Platform - A new and exciting vision
Jorge Ferrer
 
PDF
[DevDay2018] Liferay DXP – A powerful Enterprise Solution - By Vy Bui, Develo...
DevDay Da Nang
 
PDF
2014 Liferay Roadshow Ambientia Finland
Ruud Kluivers
 
PPTX
Liferay Configuration and Customization
Thành Nguyễn
 
PDF
01/2009 - Portral development with liferay
daveayan
 
PPTX
Portlet Framework: the Liferay way
riround
 
PDF
Making a decision between Liferay and Drupal
InfoAxon Technologies Limited
 
ODP
Liferay with xebia
sourabh aggarwal
 
PDF
Liferay Italy Symposium 2015 Liferay Mobile SDK and Liferay Screens
Denis Signoretto
 
PDF
Liferay architecture By Navin Agarwal
Navin Agarwal
 
PDF
Moved to https://slidr.io/azzazzel/leveraging-osgi-to-create-extensible-plugi...
Milen Dyankov
 
PPTX
Liferay on docker
Geeta Raghu Vamsi Kotipalli
 
ODP
Liferay and Cloud
Miguel Pastor
 
PPTX
Liferay 7
Son Nguyen
 
PPTX
Liferay portal advantages
Manish Kumar Jaiswal
 
PDF
Mavenizing your Liferay project
mimacom
 
PPTX
Liferay as solution for legacy applications
Manish Kumar Jaiswal
 
PDF
EclipseCon Europe 2015 - liferay modularity patterns using OSGi -Rafik Harabi
Rafik HARABI
 
PPTX
Benefits of using liferay
SKALI Group
 
PDF
Why choose-liferay
Ruud Kluivers
 
Liferay DevCon 2014: Lliferay Platform - A new and exciting vision
Jorge Ferrer
 
[DevDay2018] Liferay DXP – A powerful Enterprise Solution - By Vy Bui, Develo...
DevDay Da Nang
 
2014 Liferay Roadshow Ambientia Finland
Ruud Kluivers
 
Liferay Configuration and Customization
Thành Nguyễn
 
01/2009 - Portral development with liferay
daveayan
 
Portlet Framework: the Liferay way
riround
 
Making a decision between Liferay and Drupal
InfoAxon Technologies Limited
 
Liferay with xebia
sourabh aggarwal
 
Liferay Italy Symposium 2015 Liferay Mobile SDK and Liferay Screens
Denis Signoretto
 
Liferay architecture By Navin Agarwal
Navin Agarwal
 
Moved to https://slidr.io/azzazzel/leveraging-osgi-to-create-extensible-plugi...
Milen Dyankov
 
Liferay on docker
Geeta Raghu Vamsi Kotipalli
 
Liferay and Cloud
Miguel Pastor
 
Liferay 7
Son Nguyen
 
Liferay portal advantages
Manish Kumar Jaiswal
 
Mavenizing your Liferay project
mimacom
 
Liferay as solution for legacy applications
Manish Kumar Jaiswal
 
EclipseCon Europe 2015 - liferay modularity patterns using OSGi -Rafik Harabi
Rafik HARABI
 
Benefits of using liferay
SKALI Group
 
Why choose-liferay
Ruud Kluivers
 

Viewers also liked (14)

PDF
SAML and Liferay
Mika Koivisto
 
PDF
Developing Liferay Plugins with Maven
Mika Koivisto
 
PDF
Manual Basico De Struts
carlossanchezvillena
 
PDF
Liferay maven sdk
Mika Koivisto
 
PDF
Liferay 6 and vaadin portlets
Rustem Gayfutdinov
 
PDF
Step by Step Guide for building a simple Struts Application
elliando dias
 
PDF
Struts Basics
Harjinder Singh
 
PPT
Alfresco P Tardif V1 0 Mars 2009
tardifpa
 
PDF
mimacom & Liferay Roadshow : Introduction to Liferay platform
Ján Gregor
 
PPTX
Liferay
SKALI Group
 
PPTX
Liferay
Elhem Sassi
 
PPTX
7 plugins de la communauté à ne pas manquer ! - Liferay France Symposium 2016
Sébastien Le Marchand
 
PPT
O que é o Liferay? Porque usar?
Felipe Valcanaia
 
PDF
Arquitectura y Funcionalidades Liferay Portal
Stratebi
 
SAML and Liferay
Mika Koivisto
 
Developing Liferay Plugins with Maven
Mika Koivisto
 
Manual Basico De Struts
carlossanchezvillena
 
Liferay maven sdk
Mika Koivisto
 
Liferay 6 and vaadin portlets
Rustem Gayfutdinov
 
Step by Step Guide for building a simple Struts Application
elliando dias
 
Struts Basics
Harjinder Singh
 
Alfresco P Tardif V1 0 Mars 2009
tardifpa
 
mimacom & Liferay Roadshow : Introduction to Liferay platform
Ján Gregor
 
Liferay
SKALI Group
 
Liferay
Elhem Sassi
 
7 plugins de la communauté à ne pas manquer ! - Liferay France Symposium 2016
Sébastien Le Marchand
 
O que é o Liferay? Porque usar?
Felipe Valcanaia
 
Arquitectura y Funcionalidades Liferay Portal
Stratebi
 
Ad

Similar to Liferay Developer Best Practices for a Successful Deployment (20)

PDF
Increase Customer Engagement and Drive Revenue with Liferay Audience Targeting
rivetlogic
 
PDF
MSLC Company Profile
Muhammed Shakir
 
PPTX
Liferay MVC Portlet Development with Liferay IDE
Surekha Technologies
 
PDF
Liferay Road Show Helsinki, What’s New and Upcoming, 2012-09-13
Ambientia
 
PDF
Liferay Go-Live Program
Sharmila Wijeyakumar, CBIP
 
PDF
Liferay - The Value of Relationship
Marcin Kierdelewicz
 
PDF
Liferay administration-guide
guest4094ec
 
PDF
Building and Deploying a Global Intranet with Liferay
rivetlogic
 
PPTX
Life ray training
Mayur Sand
 
PPTX
Fundamentals of Liferay Development for Non-Tech-Savvy Decision-Makers.pptx
Surekha Technologies
 
PDF
DeltaFixes - Liferay Portal Development Company
DeltaFixes Technologies
 
PPT
Liferay introducing
Нурлан Акашаев
 
PDF
Advanced liferay architecture clustering and high availability
Bordin Kijsirijareonchai
 
PDF
iProfs-Liferay Roadshow-03-10-13 - LPSF Highlights
Ruud Kluivers
 
PPTX
Liferay Platform Overview
FirmansyahIrma1
 
PDF
Les2012 lightning talk_exporting_and_importing_company-level_data
Sébastien Le Marchand
 
PDF
Liferay 62 User Interface Development Xinsheng Chen Jonas X Yuan
erojodafik
 
TXT
Link. portali
santi caltabiano
 
PDF
Building Enterprise Customer Portals With Liferay
rivetlogic
 
Increase Customer Engagement and Drive Revenue with Liferay Audience Targeting
rivetlogic
 
MSLC Company Profile
Muhammed Shakir
 
Liferay MVC Portlet Development with Liferay IDE
Surekha Technologies
 
Liferay Road Show Helsinki, What’s New and Upcoming, 2012-09-13
Ambientia
 
Liferay Go-Live Program
Sharmila Wijeyakumar, CBIP
 
Liferay - The Value of Relationship
Marcin Kierdelewicz
 
Liferay administration-guide
guest4094ec
 
Building and Deploying a Global Intranet with Liferay
rivetlogic
 
Life ray training
Mayur Sand
 
Fundamentals of Liferay Development for Non-Tech-Savvy Decision-Makers.pptx
Surekha Technologies
 
DeltaFixes - Liferay Portal Development Company
DeltaFixes Technologies
 
Liferay introducing
Нурлан Акашаев
 
Advanced liferay architecture clustering and high availability
Bordin Kijsirijareonchai
 
iProfs-Liferay Roadshow-03-10-13 - LPSF Highlights
Ruud Kluivers
 
Liferay Platform Overview
FirmansyahIrma1
 
Les2012 lightning talk_exporting_and_importing_company-level_data
Sébastien Le Marchand
 
Liferay 62 User Interface Development Xinsheng Chen Jonas X Yuan
erojodafik
 
Link. portali
santi caltabiano
 
Building Enterprise Customer Portals With Liferay
rivetlogic
 
Ad

More from rivetlogic (20)

PDF
Storytelling for CX: Make Your Audience the Hero
rivetlogic
 
PDF
How to Accelerate Your Digital Transformation With Design Thinking
rivetlogic
 
PDF
Ensuring the Success of a Global Partner Network - How Dropbox is managing it...
rivetlogic
 
PDF
How a Product Development Portal Can Help Turn Innovative Ideas Into Marketab...
rivetlogic
 
PDF
Reimagine Your Video Communications With Video Center on AWS
rivetlogic
 
PDF
Elevate Your Digital Experiences with Cloud Content Management on Box
rivetlogic
 
PDF
Delivering Connected Digital Experiences for Engaging the Modern Day Customer
rivetlogic
 
PDF
5 Reasons Why You Should Consider Migrating Web Apps to the Cloud on AWS
rivetlogic
 
PDF
5 Reasons Why Your CMS Should Move to the Cloud
rivetlogic
 
PDF
Improve Employee Engagement With a Mobile Enabled Intranet
rivetlogic
 
PDF
Incorporating Mobile Into Your Digital Experience Strategy
rivetlogic
 
PDF
Marketing Asset Center - Enabling Consistency & Productivity Across Sales & M...
rivetlogic
 
PDF
NoSQL Design Considerations and Lessons Learned
rivetlogic
 
PDF
Increase Your Marketing Productivity With the Marketing Asset Center for Alfr...
rivetlogic
 
PDF
Social Intranets for Smarter Enterprise Collaboration
rivetlogic
 
PDF
AT&T’s Mobile Developer Community: Social, Personalized, and Built for Scale
rivetlogic
 
PDF
SEO with Liferay
rivetlogic
 
PDF
Implementing an SEO Strategy for Your Liferay Websites
rivetlogic
 
PDF
Building Engaging Customer Experiences Powered by MongoDB
rivetlogic
 
PDF
Social Intranets on Liferay for Smarter Enterprise Collaboration
rivetlogic
 
Storytelling for CX: Make Your Audience the Hero
rivetlogic
 
How to Accelerate Your Digital Transformation With Design Thinking
rivetlogic
 
Ensuring the Success of a Global Partner Network - How Dropbox is managing it...
rivetlogic
 
How a Product Development Portal Can Help Turn Innovative Ideas Into Marketab...
rivetlogic
 
Reimagine Your Video Communications With Video Center on AWS
rivetlogic
 
Elevate Your Digital Experiences with Cloud Content Management on Box
rivetlogic
 
Delivering Connected Digital Experiences for Engaging the Modern Day Customer
rivetlogic
 
5 Reasons Why You Should Consider Migrating Web Apps to the Cloud on AWS
rivetlogic
 
5 Reasons Why Your CMS Should Move to the Cloud
rivetlogic
 
Improve Employee Engagement With a Mobile Enabled Intranet
rivetlogic
 
Incorporating Mobile Into Your Digital Experience Strategy
rivetlogic
 
Marketing Asset Center - Enabling Consistency & Productivity Across Sales & M...
rivetlogic
 
NoSQL Design Considerations and Lessons Learned
rivetlogic
 
Increase Your Marketing Productivity With the Marketing Asset Center for Alfr...
rivetlogic
 
Social Intranets for Smarter Enterprise Collaboration
rivetlogic
 
AT&T’s Mobile Developer Community: Social, Personalized, and Built for Scale
rivetlogic
 
SEO with Liferay
rivetlogic
 
Implementing an SEO Strategy for Your Liferay Websites
rivetlogic
 
Building Engaging Customer Experiences Powered by MongoDB
rivetlogic
 
Social Intranets on Liferay for Smarter Enterprise Collaboration
rivetlogic
 

Recently uploaded (20)

PDF
Log-Based Anomaly Detection: Enhancing System Reliability with Machine Learning
Mohammed BEKKOUCHE
 
PDF
"AI Transformation: Directions and Challenges", Pavlo Shaternik
Fwdays
 
PDF
Reverse Engineering of Security Products: Developing an Advanced Microsoft De...
nwbxhhcyjv
 
PDF
CIFDAQ Token Spotlight for 9th July 2025
CIFDAQ
 
PDF
NewMind AI - Journal 100 Insights After The 100th Issue
NewMind AI
 
PPTX
MSP360 Backup Scheduling and Retention Best Practices.pptx
MSP360
 
PDF
July Patch Tuesday
Ivanti
 
PDF
Agentic AI lifecycle for Enterprise Hyper-Automation
Debmalya Biswas
 
PDF
DevBcn - Building 10x Organizations Using Modern Productivity Metrics
Justin Reock
 
PPTX
OpenID AuthZEN - Analyst Briefing July 2025
David Brossard
 
PDF
Blockchain Transactions Explained For Everyone
CIFDAQ
 
PDF
HCIP-Data Center Facility Deployment V2.0 Training Material (Without Remarks ...
mcastillo49
 
PDF
SFWelly Summer 25 Release Highlights July 2025
Anna Loughnan Colquhoun
 
PDF
Empower Inclusion Through Accessible Java Applications
Ana-Maria Mihalceanu
 
PDF
Fl Studio 24.2.2 Build 4597 Crack for Windows Free Download 2025
faizk77g
 
PPTX
Webinar: Introduction to LF Energy EVerest
DanBrown980551
 
PDF
[Newgen] NewgenONE Marvin Brochure 1.pdf
darshakparmar
 
PDF
New from BookNet Canada for 2025: BNC BiblioShare - Tech Forum 2025
BookNet Canada
 
PDF
How Startups Are Growing Faster with App Developers in Australia.pdf
India App Developer
 
PDF
"Beyond English: Navigating the Challenges of Building a Ukrainian-language R...
Fwdays
 
Log-Based Anomaly Detection: Enhancing System Reliability with Machine Learning
Mohammed BEKKOUCHE
 
"AI Transformation: Directions and Challenges", Pavlo Shaternik
Fwdays
 
Reverse Engineering of Security Products: Developing an Advanced Microsoft De...
nwbxhhcyjv
 
CIFDAQ Token Spotlight for 9th July 2025
CIFDAQ
 
NewMind AI - Journal 100 Insights After The 100th Issue
NewMind AI
 
MSP360 Backup Scheduling and Retention Best Practices.pptx
MSP360
 
July Patch Tuesday
Ivanti
 
Agentic AI lifecycle for Enterprise Hyper-Automation
Debmalya Biswas
 
DevBcn - Building 10x Organizations Using Modern Productivity Metrics
Justin Reock
 
OpenID AuthZEN - Analyst Briefing July 2025
David Brossard
 
Blockchain Transactions Explained For Everyone
CIFDAQ
 
HCIP-Data Center Facility Deployment V2.0 Training Material (Without Remarks ...
mcastillo49
 
SFWelly Summer 25 Release Highlights July 2025
Anna Loughnan Colquhoun
 
Empower Inclusion Through Accessible Java Applications
Ana-Maria Mihalceanu
 
Fl Studio 24.2.2 Build 4597 Crack for Windows Free Download 2025
faizk77g
 
Webinar: Introduction to LF Energy EVerest
DanBrown980551
 
[Newgen] NewgenONE Marvin Brochure 1.pdf
darshakparmar
 
New from BookNet Canada for 2025: BNC BiblioShare - Tech Forum 2025
BookNet Canada
 
How Startups Are Growing Faster with App Developers in Australia.pdf
India App Developer
 
"Beyond English: Navigating the Challenges of Building a Ukrainian-language R...
Fwdays
 

Liferay Developer Best Practices for a Successful Deployment

  • 1. Liferay Developer Best Practices March 31 st 2011 Rivet Logic Corporation 1800 Alexander Bell Drive Suite 400 Reston, VA 20191 Ph: 703.955.3480 Fax: 703.234.7711 Presented By Alaaeldin El-Nattar Principal Architect Rivet Logic Corporation
  • 2. Rivet Logic Overview Award-winning professional services focused on enabling: Collaboration and Community Platforms Enterprise and Web Content Management Next Generation Websites Using Leading Open Source Software Company Facts Founded 2005, Consistently Profitable, Employee-owned Headquartered in Reston, VA Regional Offices in Boston, New York City, LA Near-shore Development Center in Costa Rica 40+ Consultants Copyright © 2008. Rivet Logic Corporation. All rights reserved.
  • 3. Rivet Logic and Liferay Certified Partner since 2006 Conduct all Public Training on East Coast USA Contributor (software, documentation, forums, training material) Host of first ever East Coast User Conference in 2009 20+ Liferay projects underway or completed Copyright © 2008. Rivet Logic Corporation. All rights reserved.
  • 4. Best Practices What are best practices? “ A best practice is a technique, method, process, activity, incentive, or reward that is believed to be more effective at delivering a particular outcome than any other technique, method, process, etc. when applied to a particular condition or circumstance. ” – Wikipedia Why is it not easy to follow them? Why should we follow them? Copyright © 2010. Rivet Logic Corporation. All rights reserved.
  • 5. Motivation Better maintenance Better flexibility Higher confidence A great differentiator Copyright © 2010. Rivet Logic Corporation. All rights reserved.
  • 6. Liferay Best Practices Best practices at three levels Architecture Design/Development Deployment/Operations Copyright © 2010. Rivet Logic Corporation. All rights reserved.
  • 7. Copyright © 2009. Rivet Logic Corporation. All rights reserved. ARCHITECTURE
  • 8. Architecture Best Practices Essentials Understanding Liferay’s architecture and roadmap Ability to map real life IA into Communities/Organizations Use what you have Organization hierarchies can be very useful Educate the client e.g. Control Panel is powerful but one must be told why Copyright © 2010. Rivet Logic Corporation. All rights reserved.
  • 9. Architecture Best Practices Disciplines Do your best to understand the client’s business model Walk and talk like they do Terminology matters Be 100% transparent Be “Agile” Maintain a clear upgrade path Copyright © 2010. Rivet Logic Corporation. All rights reserved.
  • 10. Copyright © 2009. Rivet Logic Corporation. All rights reserved. DESIGN / DEVELOPMENT
  • 11. Design/Development Best Practices Use Expandos for extending models where possible Quick apps can be written using the Liferay WCM and Expandos Think about the pros and cons Copyright © 2010. Rivet Logic Corporation. All rights reserved. Note: This list is not in any particular order http://www.liferay.com/web/raymond.auge/blog/-/blogs/expandos-ii-refactor-of-a-previous-post-for-6-0
  • 12. Design/Development Best Practices Don’t forget that you can use custom SQL in your plugins Consider caching if custom query is called often Copyright © 2010. Rivet Logic Corporation. All rights reserved. http://www.liferay.com/community/forums/-/message_boards/message/4912728 http://www.liferay.com/community/wiki/-/wiki/Main/Service+Builder+Finders
  • 13. Design/Development Best Practices Portlet resource permissions in Plugin SDK Important for portlet flexibility Understand the three portlet permission levels Copyright © 2010. Rivet Logic Corporation. All rights reserved. http://www.liferay.com/community/forums/-/message_boards/message/4887808
  • 14. Design/Development Best Practices You can access Liferay services directly in velocity No need for custom velocity variables Helps when building WCM applications Copyright © 2010. Rivet Logic Corporation. All rights reserved. http://www.liferay.com/community/forums/-/message_boards/message/4885934
  • 15. Design/Development Best Practices Before you customize look at portal.properties Use hooks to override properties if you can If hooks don’t allow you to override a property use portal-ext.properties Copyright © 2010. Rivet Logic Corporation. All rights reserved.
  • 16. Design/Development Best Practices Localization is made simple by Liferay Any database column can be localized Copyright © 2010. Rivet Logic Corporation. All rights reserved. http://www.liferay.com/community/forums/-/message_boards/message/4857873 <column name=&quot;title&quot; type=&quot;String&quot; localized=&quot;true&quot; />
  • 17. Design/Development Best Practices Understand how Liferay counters work Look at com/liferay/counter/service.xml Override if necessary See counter-spring.xml Copyright © 2010. Rivet Logic Corporation. All rights reserved. http://www.liferay.com/community/forums/-/message_boards/message/4850927 http://www.liferay.com/community/forums/-/message_boards/message/4841385
  • 18. Design/Development Best Practices Know when/how to share services between portlets Place service JAR in WEB-INF/lib of each plugin Allows for hot deployable plugins Copyright © 2010. Rivet Logic Corporation. All rights reserved. http://www.liferay.com/community/forums/-/message_boards/message/4686465 http://www.liferay.com/web/juan.fernandez/blog/-/blogs/liferay-modules-communication
  • 19. Design/Development Best Practices Know how to upgrade your portlets Use Liferay’s UpgradeProcess Use a hook plugin and an Upgrade class Copyright © 2010. Rivet Logic Corporation. All rights reserved. http://www.liferay.com/web/ryan.park/blog/-/blogs/implementing-upgradingprocess-for-your-liferay-portlets!?_33_redirect=%2Fweb%2Fryan.park%2Fblog
  • 20. Design/Development Best Practices Build your integration layers as services Use Service Builder Standardize development methodology Copyright © 2010. Rivet Logic Corporation. All rights reserved.
  • 21. Design/Development Best Practices Understand the pros and cons of search/indexing options Solr vs Local Index Copyright © 2010. Rivet Logic Corporation. All rights reserved. http://issues.liferay.com/browse/LPS-15006 http://svn.liferay.com/changelog/plugins?cs=71516
  • 22. Copyright © 2009. Rivet Logic Corporation. All rights reserved. DEPLOYMENT / OPERATIONS
  • 23. Deployment/Ops Best Practices Document everything DEV vs QA vs PROD HINT: Use properties files per environment portal-dev.properties portal-qa.properties portal-prod.properties Copyright © 2010. Rivet Logic Corporation. All rights reserved.
  • 24. Deployment/Ops Best Practices Deploy Liferay as a service Windows Tomcat can be installed as a service Unix Use init scripts Distro dependant Copyright © 2010. Rivet Logic Corporation. All rights reserved.
  • 25. Deployment/Ops Best Practices Know how to do hardware sizing Ask the right questions How many concurrent users What are the real life use cases Translate use cases to Liferay functionality Map functionality to resource utilization File system Database Copyright © 2010. Rivet Logic Corporation. All rights reserved. ?
  • 26. Deployment/Ops Best Practices Performance tuning Profile the portal Tweak the JVM Have a scalability plan Copyright © 2010. Rivet Logic Corporation. All rights reserved.
  • 27. Deployment/Ops Best Practices High-Availability deployment quirks Clustered cache is affected by underlying network HTTP session replication is usually overkill Educate the client Copyright © 2010. Rivet Logic Corporation. All rights reserved. You can count on me
  • 28. Summary Best practices span the entire software development lifecycle Try to keep up Liferay is always changing Always promote best practices Copyright © 2009. Rivet Logic Corporation. All rights reserved.
  • 29. Q & A Copyright © 2010. Rivet Logic Corporation. All rights reserved.
  • 30. rivetlogic.com blogs.rivetlogic.com forge.rivetlogic.com youtube.com/rivetlogic twitter.com/rivetlogic Learn more… Copyright © 2010. Rivet Logic Corporation. All rights reserved.