You are on page 1of 313

Portal Administrator's Guide

Richard L. Sezov, Jr.

Liferay Administrator's Guide by Richard L. Sezov, Jr. Copyright !""# by Liferay, $nc. $S%& #'()")*'()"!'!#)+ ,his -or. is offered under the Creative Commons Attribution)Share A/i.e 0nported /icense.

1ou are free2 to share3to copy, distribute, and transmit the -or. to remi43to adapt the -or. 0nder the fo//o-ing conditions2 Attribution. 1ou must attribute the -or. in the manner specified by the author or /icensor 5but not in any -ay that suggests that they endorse you or your use of the -or.6. Share Alike. $f you a/ter, transform, or bui/d upon this -or., you may distribute the resu/ting -or. on/y under the same, simi/ar or a compatib/e /icense. ,he fu// version of this /icense appears in the appendi4 of this boo., or you may vieit on/ine here2 http277creativecommons.org7/icenses7by)sa78." Contributors2 Ray Auge, Jian Cao 5Steven6, %rian Chan, A/ice Cheng, %ryan Cheung, $van Cheung, Shepherd Ching, A/e4ander Cho-, %runo 9arache, Jorge 9errer, :i.e ;an, JR ;oun, Scott Lee, <ei ;ong :a 5Sai6, Char/es :ay, James :in, A/berto :ontero, Jerry &iu, :ichae/ Saechang, Li Ji Shan 5=a/e6, >d Shin, Joseph Shum, :ichae/ 1oung

Table of Contents
1. Introduction.......................................................................................15 CR>A,>= 9?R ,;> >&,>R@R$S>..................................................................................A* @ersona/ization and easy customization..............................................A* <or.f/o- adaptab/e...............................................................................A+ %randing friend/y...................................................................................A+ 9/e4ib/e organization.............................................................................A+ %ui/t <ith ,he >nd)0ser $n :ind.........................................................A+ A-ard)-inning 0$............................................................................A+ ?ne)C/ic. Loo. and 9ee/ Changes...................................................A+ <eb ?S..............................................................................................A+ ,>C;&?L?G1 ,? ;>L@ =>B>L?@>RS...........................................................................A+ Standards Comp/iant..............................................................................A' Ready $ntegration...................................................................................A' Liferay @/ugins Cata/og..........................................................................A' S0@@?R,>= ,>C;&?L?G$>S ......................................................................................A' LA&G0AG>S ........................................................................................................A' 2. Initial Setup.......................................................................................19 >=$,$?&S ?9 L$9>RA1.............................................................................................A# ?%,A$&$&G L$9>RA1...............................................................................................!" $&S,ALL$&G A %0&=L>............................................................................................!" $&S,ALL$&G L$9>RA1 9?R A& >&,>R@R$S>.....................................................................!! Samp/e =ata............................................................................................!! Liferay ;ome...........................................................................................!! =atabase Setup........................................................................................!8 =efau/t :ethod2 Automatic.............................................................!8 :anua/ :ethod................................................................................!8 ,urning a %und/e into an >nterprise @orta/.........................................!C ,he porta/)e4t.properties 9i/e.........................................................!* $nsta//ing Liferay on an >4isting App/ication Server..........................!' $nsta//ing Liferay in A" >asy Steps..................................................!' G/ass9ish !.4.....................................................................................!( G/ass9ish 8.4.....................................................................................8A Jetty +................................................................................................8C J%oss C."8spA 7 C."C 7 C."* 7 C.! 7 C.8..............................................8+ J%oss *.4............................................................................................8# ?rac/e App/ication Server 5?CCJ6....................................................C! Resin 8.A.4.........................................................................................C' Resin 8.!.4.........................................................................................C# ,omcat *.*.D.....................................................................................*" <ebLogic # 7 A"................................................................................*! ?rac/e <ebLogic A".8.......................................................................** <ebSphere +.A..................................................................................*( <ebSphere '."..................................................................................+# :a.ing Liferay Coe4ist -ith ?ther Java >> App/ications....................'C S0::AR1...........................................................................................................'* 3. Configuration.....................................................................................77 L$9>RA1'S 0S>R $&,>R9AC>......................................................................................'' iii

&avigating Liferay..................................................................................'( &avigating the Contro/ @ane/................................................................(" @?R,AL ARC;$,>C,0R>...........................................................................................(A 0sers........................................................................................................(! 0ser Groups.............................................................................................(! Ro/es.........................................................................................................(! ?rganizations..........................................................................................(8 Communities...........................................................................................(8 0S$&G ,;> C?&,R?L @A&>L.....................................................................................(C Adding 0sers...........................................................................................(C 0ser :anagement..................................................................................(+ ?rganizations..........................................................................................(' Communities...........................................................................................(# Community @rovisioning................................................................#" 0ser Groups.............................................................................................#! 0ser Groups and @age ,emp/ates...................................................#8 Ro/es.........................................................................................................#( =efining @ermissions on a Ro/e......................................................#( Specia/ &ote about the @o-er 0sers Ro/e....................................A"A GL?%AL S>RB>R S>,,$&GS.....................................................................................A"A @ass-ord @o/icies..................................................................................A"A Settings..................................................................................................A"! Genera/............................................................................................A"! Authentication2 Genera/ Settings.................................................A"! Authentication2 L=A@....................................................................A"8 Sing/e Sign)?n................................................................................A"# Authentication2 Centra/ Authentication Service 5CAS6...............A"# Authentication2 &,L:...................................................................AA" Authentication2 ?pen$=.................................................................AAA Authentication2 ?penSS?..............................................................AAA Authentication2 Site:inder..........................................................AA! =efau/t 0ser Associations..............................................................AA! Reserved Credentia/s.....................................................................AA! :ai/ ;ost &ames.............................................................................AA8 >mai/ &otifications.........................................................................AA8 $dentification..................................................................................AA8 :isce//aneous2 =isp/ay Settings....................................................AA8 :onitoring............................................................................................AA8 @/ugins Configuration..........................................................................AA8 Server Administration.........................................................................AAC Resources........................................................................................AAC Log Leve/s........................................................................................AAC System @roperties..........................................................................AAC @orta/ @roperties............................................................................AA* Shutdo-n........................................................................................AA* ?pen?ffice......................................................................................AA* @orta/ $nstances....................................................................................AA+ @/ugins $nsta//ation..............................................................................AA+ S0::AR1.........................................................................................................AA+ 4. Lifera Collaboration Suite..............................................................119 SC?@>S.............................................................................................................AA# ARC;$B>= S>,0@S...............................................................................................A!A iv

@>R:$SS$?&S......................................................................................................A!A S;AR$&G...........................................................................................................A!! Any <eb Site.........................................................................................A!! 9aceboo.................................................................................................A!! 9riends...................................................................................................A!8 %L?GS..............................................................................................................A!8 ,he %/ogs @ort/et..................................................................................A!C Configuring the %/ogs @ort/et.......................................................A!* Aggregating %/og >ntries.....................................................................A!( CAL>&=AR.........................................................................................................A!# Configuring the Ca/endar @ort/et........................................................A!# >vent 9rom.....................................................................................A!# >vent Reminder >mai/...................................................................A!# =isp/ay Settings..............................................................................A8" 0sing the Ca/endar @ort/et..................................................................A8" C;A,...............................................................................................................A8A :A$L...............................................................................................................A8! :>SSAG> %?AR=S...............................................................................................A88 >mai/ 9rom............................................................................................A8C :essage Added >mai/...........................................................................A8C :essage 0pdated >mai/.......................................................................A8C ,hread @riorities..................................................................................A8C 0ser Ran.s.............................................................................................A8C RSS.........................................................................................................A8* Anonymous @osting..............................................................................A8* Ratings...................................................................................................A8* @ermissions...........................................................................................A8* Adding Categories.................................................................................A8+ 0sing the :essage %oards...................................................................A8' :essage %oard Administrative 9unctions..........................................A8# :oving ,hreads..............................................................................AC" =e/eting ,hreads............................................................................AC" %anning 0sers................................................................................AC" Sp/itting ,hreads............................................................................AC" >diting @osts...................................................................................AC" @ermissions.....................................................................................ACA <$E$S..............................................................................................................ACA Getting Started -ith the Liferay <i.i.................................................ACA :anaging <i.is....................................................................................AC! Adding and >diting <i.i @ages...........................................................AC8 @age =etai/s...........................................................................................ACC =etai/s..............................................................................................ACC ;istory.............................................................................................AC* $ncoming 7 ?utgoing Lin.s...........................................................AC* Attachments...................................................................................AC* &avigating in the <i.i @ort/et.............................................................AC* S0::AR1.........................................................................................................AC+ 5. Ad!anced Lifera Configuration......................................................147 ,he porta/)e4t.properties 9i/e.............................................................AC' @roperties ?verride.......................................................................AC( Liferay ;ome..................................................................................AC( @orta/ Conte4t................................................................................AC( v

Resource Repositories Root...........................................................AC# ,echno/ogy Compatibi/ity Eit.......................................................AC# Schema............................................................................................AC# 0pgrade...........................................................................................AC# Berify..............................................................................................A*" Auto =ep/oy....................................................................................A*" ;ot =ep/oy......................................................................................A*! ;ot 0ndep/oy..................................................................................A*8 @/ugin..............................................................................................A*8 @ort/et.............................................................................................A*8 @ort/et Coordination......................................................................A*C ,heme..............................................................................................A*C Resource Actions............................................................................A** :ode/ ;ints....................................................................................A** Service %ui/der...............................................................................A** Spring..............................................................................................A** ;ibernate........................................................................................A*+ J=%C.................................................................................................A*( Custom SFL.....................................................................................A+" =atabase..........................................................................................A+" >hcache...........................................................................................A+" JavaScript........................................................................................A+A SFL =ata..........................................................................................A+C Company.........................................................................................A+* 0sers................................................................................................A++ Groups and Ro/es............................................................................A+' ?rganizations.................................................................................A+# Languages and ,ime Gones...........................................................A'" Loo. and 9ee/..................................................................................A'! ReHuest............................................................................................A'! Session.............................................................................................A'! JAAS.................................................................................................A'C L=A@................................................................................................A'* CAS...................................................................................................A'' &,L:...............................................................................................A'' ?pen$=.............................................................................................A'( ?penSS?..........................................................................................A'( Site:inder......................................................................................A'( Authentication @ipe/ine.................................................................A'# Auto Login.......................................................................................A(A SS? -ith :AC 5:essage Authentication Code6...........................A(! @ass-ords.......................................................................................A(8 @ermissions.....................................................................................A(C Captcha...........................................................................................A(* Startup >vents................................................................................A(* Shutdo-n >vents............................................................................A(+ @orta/ >vents...................................................................................A(+ Login event.....................................................................................A(+ Logout event...................................................................................A(' =efau/t Landing @age.....................................................................A(' =efau/t Logout @age.......................................................................A(' =efau/t Guest @ub/ic Layouts........................................................A(' vi

=efau/t 0ser @rivate Layouts.........................................................A(( =efau/t 0ser @ub/ic Layouts..........................................................A(# =efau/t Admin................................................................................A#" Layouts............................................................................................A#" =efau/t Settings Layouts................................................................A#A @ort/et 0RL.....................................................................................A#* @references.....................................................................................A#+ Struts...............................................................................................A#+ $mages.............................................................................................A#+ 9i/eSystem;oo...............................................................................A#' >ditors.............................................................................................A#' 9ie/ds...............................................................................................A#' :ime ,ypes.....................................................................................A#' Amazon...........................................................................................A#( %ro-ser Launcher..........................................................................A#( Contro/ @ane/..................................................................................A#( $nstant :essenger..........................................................................A## Lucene Search.................................................................................A## Source9orge....................................................................................!"A Ba/ue ?bIect....................................................................................!"! Communication Lin......................................................................!"! Content =e/ivery &et-or..............................................................!"8 Counter...........................................................................................!"8 Loc..................................................................................................!"8 J%$....................................................................................................!"8 JCR...................................................................................................!"8 Live 0sers........................................................................................!"C Loc..................................................................................................!"C :ai/..................................................................................................!"C ?pen?ffice......................................................................................!"+ @?@..................................................................................................!"+ Fuartz..............................................................................................!"' Schedu/er........................................................................................!"' Search Container............................................................................!"' Sharepoint......................................................................................!"' Socia/ %oo.mar.s...........................................................................!"( Be/ocity >ngine..............................................................................!"( Birtua/ ;osts...................................................................................!"# ;,,@................................................................................................!"# Serv/et 9i/ters.................................................................................!A" 0p/oad Serv/et ReHuest..................................................................!AA <eb Server......................................................................................!AA <eb=AB..........................................................................................!AA :ain Serv/et....................................................................................!A! A4is Serv/et.....................................................................................!A! JS?& ,unne/ Serv/et.......................................................................!A! Liferay ,unne/ Serv/et...................................................................!A! Spring Remoting Serv/et...............................................................!A! <eb=AB Serv/et.............................................................................!A8 <idget Serv/et................................................................................!A8 Admin @ort/et.................................................................................!A8 Announcements @ort/et.................................................................!A8 vii

Asset @ub/isher @ort/et..................................................................!AC %/ogs @ort/et...................................................................................!AC Ca/endar @ort/et.............................................................................!AC Communities @ort/et......................................................................!A* =ocument Library @ort/et.............................................................!A* $mage Ga//ery @ort/et.....................................................................!A+ $nvitation @ort/et............................................................................!A' Journa/ @ort/et................................................................................!A' Journa/ Artic/es @ort/et..................................................................!A# Journa/ Content Search @ort/et.....................................................!A# :essage %oards @ort/et.................................................................!A# :y @/aces @ort/et............................................................................!!" &avigation @ort/et..........................................................................!!" &ested @ort/ets @ort/et..................................................................!!A @ort/et CSS @ort/et.........................................................................!!A Shopping @ort/et............................................................................!!A Soft-are Cata/og @ort/et................................................................!!! ,ags Compi/er @ort/et....................................................................!!! ,ags @ort/et.....................................................................................!!! ,as.s @ort/et...................................................................................!!8 ,rans/ator @ort/et..........................................................................!!8 <i.i @ort/et.....................................................................................!!8 @L0G$& :A&AG>:>&,..........................................................................................!!* @ort/ets..................................................................................................!!* ,hemes..................................................................................................!!+ Layout ,emp/ates.................................................................................!!' ;oo. @/ugins.........................................................................................!!' <eb @/ugins...........................................................................................!!' $nsta//ing @/ugins from Repositories..................................................!!' $nsta//ing @/ugins :anua//y.................................................................!8" @/ugin ,roub/eshooting.......................................................................!8A Liferay Configuration $ssues.........................................................!8! ,he Container 0pon <hich Liferay $s Running..........................!88 Changing the Configuration ?ptions in :u/tip/e @/aces............!8* ;o- Liferay $s %eing Launched.....................................................!8* Creating 1our ?-n @/ugin Repository................................................!8+ ,he Soft-are Cata/og.....................................................................!8' :anua//y Creating A Soft-are Cata/og.........................................!CC Connecting to a Soft-are Cata/og.................................................!CC L$9>RA1 S>RB$C>S ?R$>&,>= ARC;$,>C,0R>...............................................................!CC Accessing Liferay's <S=L....................................................................!C' ". #nterpri$e Configuration.................................................................249 L$9>RA1 CL0S,>R$&G............................................................................................!*" A// &odes Shou/d %e @ointing to the Same Liferay =atabase............!*A =ocument Library Configuration........................................................!*A Jac.rabbit Sharing................................................................................!*! Search Configuration...........................................................................!*8 @/uggab/e >nterprise Search.........................................................!*8 Lucene Configuration....................................................................!** ;ot =ep/oy.............................................................................................!*+ =$S,R$%0,>= CAC;$&G..........................................................................................!*+ ;ibernate Cache Settings..............................................................!*( viii

C/ustering Jac.rabbit.....................................................................!*# <?RE9L?<.......................................................................................................!*# $nsta//ation and ,est.............................................................................!+" 0sing =ifferent =atabases....................................................................!+A ;o- the <or.f/o- @ort/et <or.s.......................................................!+A @rocess =efinitions.........................................................................!+A $ntegrating -ith 0sers, Communities, and Ro/es........................!+A =ata ,ypes and >rror Chec.ing....................................................!+8 Samp/e @rocess =efinitions...........................................................!+* <arning :essages.........................................................................!++ Administration......................................................................................!+' =ep/oying <or.f/o-s.....................................................................!+' :anaging $nstances.......................................................................!+( :anaging ,as.s..............................................................................!'" 9uture >nhancements..........................................................................!'A Logging............................................................................................!'A Customizab/e 9ront)>nd................................................................!'A 9i/e 0p/oad =ata ,ype....................................................................!'! 9reHuent/y As.ed Fuestions................................................................!'! ;o- do you -rite a ne- process definitionJ...............................!'! <hy are there K=up/icate 9i/eL e4ceptions -hen $ change databases for I%@:J.......................................................................!'! =>@L?1$&G A C0S,?:$G>= L$9>RA1.........................................................................!'! =ep/oying =irect/y on the Server........................................................!'8 =ep/oying from a C/ient :achine........................................................!'C @>R9?R:A&C> ,0&$&G.........................................................................................!'C :emory.................................................................................................!'C Garbage Co//ection................................................................................!'* @roperties 9i/e Changes.......................................................................!'' Serv/et 9i/ters........................................................................................!'( @ort/ets..................................................................................................!'( Read)<riter =atabase Configuration..................................................!'( =atabase Sharding................................................................................!'# 7. %aintaining A Lifera &ortal...........................................................2'3 L$9>RA1 :?&$,?R$&G 0S$&G G??GL> A&AL1,$CS........................................................!(8 %ACE$&G 0@ A L$9>RA1 $&S,ALLA,$?&.....................................................................!(C Source Code...........................................................................................!(C Liferay's 9i/e System.............................................................................!(* =atabase................................................................................................!(* L$9>RA1'S L?GG$&G S1S,>:...................................................................................!(* 0@GRA=$&G L$9>RA1............................................................................................!(' Liferay 0pgrade @rocedure..................................................................!(' 0pgrade Steps.................................................................................!(( 0pgrading Liferay C.8 to Liferay C.C....................................................!(( @rereHuisite ...................................................................................!(( $f 1our =eve/opers ;ave Customized Liferay..............................!(( 0pgrading Liferay C.C to Liferay *."....................................................!(# @rereHuisite ...................................................................................!(# $f 1our =eve/opers ;ave Customized Liferay..............................!(# Converting -i.i pages 5optiona/6 .................................................!(# 0pgrade ,roub/eshooting ............................................................!#" 0pgrading Liferay *." to Liferay *.A....................................................!#" i4

Changes in configuration properties ...........................................!#" ;o- to .eep the o/d va/ues ..........................................................!#" <hat has been changedJ ..............................................................!#" $f 1our =eve/opers ;ave Customized Liferay..............................!#" 0pgrading ,hemes ........................................................................!#A ,he @arent >/ement of the =oc. :ay Change @ositioning <hen 0pgrading.......................................................................................!#! ,he C/ass &ames for =ifferent 0$ Components ;ave Changed . !#! Change in ,heme CSS 9ast Load...................................................!#! Change in Javascript 9ast Load.....................................................!#8 0pgrading @;@ @ort/ets ................................................................!#8 Javascript changes .........................................................................!#8 0pgrading 9rom Liferay *.A to Liferay *.!..........................................!#C @rereHuisite ...................................................................................!#C Changes in configuration properties ...........................................!#* ,heme 0pgrade .............................................................................!#* A@$ Changes ...................................................................................!#+ '. Appendi() *ocu+entation Licen$e...................................................299 CR>A,$B> C?::?&S L$C>&S>.................................................................................!## License...................................................................................................!## Creative Commons &otice....................................................................8"* 9. Colophon..........................................................................................3,7 Inde(....................................................................................................31,

PREFACE

Liferay @orta/ is the /eading open source porta/ in the mar.etp/ace today. $t has received a-ards from mu/tip/e /eading industry pub/ications, and has an impressive do-n/oad rate 5over +",""" do-n/oads a month and over a mi//ion do-n/oads tota/6. <hy is it so popu/arJ %ecause Liferay @orta/ has out of the box a// of the features you need to run a successfu/ -eb site, -hether that site is a pub/ic $nternet site, a corporate $ntranet, or anything in bet-een. ,his boo. -as -ritten -ith the server administrator in mind. $t is a guide for anyone -ho -ants to get a Liferay @orta/ server up and running, and -i// guide you step)by)step through the insta//ation and configuration process. 0se this boo. as a handboo. to getting your Liferay @orta/ insta//a) tion running smooth/y, and then .eep it by your side as you configure and maintain your Liferay)po-ered -eb site. ,he information contained herein has been organized in a -ay that hopefu//y ma.es it easy to /ocate information. <e start at the beginning2 do-n/oading and configuring the Liferay bund/es. 9rom there, -e -or. a// the -ay through the mu/tip/e -ays of insta//ing Liferay manua//y on an ap) p/ication server, to porta/ administration. 1ou'// see ho- to use Liferay's co/) /aboration suite of port/ets to enab/e your users to -or. together more effi) cient/y and more easi/y. 9rom there -e go into advanced administration topics and enterprise configuration, inc/uding c/ustering and integrating Liferay -ith other services. <e round things out by sho-ing you ho- to op) timize Liferay's performance, ho- to manage a Liferay insta//ation, ho- to bac. it up, and ho- to upgrade Liferay if you are moving from a previous version.

4i

What's New in the Third dition

Certain/y, Liferay @orta/ has not stood sti// since the /ast edition -as -ritten. ,his edition has been updated so that it covers Liferay @orta/ up to version *.!. Chapter * 5Advanced Liferay Configuration6 has been comp/ete/y revamped to that it covers a// of the ne- porta/ properties, and the rest of the boo. has been e4haustive/y gone through and updated. ,he chapter on @orta/ Administration 5Chapter 86 has been overhau/ed so that it covers Liferay administration using the ne- Contro/ @ane/. ,his chapter a/so goes over porta/ design, /isting the things you might -ant to consider as you bui/d your -eb site on Liferay @orta/. 9or this edition of the boo., a ne- chapter on Liferay's unpara//e/ed co//aboration suite of port/ets has been provided. ,his chapter -i// guide you through enab/ing your users to co//aborate using the robust set of too/s that Liferay provides2 b/ogs, ca/endar, chat, mai/, message boards, and -i.is. ?ther chapters have been e4panded to inc/ude additiona/ information. 9or e4amp/e, Chapter ' 5Maintaining a Liferay Portal6 no- covers database sharding among other things, and an updated section on upgrading Liferay.

!onventions

Sections are bro.en up into mu/tip/e /eve/s of headings, and these are designed to ma.e it easy to find information. Ti#$ This is a tip. Tips are used to indicate a suggestion or a piece of information that affects whatever is being talked about in the surrounding text. They are always accompanied by this gray box and the icon to the left.

Source code and configuration file directives are presented like this. If source code goes multi-line, the lines will be \ separated by a backslash character like this.

Italics are used to represent /in.s or buttons to be c/ic.ed on in a user interface and to indicate a /abe/ or a name of a Java c/ass. -old is used to describe fie/d /abe/s and port/ets. @age headers denote the chapters, and footers denote the particu/ar section -ithin the chapter.

Pu"lisher Notes

$t is our hope that this boo. -i// be va/uab/e to you, and that it -i// be an indispensab/e resource as you begin to administer a Liferay porta/ server. $f you need any assistance beyond -hat is covered in this boo., Liferay, $nc. offers training, consu/ting, and support services to fi// any need that you might have. @/ease see http277---./iferay.com7-eb7guest7services for fur) ther information about the services -e can provide.

4ii

As a/-ays, -e -e/come any feedbac.. $f there is any -ay you thin. -e cou/d ma.e this boo. better, p/ease fee/ free to mention it on our forums. 1ou can a/so use any of the emai/ addresses on our Contact Us page 5http277---./iferay.com7-eb7guest7aboutMus7contactMus6. <e are here to serve you, our users and customers, and to he/p ma.e your e4perience using Liferay @orta/ the best it can be.

Author Notes

,he first edition of this boo. -as out/ined in a sma// noteboo. 5paper, not a computer6 on a p/ane f/ying from @hi/ade/phia to Los Ange/es. A coup/e of months /ater, it -as rehashed e/ectronica//y in out/ine form among a sma// group of Liferay emp/oyees unti/ the fina/ /ist of content -as con) sidered comp/ete. ,his seems /i.e a -or/d a-ay no-, as so much has changed, not on/y -ith the product, but a/so -ith the company, as Liferay has gro-n so much in the intervening years. 9or this third edition, $ had a target dead/ine to meet2 the boo. had to be ready for the re/ease of the *.! >nterprise >dition of the product. A /ot of hard -or. -ent into po/ishing the materia/ and ma.ing it as error)free as possib/e. ?f course, no one is perfect, and so if -e find any prob/ems -ith the materia/, they -i// be corrected on the errata page for the boo. in Liferay's -i.i 5http277-i.i./iferay.com6. $ have endeavored to give credit to everyone -ho made a contribution 5it's on the copyright page6, but if $ missed somebody3-hich -ou/d not be surprising3p/ease /et me .no- so your name is not /eft out of the ne4t edi) tionN $ cannot e4press enough ho- -onderfu/ it is to be surrounded by so many ta/ented peop/e -ho do everything they can to ma.e this product the best it can be3even -hen a particu/ar tas. is not their primary Iob. ,he engineering team at Liferay is a fantastic group of peop/e, and my Iob -ou/d be a /ot more difficu/t -ere it not for their patience -ith me -hen $ interrupt their -or. -ith some 5pretty dumb, sometimes6 Huestions. So specia/ than.s are due to Ray Auge, &ate Cavanaugh, %rian Chan, A/e4 Cho-, %runo 9arache, Jorge 9errer, and :i.e 1oung. $'d a/so /i.e to than. my daughter Ju/ia for chec.ing in on me from time to time and bringing some good cheer -ith her. And of course, $ -ant to than. my -ife, =eborah, -ho continua//y has to put up -ith /ong hours as a computer -ido-, for her understanding and support. $ cou/dn't do any of this -ithout her. Rich Sezov http277---./iferay.com7-eb7rsezov7b/og

4iii

1. INTRODUCTION

Liferay @orta/ is the -or/d's /eading open source enterprise porta/ so/ution using the /atest in Java and <eb !." techno/ogies. A. !. 8. C. *. +. Runs on a// maIor app/ication servers and serv/et containers, databases, and op) erating systems, -ith over '"" dep/oyment combinations JSR)!(+ Comp/iant ?ut)of)the)bo4 usabi/ity -ith over +" port/ets pre)bund/ed. %ui/t in Content :anagement System 5C:S6 and Co//aboration Suite @ersona/ized pages for a// users %enchmar.ed as among the most secure porta/ p/atforms using LogicLibrary's Logiscan suite

Created for the enterprise, Liferay @orta/ provides a virtua/ space -here you can centra/ize, share and co//aborate. %ui/t -ith the end user in mind, Liferay @orta/'s a-ard -inning user interface is easy enough to master by even the /east technica/ of users. Liferay @orta/ a/so remains one of the most popu/ar porta/ techno/ogies -ithin the deve/oper community -ith an ever)gro-ing /ist of features that he/p your $, team dep/oy business so/utions -ith minima/ time and effort.

!reated %or the nter#rise


Personalization and eas& customization
Give the right peop/e the right access to the right app/ications and documentsN A high/y granu/ar permissions system a//o-s you to customize the user e4perience at

$ntroduction the organizationa/ and persona/ /eve/.

Wor'%low ada#ta"le
LiferayOs techno/ogy is bui/t to Huic./y adapt business and organizationa/ changes, ensuring minima/ do-ntime in todayOs fast)changing mar.et.

(randin) %riendl&
Liferay @orta/ is coded to easi/y adapt to your organizationOs desired branding and /oo. and fee/.

*le+i"le or)anization
Liferay @orta/ is high/y sca/ab/e for /arge, gro-ing user bases. $t accommodates the functiona/ needs of even the most comp/e4 of enterprises))9or e4amp/e, your sub organizations can each be given its o-n porta/ e4perience -ith uniHue 0RL, /ogin, /oo. and fee/ and security permissionsN

(uilt With The nd,-ser .n /ind


Liferay @orta/Os a-ard -inning user interface offers dynamic, intuitive and time saving features that fosters user adoption across your entire organization.

AWAR0,W.NN.NG -.
Liferay @orta/ offers dynamic, intuitive and time saving features that foster user adoption across your entire organization. <e -ere the first porta/ to introduce drag) and)drop port/et re)positioning and continue to de/iver innovative usabi/ity features for even the /east technica/ of usersN

1N ,!L.!2 L112 W ( 1S

AN0

!3ANG S

=ep/oy a ne- /oo. and fee/ -ith one c/ic. -ithout having to touch any codeN

<or. -ith LiferayOs =ocument Library /i.e a net-or. drive on your des.top -ith fami/iar fo/ders. An optiona/ free)f/oating port/et theme mimics the /oo. and fee/ of your des.top environment.

Technolo)& to 3el# 0evelo#ers


@rotect your deve/opment investment. Liferay @orta/Os active and mature com) munity a/-ays .eeps the deve/oper e4perience in mind.

A+

,echno/ogy to ;e/p =eve/opers

$ntroduction

Standards !om#liant
Liferay @orta/ comp/ies -ith .ey industry standards, ma.ing it easy to -or. and integrate -ith.

Read& .nte)ration
@artnerships -ith /eading ?pen Source p/ayers such as A/fresco, $C>soft, Spring) Source, and @entaho ensure unpara//e/ed integration and support for these -ide/y) used techno/ogies.

Li%era& Plu)ins !atalo)


,his e4c/usive feature of Liferay @orta/ .eeps trac. of ne- versions of the soft) -are and instant/y updates the techno/ogy -ithout troub/esome restarts. Liferay supports ALL maIor app servers, databases, and operating systems -ith over '"" dep/oyment configurations. @/ease see our dep/oyment matri4 for more detai/s.

Su##orted Technolo)ies
,echno/ogies 0sed2 Apache Service:i4 ehcache ;ibernate $C>faces Java J!>>7J>> I%@: JGroups IFuery JavaScript 9rame-or. Lucene :u/eSource >S% @;@ Ruby Seam Spring P A?@ Struts P ,i/es ,apestry Be/ocity Standards2 AJAD iCa/endar P :icroformat JSR)!(+ JSR)A!' JSR)A'" Seats on the JSR)!(+ 5@ort/et !."6 and JS9)8AC 5JS9 !."6 committees ?penSearch ?pen p/atform -ith support for -eb services inc/uding2 JS?& ;essian %ur/ap R>S, R:$ <SR@ <eb=AB

Lan)ua)es
Liferay supports $A(& for any /anguage out)of)the)bo4 and ships -ith defau/t trans/ations for !! /anguages. :ost of these trans/ations are maintained by native Languages A'

$ntroduction spea.ers of the /anguages from Liferay's open source community. Additiona/ /an) guages can be added very easi/y, and this has been done many times over the /ife of the product.

A(

Languages

2. INITIAL SETUP

Liferay @orta/ is one of the most f/e4ib/e app/ications -ith regard to app/ication server environment on the mar.et today. 1ou can insta// Liferay @orta/ on everything from a shared ,omcat insta//ation to a mu/ti)node c/uster running a commercia/ ap) p/ication server, and on everything in bet-een. $n fact, Liferay is used successfu//y in a// of these scenarios every day. 1ou -i// find that because Liferay is e4treme/y f/e4ib/e in its dep/oyment options, it is easy to insta// as -e//. $f you a/ready have an app/ication server, you can simp/y use the too/s for dep/oyment that came -ith your app/ication server. $f you do not have an app/ication server, Liferay provides severa/ app/ication server bund/es from -hich to choose. ,hese are very easy to insta// and -ith a sma// amount of configura) tion can be made into production)ready systems.

ditions o% Li%era&
Liferay ships in t-o different editions2 Liferay @orta/ Standard >dition 5S>6 and Liferay @orta/ >nterprise >dition 5>>6. S> is the same Liferay @orta/ that has been avai/ab/e for years2 freHuent/y updated and bursting -ith the /atest features, the standard edition of Liferay @orta/ is offered for free under the business)friend/y :$, open source /icense. Liferay @orta/ >> is a supported version of Liferay @orta/ for the enterprise. ;ardened for security and designed to be roc. so/id stab/e, >> is offered -ith a subscription and support pac.age, a//o-ing organizations to bui/d their porta/s on a stab/e version of the product that is offered over an e4tended period of time. %ecause the re/ease cyc/e for >> is /onger than that for S>, each enterprise re) /ease is supported for C years. A// bug fi4es in Liferay @orta/ are bac.ported to your version of Liferay for the duration of your subscription. ,his gives organizations the peace of mind that comes from .no-ing that their Liferay)po-ered -eb site is stab/e and -i// run for years to come, enab/ing them to bui/d their sites on a proven, stab/e p/atform. Additiona//y, Liferay's professiona/ services team offers training and con) su/ting on the >nterprise >dition to ensure /ong)term support and stabi/ity for our c/i)

$nitia/ Setup ents.

1"tainin) Li%era&
,he S> version of Liferay is free/y do-n/oadab/e from our -eb site at http277---./iferay.com. C/ic. on the Downloads /in. at the top of the page, and you -i// be presented -ith mu/tip/e options for getting a copy of Liferay, inc/uding our convenient bund/es or a .-ar pac.age for insta//ation on your app/ication server of choice. ,he >> version of Liferay -i// be provided to you as a resu/t of your support sub) scription. 1ou -i// be provided -ith do-n/oad /in.s -hich -i// a//o- you to obtain a copy of a Liferay bund/e or a .-ar pac.age for insta//ation on your app/ication server of choice. $f you -ant to insta// a bund/e, there is a /ist of bund/es avai/ab/e. $f you do not current/y have an app/ication server, it is best to do-n/oad the ,omcat bund/e, as ,omcat is one of the sma//est and most straightfor-ard bund/es to configure. $f you have an app/ication server preference, you can a/so choose the server you prefer from the avai/ab/e Liferay @orta/ bund/es. ;aving a J=E 5Java =eve/opment Eit6 a/ready in) sta//ed is a prereHuisite to running any of the bund/es. @/ease note that Liferay is not ab/e to provide app/ication server bund/es for pro) prietary app/ication servers such as <ebLogic, <ebSphere, or ?rac/e App/ication Server because the /icenses for these servers do not a//o- for redistribution. Liferay @orta/, ho-ever, runs Iust as -e// on these app/ication servers as it does on open source app/ication servers. 1ou -i// need to use the .-ar pac.age to insta// Liferay on these app/ication servers. 9or a manua/ insta//, you -i// need the Liferay .-ar fi/e as -e// as Liferay's de) pendency .Iars. Later in this chapter are instructions for insta//ing Liferay on many of the maIor app/ication servers avai/ab/e today.

.nstallin) a (undle
Liferay bund/es contain the same directory structure regard/ess of app/ication server. ,he top)/eve/ fo/der is named for the re/ease of Liferay. ,his fo/der is a/so sometimes ca//ed Liferay Home. $nside this fo/der, you -i// find fo/ders for various uses2 *ata) ,his fo/der is used to store the em) Illustration ! "undle directory bedded ;SFL database -hich the bund/es use, structure as -e// as the configuration and data for the Jac.rabbit JSR)A'" content repository and the Lucene search inde4. *eplo ) @/ugins -hich you -ish to dep/oy to Liferay can be copied into this fo/der. $t is a/so used by Liferay's graphica/ p/ugin insta//er uti/ity, -hich is avai/ab/e from the Contro/ @ane/.

!"

$nsta//ing a %und/e

$nitia/ Setup Licen$e) Contains both Liferay's /icense and a fi/e -hich describes the /icenses for many of the other open source proIects that are used interna//y by Liferay. .Application Ser!er/) ,here -i// a/so be an app/ication server fo/der -hich is different depending on -hich bund/e you have do-n/oaded. ,his fo/der contains the app/ication server in -hich Liferay has been insta//ed. $n most cases, insta//ing a bund/e is as easy as uncompressing the archive and then starting the app/ication server. 9or e4amp/e, if you -ere to insta// Liferay @orta/ on ,omcat, you -ou/d simp/y unzip the bund/e to a /ocation of your choice. &o- you -ou/d start ,omcat in the same -ay as you -ou/d if you had do-n) /oaded it manua//y. ,omcat is /aunched by -ay of a script -hich is found in its bin fo/der. $f you drop to a command prompt and go to this fo/der, you can /aunch ,omcat via the fo//o-ing command on <indo-s2
startup

or the fo//o-ing command on Linu4 7 :ac 7 0ni42


./startup.sh

,he Liferay 7 ,omcat bund/e -i// then /aunch. $f you are on <indo-s, you -i// see another command prompt -indo- appear -ith ,omcat's conso/e in it. $f you are on Linu4, you can see the ,omcat conso/e by issuing the fo//o-ing command2
tail -f ../logs/catalina.out

?nce ,omcat has comp/eted its startup, it shou/d automatica//y /aunch a -eb bro-ser so you can see the home page. $f it does not, /aunch your -eb bro-ser and then go to the fo//o-ing address2 http277/oca/host2("(". ,he defau/t Liferay home page -i// then appear in your -eb bro-ser. $t -i// be using an embedded database for its configuration, but it is fu//y functiona/. 1ou can no- begin e4p/oring the various fea) tures of Liferay.

Illustration #! Default Page in the Liferay "undles Liferay ships by defau/t -ith a samp/e -eb site inc/uded, ca//ed ' Cogs. 1ou can access this site and /og in as the various users to get fami/iar -ith Liferay and -hat it $nsta//ing a %und/e !A

$nitia/ Setup can do. $nsta//ing a different bund/e is done in e4act/y the same -ay2 unzip the bund/e into the fo/der of your choice, /aunch the app/ication server, and then vie- the porta/ in your -eb bro-ser. As you can see, bund/es are the easiest -ay to get started -ith Liferay. ,hey come pre)configured -ith a running Liferay that can be used immediate/y to e4p/ore a// of the things that Liferay can do. And -ith minima/ e4tra configuration 5-hich -e -i// see /ater6, bund/es can be converted into fu// production)ready systems.

.nstallin) Li%era& %or an nter#rise


>ventua//y, you -i// -ant to insta// Liferay onto a rea/ server, after you've com) p/eted your eva/uation and you -ant to begin bui/ding your -eb site. $t is easiest to do this by starting -ith a bund/e and then reconfiguring that bund/e so that it is enter) prise)ready. %ecause this is by far the Huic.est and easiest method to get a production Liferay system running, -e -i// /oo. at this first. ?ften, ho-ever, enterprises -i// have an estab/ished Java >> infrastructure upon -hich they -ou/d /i.e to insta// Liferay. $n this situation, a bund/e -i// not suffice. :ost of this section, therefore, -i// focus on insta//ing Liferay onto an a/ready)estab/ished app/ication server.

Sam#le 0ata
<hi/e the samp/e ' Cogs data is a good e4amp/e of ho- Liferay might be used, -hen you are ready to bui/d your o-n site, you -on't -ant that data c/uttering up your database. So before you connect Liferay to your production database, you -i// -ant to ma.e sure you have removed the samp/e ' Cogs data from your Liferay in) sta//ation. ,his is as simp/e as undep/oying the inc/uded ' Cogs app/ications from the bund/e. ,here are three app/ications inc/uded in the bund/e that you -i// need to remove. ,hese three modify Liferay's defau/t behavior in order to ma.e the ' Cogs app/ication -or. proper/y. %ecause -e -ant to revert Liferay's behavior bac. to its defau/ts for a c/ean insta//, you -i// -ant to remove2 $e!encog$0hook $e!encog$0the+e 1ol0portlet

$f you forget to undep/oy these three app/ications before you connect Liferay to your rea/ database, the samp/e data -i// be created in your database and may cause is) sues, especia//y if you a/ready have data in your database. So you -ant to ma.e sure that you get these three app/ications undep/oyed before setting up your server. 0se your app/ication server's method for undep/oying app/ications in order to remove them.

Li%era& 3ome
$n Liferay *.!." and higher, there is a ne- fo/der defined as Liferay Home. ,his

!!

$nsta//ing Liferay for an >nterprise

$nitia/ Setup fo/der for most app/ication servers is one fo/der higher than the /ocation of the ap) p/ication server itse/f. $n the case of a server -hich defines different domains for dif) ferent instances of the server, this fo/der may be one fo/der up from the domain in -hich Liferay is running. $f Liferay is unab/e to create the resources it needs in this fo/der, or if it finds it) se/f running on certain app/ication servers, it -i// fa// bac. to defining the home fo/der in the home fo/der of the user $= that is running Liferay. As described above in the "undles section, the home fo/der is very important to the operation of Liferay. ,he aforementioned fo/ders 5data$ de%loy$ and license6 -i// be created there, and you can a/so put a specia/ configuration fi/e ca//ed %ortal&ext'%ro%er& ties there. ,his fi/e -i// be fu//y documented in Chapter *2 Advanced Liferay Configuration, but -e -i// use it in this chapter for some basic configuration, inc/uding setting up Liferay to ta/. to our database.

0ata"ase Setu# 0 *A-LT / T310$ A-T1/AT.!


$f you create your database and grant a user $= fu// access to it, Liferay can use that user $= to create its inde4es and tab/es automatica//y. ,his is the recommended -ay to set up Liferay, as it a//o-s you to ta.e advantage of Liferay's abi/ity to auto) matica//y maintain its database through various p/ugin insta//s -hich may create tab/es of their o-n and through upgrades of the p/atform. $t is by far the best -ay to set up your Liferay insta//ation. $f you -i// be setting up Liferay's database -ith the recommended permissions, you can s.ip the ne4t section.

/AN-AL / T310
>ven though Liferay can create its database automatica//y, some enterprises prefer not to a//o- the user $= configured in an app/ication server to have the permis) sions over the database necessary for Liferay and its p/ugins to maintain their tab/es. 9or these organizations, Se/ect, $nsert, 0pdate, and =e/ete are genera//y a// the per) missions that are granted, and so -e -i// go over ho- to set up the database manu) a//y. $f your organization is -i//ing to grant the Liferay user $= permissions to create and drop tab/es in the database3and this is the recommended configuration3you can s.ip this section. ?ne other caveat is this2 Liferay has an automatic database upgrade function -hich runs -hen the version of Liferay is upgraded to a ne- re/ease. $f the user $= that accesses the database does not have enough rights to create 7 modify 7 drop tab/es in the database, you -i// need to grant those rights to the $= before you start your upgraded Liferay for the first time. ?nce the upgrade is comp/ete, you can re) move those rights unti/ the ne4t upgrade. Additiona//y, many p/ugins provided by Liferay reHuire that ne- tab/es be added to Liferay's database. ,hese p/ugins cannot be insta//ed if Liferay does not have permission to create these tab/es automatica//y. $f $nsta//ing Liferay for an >nterprise !8

$nitia/ Setup you -ish to insta// these p/ugins, you -i// need to grant rights to create tab/es in the database before you attempt to insta// them. Liferay provides an SFL script archive do-n/oad on the -eb site. 9or the S> ver) sion, it is in the Additional (iles section of the =o-n/oads page. 9or the >> version, you -i// be provided a /in. to this archive. =o-n/oad this fi/e and unzip it. 1ou -i// find that it contains a fo/der structure that is bro.en do-n by the type of script 5fu//, min) ima/, or upgrade6, and then further by database vendor type. $t is best to use the create&minimal script if you are insta//ing a fresh version of Liferay on a deve/opment, FA, or production server. ,his script creates the necessary Liferay tab/es in the database, -ith a minimum configuration. ,his is most appropri) ate for a ne- insta//ation of Liferay. ,he create script, by contrast, configures a Liferay database -ith a portion of the content from http277---./iferay.com embedded in it. ,his can be usefu/ from a de) ve/opment perspective, as it contains -or.ing e4amp/es of the use of many of Liferay's features, inc/uding the Journa/ Content :anagement System. $nside the create or create&minimal fo/ders are scripts for every database that Liferay supports. A =%A can use the script provided to create the Liferay database, comp/ete -ith the inde4es necessary for optima/ performance. ?nce this is done, be sure that the $= that the porta/ -i// use to connect to the database has at /east Se/ect, $nsert, 0pdate, and =e/ete permissions. @referab/y, ho-ever, the $= shou/d a/so have rights to create, modify, and drop tab/es and inde4es, as this ma.es upgrading easier. ,his, ho-ever, is not necessary for the dai/y operation of Liferay. ?nce your =%A has created the database and provided the credentia/s for access) ing it, you are ready to begin A6 ma.ing a bund/e enterprise)ready or !6 manua//y in) sta//ing Liferay on your app/ication server.

Turnin) a (undle into an nter#rise Portal


Liferay @orta/ is distributed -ith the fo//o-ing bund/e options for serv/et con) tainers and fu// Java >> app/ication servers2 GeronimoQ,omcat G/assfish ! and 8 J%ossQ,omcat C.! J%ossQ,omcat *." Jetty J?nASQJetty J?nASQ,omcat Resin ,omcat *.* ,omcat +."

!C

$nsta//ing Liferay for an >nterprise

$nitia/ Setup Choose your preferred bund/e and do-n/oad it from the do-n/oads page on Liferay's -eb site or via the >> /in.s that -ere provided to you. A prereHuisite for running any of the bund/es is that you have the proper version of the Java =eve/o) ment Eit 5A.* or higher6 insta//ed on the machine to -hich you are insta//ing Liferay. :a.e sure that you have a/so created the JABAM;?:> environment variab/e and have pointed it to your Java insta//ation. 0nzip the bund/e to the /ocation from -hich you are going to run it. 9or e4) amp/e, you might use =2Rapps in <indo-s or 7opt in Linu4 or 0&$D variants. ,he de) fau/t bund/e insta//ation of Liferay @orta/ uses an embedded database. <hi/e this is a good method to have it up and running fast for eva/uation or deve/opment, it has sev) era/ dra-bac.s2 ?n/y one user can access it at a time. ,his is because the data is stored on a fi/e on dis. and ;SFL /oc.s it -hen doing changes. ,he data is stored inside the bund/e and might be /ost on redep/oyment. ,his configuration does not sca/e -e// and -i// have performance prob/ems -hen mu/tip/e users are accessing the system.

?bvious/y, you do not -ant to be running Liferay against the embedded database. 9ortunate/y, Liferay has great support for a good number of production)ready data) bases, and it is easy to configure Liferay to use them. ,he e4act instructions -i// de) pend on the app/ication server and database, but can be summarized as2 A. !. Create the database in your =%:S of choice 5see the above section /abe/ed Database )etu% for further information6. S?ptiona/T Create a =ata Source ca//ed *dbc+LiferayPool in your app/ication server -hich points to your database and has the proper credentia/s to ac) cess it. S?ptiona/T Create a mai/ session ca//ed mail+Mail)ession in your app/ication server -hich points to your mai/ server, so Liferay can send mai/. Create a %ortal&ext'%ro%erties fi/e in the Liferay ;ome fo/der -hich either points direct/y to the database and mai/ session or points to the app/ication server's =ata Source and mai/ session. Start Liferay. Liferay -i// create the tab/es automatica//y and start. ?ther) -ise, you -i// have had to prepare the database first by running the appro) priate create script.

8. C.

*.

Refer to the manua/ insta//ation instructions be/o- for further detai/s on config) uring the various app/ication servers. ,here is no difference bet-een the Liferay bund/es and the regu/ar distribution archives of the app/ication servers as they are avai/ab/e from their o-n sites, -ith the e4ception that Liferay is pre)insta//ed in them, and the JB: settings may have been optimized for use -ith Liferay.

T3

P1RTAL, 4T.PR1P RT. S

*.L

,o point your Liferay bund/e to your database, create a fi/e ca//ed %ortal&ext'%ro%& erties in your Liferay ;ome fo/der. ,his fi/e overrides defau/t properties that come

$nsta//ing Liferay for an >nterprise

!*

$nitia/ Setup -ith Liferay. 1ou are going to override the defau/t configuration -hich points Liferay to the embedded ;SFL database. ,here are t-o -ays to set up the connection2 0se your app/ication server's connection poo/. 0se the bui/t)in connection poo/.

$f you -ant to use your app/ication server's connection poo/, you -i// have to cre) ate one in your app/ication server that points to your database. $t shou/d be ca//ed *dbc+LiferayPool. ,o cause Liferay to use this connection poo/, add the fo//o-ing direct) ive to your %ortal&ext'%ro%erties fi/e2
jdbc.default.jndi.name jdbc/!iferay"ool

,o use the bui/t)in connection poo/3based on C8@",add the temp/ate -hich is provided in Chapter * for your particu/ar database. ,he temp/ate for :ySFL is provided as an e4amp/e be/o-.
# # $yS%! # jdbc.default.driver&lass'ame com.mys(l.jdbc.)river jdbc.default.url jdbc*mys(l*//localhost/lportal+use,nicode true-character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.default.username jdbc.default.password

1ou -ou/d provide the user name and pass-ord to the database as va/ues for the username and %assword directives. 9or mai/, there is a simi/ar procedure. Again, you have t-o -ays to configure your server2 0se your app/ication server's mai/ session. 0se the bui/t)in mai/ session.

,o use your app/ication server's mai/ session, you -i// have to create one in your app/ication server that points to your mai/ server. ?nce you have done that, add the fo//o-ing directive to your %ortal&ext'%ro%erties fi/e2
mail.session.jndi.name mail/$ailSession

,o use the bui/t)in mai/ session, add the fo//o-ing directives to your %ortal&ext'& %ro%erties fi/e, substituting your mai/ server information2
mail.session.mail.pop2.host localhost mail.session.mail.pop2.password mail.session.mail.pop2.port 334 mail.session.mail.pop2.user mail.session.mail.smtp.auth false mail.session.mail.smtp.host localhost mail.session.mail.smtp.password mail.session.mail.smtp.port 56

!+

$nsta//ing Liferay for an >nterprise

$nitia/ Setup
mail.session.mail.smtp.user mail.session.mail.store.protocol pop2 mail.session.mail.transport.protocol smtp

Save the fi/e. 1ou can no- start your app/ication server.

.nstallin) Li%era& on an +istin) A##lication Server


,his section contains detai/ed instructions for insta//ing Liferay @orta/ using its <AR distribution. ,his a//o-s system administrators to dep/oy Liferay in e4isting ap) p/ication server insta//ations. $t is recommended that you have a good understanding of ho- to dep/oy Java >> app/ications in your app/ication server of choice.

.NSTALL.NG L.* RA5 .N 67


A. !. 8.

AS5

ST PS

,here are A" generic steps to insta//ing Liferay on an e4isting app/ication server2 ?btain the Liferay .-ar fi/e and the dependencies archive. :a.e sure you do not have an app/ication /istening at the root 576 of your server. $f you do, move it to a different conte4t or undep/oy it. =ecide -hether you -ant to use your app/ication server's data sources or if you -ant to use the one inc/uded -ith Liferay. $f you -ant to use your ap) p/ication server's data source, create a data source for Liferay ca//ed *dbc+LiferayPool. =ecide -hether you -ant to use your app/ication server's mai/ session or if you -ant to use the one inc/uded -ith Liferay. $f you -ant to use your ap) p/ication server's mai/ session, create one ca//ed mail+Mail)ession. Shut your app/ication server do-n. >4tract the dependencies to a /ocation on your server's g/oba/ c/ass path. ,his a//o-s both Liferay and p/ugins to access these dependencies. Create a %ortal&ext'%ro%erties fi/e and p/ace it in the Liferay ;ome fo/der. Gen) era//y, this is one fo/der up from -here your app/ication server is insta//ed. See the notes on specific app/ication servers be/o- for the /ocation of this fo/der for your app/ication server. Add either the J&=$ name of your data source or the J=%C parameters above to connect Liferay to your database. Add either the J&=$ name of your mai/ session or the mai/ parameters above to connect Liferay to your mai/ server.

C.

*. +. '.

(. #.

A". Start your app/ication server, dep/oy the Liferay .-ar fi/e, and start it. ,he instructions be/o- are specific for each app/ication server that Liferay sup) ports. Liferay supports a -ide combination of app/ication servers and databases. %e) cause of this, for brevity this section assumes :ySFL as the database, that the data) base has a/ready been created, and that you are using your app/ication server's mai/ session and data source. ,o use other databases, substitute the J=%C driver and 0RL construct for your database in p/ace of the :ySFL ones sho-n here. $nsta//ing Liferay for an >nterprise !'

$nitia/ Setup <e a/so assume your app/ication server is a/ready insta//ed and running success) fu//y. $f you sti// need to insta// your app/ication server, p/ease fo//o- your vendor's instructions first. ,he fo//o-ing instructions assume an insta//ation on a /oca/ machine. <hen in) sta//ing to a remote server, substitute localhost -ith the host name or $@ of the server. Remember, for a// of these app/ication servers, create your %ortal&ext'%ro%erties fi/e in the Liferay ;ome fo/der and ma.e sure it points to your database connection poo/ and mai/ session. Ti#$ Note that Liferay 5.x requires JD !.5 or greater. Do not attempt to in" stall Liferay 5.x on an application server that runs under Java !.# or lower$ it will not work. %f you are running an application server that ships with a JD and that JD is !.# or lower& you will need to upgrade your application server in order to user Liferay 5.x. Liferay #.x& however& will run fine on these application servers.

GLASS*.S3 8.4
Lifera 2o+e is one fo/der above G/ass9ish's insta// /ocation. A. !. 8. C. *. =o-n/oad the /atest Liferay @orta/ .-ar fi/e and dependencies. Copy the dependencies .Iars into -.LA))(I)H/H0M1+domains+domain +lib, -here -.LA))(I)H/H0M1 is the directory -here G/assfish is insta//ed. Copy xercesIm%l'*ar and J=%C driver into the same p/ace. Start G/assfish if it hasn't a/ready been started. Go to the G/assfish Adminis) tration Conso/e at http277/oca/host2C(C(. =efau/t /ogin credentia/s are u$er na+e) adminU pa$$1ord) adminadmin'

Illustration 2! .lassfish 3D"C Connection Pool

0ATA(AS !1N*.G-RAT.1N
$f you -ant G/assfish to manage your data source, fo//o- the instructions be/o-. $f you -ant Liferay to manage your data source, you can s.ip this section.

!(

$nsta//ing Liferay for an >nterprise

$nitia/ Setup A. !. 0nder 0ther 4as5s, se/ect Create 6ew 3D"C Connection Pool' $n the first screen, give it a name of LiferayPool, a Resource ,ype of *avax's7l'& ConnectionPoolData)ource, and se/ect My)8L as the =atabase Bendor. C/ic. 6ext' ?n the ne4t page, scro// do-n to the Additional Pro%erties section. 9ind the property ca//ed U9L, and set its va/ue to2
jdbc*mys(l*//localhost/lportal+use,nicode true-amp7character.ncoding ,/0-1-amp7emulate!ocators true

8.

$f your database is not on the same server as G/assfish, substitute your data) base server's host name for localhost above. C. *. +. '. C/ic. Add Pro%erty, and add a property ca//ed user -ith a va/ue of the user name to connect to the database. C/ic. Add Pro%erty again, and add a property ca//ed %assword -ith a va/ue of the pass-ord to connect to the database. C/ic. (inish' 1ou -i// no- see a /ist of Connection @oo/s. ,o test your connection, c/ic. the LiferayPool and c/ic. the Ping button. $f you get a &ing Succeeded mes) sage, everything has been set up correct/y. C/ic. 3D"C 9esources. 1ou -i// see a /ist of J=%C Resources by J&=$ &ame. C/ic. 6ew.

(. #.

A". :a.e the J&=$ &ame *dbc+LiferayPool and se/ect the Liferay@oo/ you created ear/ier. AA. C/ic. 0:'

Illustration ;! .lassfish Mail )ession

/A.L !1N*.G-RAT.1N
$f you -ant G/ass9ish to manage your mai/ session, fo//o- the instructions be/o-. $f you -ant Liferay to manage your mai/ session, you can s.ip this section.

$nsta//ing Liferay for an >nterprise

!#

$nitia/ Setup A. !. 8. C. 0nder 9esources, c/ic. 3avaMail )essions. C/ic. 6ew' Give the Java:ai/ Session a J&=$ name of mail+Mail)ession, and fi// out the rest of the form -ith the appropriate information for your mai/ server. C/ic. 0:'

0 PL15 L.* RA5


A. !. 8. C. *. +. '. C/ic. A%%lication )erver at the top of the tree hierarchy on the /eft. C/ic. 3<M )ettings )V 3<M 0%tions' C/ic. Add 3<M 0%tion, and enter the fo//o-ing2
-)com.sun.enterprise.server.ss.8S%uickStartup false

C/ic. )ave' Log out of the Administration Conso/e and stop G/assfish. =ep/oy Liferay by copying the /iferay)porta/)4.4.4.-ar fi/e you do-n/oaded in step A into the -.LA))(I)H/H0M1+domains+domain +autode%loy directory. Create a fi/e ca//ed %ortal&ext'%ro%erties. Add the fo//o-ing directives to the fi/e2

jdbc.default.driver&lass'ame com.mys(l.jdbc.)river jdbc.default.url jdbc*mys(l*//localhost/lportal+use,nicode true-character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.default.username root jdbc.default.password root

$f you are using G/ass9ish's data source, add the J&=$ name instead2
jdbc.default.jndi.name jdbc/!iferay"ool

=o the same thing for the :ai/ Session. $f you are using the bui/t)in config) uration, set the fo//o-ing properties for your system2
mail.session.mail.pop2.host localhost mail.session.mail.pop2.password mail.session.mail.pop2.port 334 mail.session.mail.pop2.user mail.session.mail.smtp.auth false mail.session.mail.smtp.host localhost mail.session.mail.smtp.password mail.session.mail.smtp.port 56 mail.session.mail.smtp.user mail.session.mail.store.protocol pop2 mail.session.mail.transport.protocol smtp

$f you are using G/assfish's mai/ session, add the J&=$ name instead2
mail.session.jndi.name mail/$ailSession

8"

$nsta//ing Liferay for an >nterprise

$nitia/ Setup Save and c/ose the fi/e. (. Start G/ass9ish. <hen Liferay finishes starting, open http277/oca/host2("(" in your bro-ser. 1ou shou/d see the defau/t Liferay home page.

GLASS*.S3 9.4
Lifera 2o+e is in the G/assfish root fo/der. <e -i// assume for these instruc) tions that you are using the defau/t domain stored in =.lass(ish 9oot>+glassfish+do& mains+domain . A. %efore starting G/ass9ish, you -i// need to modify some settings in the do) main you -i// be using to increase the defau/t amount of memory avai/ab/e. $n your domain fo/der is a config fo/der. ?pen the fi/e ca//ed domain'xml in this fo/der. At appro4imate/y /ine A++ of this fi/e, you -i// find the fo//o-ing JB: option being set2
9jvm-options:-;m<635m9/jvm-options:

!.

Change this to2


9jvm-options:-;m<345=m9/jvm-options:

8.

Add another /ine after this /ine -ith the fo//o-ing JB: option2
9jvm-options:-;;*$a<"ermSi>e 56?m9/jvm-options:

Save and c/ose the fi/e. C. $n your domain fo/der is a fo/der ca//ed docroot. ,his fo/der contains a defau/t page for the domain in a fi/e ca//ed index'html. =e/ete or move this fi/e to an) other /ocation. >4tract the Liferay dependencies archive into your domain's lib fo/der. >4) tract your database's J=%C driver here as -e//.

*.

0ATA(AS !1N*.G-RAT.1N
$f you -ant G/ass9ish to manage the data source, use the fo//o-ing instructions. $f you -ant to use the bui/t)in Liferay data source, you can s.ip this section. A. Go to the G/ass9ish conso/e 0RL2 http277/oca/host2C(C(.

$nsta//ing Liferay for an >nterprise

8A

$nitia/ Setup

Illustration ?! .lassfish 3D"C Connection Pool !. 8. 0nder 0ther 4as5s, se/ect Create 6ew 3D"C Connection Pool' $n the first screen, give it a name of LiferayPool, a Resource ,ype of *avax's7l'& ConnectionPoolData)ource, and se/ect My)8L as the =atabase Bendor. C/ic. 6ext' ?n the ne4t page, scro// do-n to the Additional Pro%erties section. 9ind the property ca//ed U9L, and set its va/ue to2
jdbc*mys(l*//localhost/lportal+use,nicode true-amp7character.ncoding ,/0-1-amp7emulate!ocators true

C.

*. +. '. (. #.

$f your database is not on the same server as G/assfish, substitute your data) base server's host name for localhost above. C/ic. Add Pro%erty, and add a property ca//ed user -ith a va/ue of the user name to connect to the database. C/ic. Add Pro%erty again, and add a property ca//ed %assword -ith a va/ue of the pass-ord to connect to the database. C/ic. (inish' 1ou -i// no- see a /ist of Connection @oo/s. ,o test your connection, c/ic. the LiferayPool and c/ic. the Ping button. $f you get a &ing Succeeded mes) sage, everything has been set up correct/y.

A". C/ic. 3D"C 9esources. 1ou -i// see a /ist of J=%C Resources by J&=$ &ame. AA. C/ic. 6ew. A!. :a.e the J&=$ &ame *dbc+LiferayPool and se/ect the Liferay@oo/ you created ear/ier. A8. C/ic. 0:'

/A.L !1N*.G-RAT.1N
At the time of this -riting, Java:ai/ is not yet imp/emented in G/ass9ish 8. 9or this reason, you -i// have to use the mai/ session that is provided by Liferay. 8! $nsta//ing Liferay for an >nterprise

$nitia/ Setup

0 PL15 L.* RA5


A. Create a fi/e ca//ed %ortal&ext'%ro%erties. Add the fo//o-ing directives to the fi/e2

jdbc.default.driver&lass'ame com.mys(l.jdbc.)river jdbc.default.url jdbc*mys(l*//localhost/lportal+use,nicode true-character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.default.username root jdbc.default.password root

$f you are using G/ass9ish's data source, add the J&=$ name instead2
jdbc.default.jndi.name jdbc/!iferay"ool

=o the same thing for the :ai/ Session. $f you are using the bui/t)in config) uration, set the fo//o-ing properties for your system2
mail.session.mail.pop2.host localhost mail.session.mail.pop2.password mail.session.mail.pop2.port 334 mail.session.mail.pop2.user mail.session.mail.smtp.auth false mail.session.mail.smtp.host localhost mail.session.mail.smtp.password mail.session.mail.smtp.port 56 mail.session.mail.smtp.user mail.session.mail.store.protocol pop2 mail.session.mail.transport.protocol smtp

G/ass9ish 8 has not yet imp/emented Java:ai/, so you do not have the option to use one via J&=$. Save and c/ose the fi/e. !. 8. C. *. +. Go to the G/ass9ish conso/e 0RL2 http277/oca/host2C(C( C/ic. @eb A%%lications in the tree on the /eft. C/ic. the De%loy button. C/ic. "rowse and bro-se to the /ocation of the Liferay .-ar fi/e. Leave the rest of the defau/ts and c/ic. 0:.

Liferay -i// be dep/oyed and started automatica//y.

$nsta//ing Liferay for an >nterprise

88

$nitia/ Setup

J TT5 :
A. !. 8. C. *.

Illustration B! De%loying Liferay in .lass(ish 2

Lifera 2o+e is one fo/der above Jetty's insta// /ocation. =o-n/oad and insta// Jetty +. =o-n/oad the Liferay @orta/ .-ar fi/e. =o-n/oad Liferay @orta/ =ependencies. Create a -3144A/H0M1+lib+ext directory and copy the dependencies to it. >dit -3144A/H0M1+extra+etc+start&%lus'config.
@Ajetty.homeB/lib/e<t/ @Ajetty.homeB/lib/e<t/C

+.

Create a data source -3144A/H0M1+etc+*etty'xml.


9&all name DaddServiceD: 98rg: 9'ew 9Set

bound

to

*dbc+LiferayPool

by

editing

class Dorg.mortbay.jetty.plus.EotmServiceD: name D'ameD:/ransaction$gr9/Set: name Dadd)ataSourceD: 98rg:jdbc/!iferay"ool9/8rg: 98rg: 9'ew 9Set class Dorg.enhydra.jdbc.standard.Standard;8)ataname D)river'ameD:com.mys(l.jdbc.)river9/Set: 9&all

SourceD:

9Set name D,rlD:jdbc*mys(l*//localhost/lportal+use,nicode true-amp7character.ncoding ,/0-19/Set:

8C

$nsta//ing Liferay for an >nterprise

$nitia/ Setup
9Set 9Set 9/'ew: 9/8rg: 98rg: SourceD: 9'ew 98rg 9Set 9Set 9/'ew: 9/8rg: 9/&all: 9/'ew: 9/8rg: 9/&all: class Dorg.enhydra.jdbc.pool.Standard;8"ool)atatype DIntegerD:=9/8rg: name D$inSi>eD:=9/Set: name D$a<Si>eD:369/Set: name D,serD:9/Set: name D"asswordD:9/Set:

'.

=o-n/oad mys7l&connector&*ava&C-versionD&bin'*ar and copy to to -3144A/H0M1+lib+ext. ,his is the J=%C driver for :ySFL. $f you are using a different database, copy the appropriate driver. Create a mai/ session bound to mail+Mail)ession by editing -3144A/H0M1+etc+ *etty'xml2
9&all name DaddServiceD: 98rg: 9'ew 9Set 9Set 9"ut 9/'ew: 9/8rg: 9/&all: class Dorg.mortbay.jetty.plus.$ailServiceD: name D'ameD:$ailService9/Set: name DE')ID:mail/$ailSession9/Set: name Dmail.smtp.hostD:localhost9/"ut:

(.

#.

Create -3144A/H0M1+etc+*aas'config.
"ortalFealm G com.liferay.portal.kernel.security.jaas."ortal!ogin$odule H7 re(uired7

A". Create directory -3144A/H0M1+weba%%s+root and unpac. the Liferay .-ar fi/e into it. AA. Go to -3144A/H0M1+weba%%s+root+@1"&I6(+lib and de/ete xercesIm%l'*ar and xml&a%is'*ar. A*. Copy -3144A/H0M1+weba%%s+root+@1"&I6(+lib+commons&logging'*ar -3144A/H0M1+ext 5over-riting e4isting one6. A+. Create batch fi/e. A. !. Create a directory -3144A/H0M1+bin' Create run'bat 5&ote, this is for <indo-s p/atform. 9or other p/at) to

$nsta//ing Liferay for an >nterprise

8*

$nitia/ Setup forms, configure according/y6.


Iecho off if DD DJE8K8LMN$.JD goto errorEavaMome

JE8K8LMN$.J/bin/java -;m<635m -)file.encoding ,/01 -)user.time>one O$/ )java.security.auth.login.config ../etc/jaas.config -)S/8F/ ../e<tra/etc/start-plus.config -jar ../start.jar ../etc/jetty.<ml goto end

*errorEavaMome echo goto *end E8K8LMN$. end not defined.

3ote) $f you get a Iava./ang.?ut?f:emory>rror e4ception -hi/e starting up Jetty, give your JB: more memory by setting &Emx? #m. Start Liferay by running run'bat. ?pen your bro-ser to http277/oca/host2("(". 1ou shou/d see the defau/t Liferay home page.

J(1SS ;.79SP6 < ;.7; < ;.7= < ;.8 < ;.9
Lifera 2o+e is one fo/der above J%oss's insta// /ocation. !. 8. C. =o-n/oad and insta// J%oss AS into your preferred directory. 9rom no- on, the directory -here you insta//ed J%oss -i// be referred to as WJ%?SSM;?:>. =o-n/oad the Liferay @orta/ .-ar fi/e and dependencies. >dit -3"0))/H0M1+server+default+de%loy+*boss&web'de%loyer+conf+web'xml. Re) p/ace the defau/t serv/et 5/ines '#)#A6 2
9servlet: 9servlet-name:default9/servlet-name: 9servlet-class:org.apache.catalina.servlets.)efaultServlet9/servlet-class: 9init-param: 9param-name:debug9/param-name: 9param-value:49/param-value: 9/init-param: 9init-param: 9param-name:listings9/param-name: 9param-value:true9/param-value: 9/init-param: 9load-on-startup:39/load-on-startup: 9/servlet:

-ith2

8+

$nsta//ing Liferay for an >nterprise

$nitia/ Setup
9servlet: 9servlet-name:default9/servlet-name: 9servlet-class:org.apache.catalina.servlets.)efaultServlet9/servlet-class: 9init-param: 9param-name:debug9/param-name: 9param-value:49/param-value: 9/init-param: 9init-param: 9param-name:listings9/param-name: 9param-value:false9/param-value: 9/init-param: 9init-param: 9param-name:input9/param-name: 9param-value:=4P?9/param-value: 9/init-param: 9init-param: 9param-name:output9/param-name: 9param-value:=4P?9/param-value: 9/init-param: 9load-on-startup:39/load-on-startup: 9/servlet:

*.

Go to -3"0))/H0M1+server+default+lib+, do-n/oad mysH/)connector)Iava) XWversionY)bin.Iar and copy to this directory. ,his is the J=%C driver for :ySFL. $f you are using a different database, copy the appropriate driver. @ut the Liferay @orta/ dependency .Iars into -3"0))/H0M1+server+default+lib.

+.

0ATA(AS !1N*.G-RAT.1N
$f you -ant J%oss to manage the data source, use the fo//o-ing instructions. $f you -ant to use the bui/t)in Liferay data source, you can s.ip this section. Create -3"0))/H0M1+server+default+de%loy+liferay&ds'xml -ith fo//o-ing content2
9datasources: 9local-t<-datasource: 9jndi-name:jdbc/!iferay"ool9/jndi-name: 9connection-url: jdbc*mys(l*//localhost/lportal+ use,nicode true-amp7character.ncoding ,/0-1 9/connection-url: 9driver-class:com.mys(l.jdbc.)river9/driver-class: 9user-name:9/user-name: 9password:9/password: 9min-pool-si>e:49/min-pool-si>e: 9/local-t<-datasource: 9/datasources:

$nsta//ing Liferay for an >nterprise

8'

$nitia/ Setup

/A.L !1N*.G-RAT.1N
$f you -ant J%oss to manage the mai/ configuration, use the fo//o-ing instruc) tions. $f you -ant to use the bui/t)in Liferay mai/ session, you can s.ip this section. Set mai/ properties by rep/acing the contents of -3"0))/H0M1+server+default+de& %loy+mail&service'xml -ith2
9+<ml version D3.4D+: 9server: 9mbean code Dorg.jboss.mail.$ailServiceD vice $ailSessionD: 9attribute 9attribute 9attribute 9attribute 9property 9property 9property 9property 9property name D,serD:nobody9/attribute: name D"asswordD:password9/attribute: name D&onfigurationD: name Dmail.store.protocolD name Dmail.imap.hostD name Dmail.pop2.hostD name Dmail.smtp.hostD value DimapD /: /: /: /: /: name Djboss*ser-

name DE')I'ameD:mail/$ailSession9/attribute:

9configuration: name Dmail.transport.protocolD value DsmtpD

value DlocalhostD value DlocalhostD value DlocalhostD

9/configuration: 9/attribute: 9/mbean: 9/server:

0 PL15 L.* RA5


Configure JAAS. >dit -3"0))/H0M1+server+default+conf+login&config'xml and com) ment out the entire D:L for po/icy other in /ines AC")A*+.
9Q--9application-policy name ... 9Q--9authentication: 9login-module th.spi.,sersFoles!ogin$oduleD flag 9/authentication: 9/application-policy:--: code Dorg.jboss.security.au/: DotherD:--:

Dre(uiredD

=ep/oy the Liferay @orta/ .-ar fi/e. Create ne- directory -3"0))/H0M1+server+default+de%loy+liferay& %ortal'war' 0nzip /iferay)porta/)4.4.4.-ar to directory. Go into -3"0))/H0M1+server+default+de%loy+liferay&%ortal'war+lib' :ove domCI.Iar, Ia4en.Iar to -3"0))/H0M1+lib' :ove commons)co//ections.Iar goes to -3"0))/H0M1+serv& er+default+lib' $nsta//ing Liferay for an >nterprise

8(

$nitia/ Setup remove hibernate8.Iar, Iboss)hibernate.Iar -3"0))/H0M1+server+default+lib' from

>dit -3"0))/H0M1+server+default+de%loy+*boss*ca&service'xml. Change the =ebug at) tribute in /ine +8 from true to fa/se2
9attribute name D)ebugD:false9/attribute:

>dit -3"0))/H0M1+server+default+de%loy+*ms+*bossm7&destinations&service'xml. C/ear out te4t bet-een server tags2


9+<ml version D3.4D+: 9server: 9/server:

Create a fi/e ca//ed %ortal&ext'%ro%erties. Add the fo//o-ing directives to the fi/e2
jdbc.default.driver&lass'ame com.mys(l.jdbc.)river jdbc.default.url jdbc*mys(l*//localhost/lportal+use,nicode true-character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.default.username root jdbc.default.password root

$f you are using J%oss's data source, add the J&=$ name instead2
jdbc.default.jndi.name jdbc/!iferay"ool

=o the same thing for the :ai/ Session. $f you are using the bui/t)in config) uration, set the fo//o-ing properties for your system2
mail.session.mail.pop2.host localhost mail.session.mail.pop2.password mail.session.mail.pop2.port 334 mail.session.mail.pop2.user mail.session.mail.smtp.auth false mail.session.mail.smtp.host localhost mail.session.mail.smtp.password mail.session.mail.smtp.port 56 mail.session.mail.smtp.user mail.session.mail.store.protocol pop2 mail.session.mail.transport.protocol smtp

$f you are using J%oss's mai/ session, add the J&=$ name instead2
mail.session.jndi.name mail/$ailSession

Save and c/ose the fi/e. Start J%oss. ?pen your bro-ser to http277/oca/host2("(". 1ou shou/d see the de) fau/t Liferay home page.

J(1SS =.4
Lifera 2o+e is one fo/der above J%oss's insta// /ocation. A. =o-n/oad and insta// J%oss AS *.".A GA into your preferred directory. ,his directory -i// be referred to be/o- as -3"0))/H0M1. 8#

$nsta//ing Liferay for an >nterprise

$nitia/ Setup !. 8. =o-n/oad the /atest version of the Liferay @orta/ .-ar fi/e. Go to -3"0))/H0M1+server+default+lib+. =o-n/oad mysH/)connector)Iava) XWversionY)bin.Iar and copy to this directory. 5,his is the J=%C connector for :ySFL. 0se the appropriate driver for your database.6 =o-n/oad Liferay's @orta/ =ependencies. 0nzip to -3"0))/H0M1+server+de& fault+lib. Configure JAAS. >dit -3"0))/H0M1+server+default+conf+login&config'xml and comment out the entire D:L for po/icy other in /ines AA*)A8A.
DotherD:--:

C. *.

9Q--9application-policy name ... 9Q--9authentication: 9login-module code flag Dre(uiredD /:

Dorg.jboss.security.

auth.spi.,sersFoles!ogin$oduleD 9/authentication: 9/application-policy:--:

0ATA(AS !1N*.G-RAT.1N
$f you -ant J%oss to manage the data source, use the fo//o-ing instructions. $f you -ant to use the bui/t)in Liferay data source, you can s.ip this section. Create -3"0))/H0M1+server+default+de%loy+liferay&ds'xml -ith fo//o-ing content2
9datasources: 9local-t<-datasource: 9jndi-name:jdbc/!iferay"ool9/jndi-name: 9connection-url: jdbc*mys(l*//localhost/lportal+use,nicode true-amp7character.ncoding ,/0-1 9/connection-url: 9driver-class:com.mys(l.jdbc.)river9/driver-class: 9user-name:9/user-name: 9password:9/password: 9min-pool-si>e:49/min-pool-si>e: 9/local-t<-datasource: 9/datasources:

/A.L !1N*.G-RAT.1N
$f you -ant J%oss to manage the mai/ configuration, use the fo//o-ing instruc) tions. $f you -ant to use the bui/t)in Liferay mai/ session, you can s.ip this section. Set mai/ properties by rep/acing the contents of -3"0))/H0M1+server+default+de& %loy+mail&service'xml -ith2
9+<ml version D3.4D+: 9server:

C"

$nsta//ing Liferay for an >nterprise

$nitia/ Setup
9mbean code Dorg.jboss.mail.$ailServiceD name D,serD:nobody9/attribute: name D"asswordD:password9/attribute: name D&onfigurationD: name Dmail.store.protocolD name Dmail.imap.hostD name Dmail.pop2.hostD name Dmail.smtp.hostD value DimapD /: /: /: /: /: name Djboss*service $ailSessionD:

9attribute 9attribute 9attribute 9attribute 9property 9property 9property 9property 9property

name DE')I'ameD:mail/$ailSession9/attribute:

9configuration: name Dmail.transport.protocolD value DsmtpD

value DlocalhostD value DlocalhostD value DlocalhostD

9/configuration: 9/attribute: 9/mbean: 9/server:

0 PL15 L.* RA5


A. !. 8. C. *. +. =e/ete a// the fi/es and WJ%?SSM;?:>7server7defau/t7dep/oy7R??,.-ar 0nzip the Liferay .-ar fi/e to the R??,.-ar directory. Go to -3"0))/H0M1+server+default+de%loy+9004'war+lib' Remove Ia4en.Iar, Ia4rpc.Iar, sta4.Iar, 4erces$mp/.Iar, 4m/)apis.Iar from -3"0))/H0M1+server+default+de%loy+9004'war+@1"&I6(+lib &avigate to the Liferay ;ome fo/der, -hich is one fo/der above J%oss's insta// /ocation. Create a fi/e ca//ed %ortal&ext'%ro%erties. Add the fo//o-ing directives to the fi/e2 fo/ders in

jdbc.default.driver&lass'ame com.mys(l.jdbc.)river jdbc.default.url jdbc*mys(l*//localhost/lportal+use,nicode true-character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.default.username root jdbc.default.password root

$f you are using J%oss's data source, add the J&=$ name instead2
jdbc.default.jndi.name jdbc/!iferay"ool

=o the same thing for the :ai/ Session. $f you are using the bui/t)in config) uration, set the fo//o-ing properties for your system2
mail.session.mail.pop2.host localhost mail.session.mail.pop2.password mail.session.mail.pop2.port 334 mail.session.mail.pop2.user mail.session.mail.smtp.auth false mail.session.mail.smtp.host localhost mail.session.mail.smtp.password

$nsta//ing Liferay for an >nterprise

CA

$nitia/ Setup
mail.session.mail.smtp.port 56 mail.session.mail.smtp.user mail.session.mail.store.protocol pop2 mail.session.mail.transport.protocol smtp

$f you are using J%oss's mai/ session, add the J&=$ name instead2
mail.session.jndi.name mail/$ailSession

Save and c/ose the fi/e. Start J%oss. ?pen your bro-ser to http277/oca/host2("(". 1ou shou/d see the de) fau/t Liferay home page.

1RA!L APPL.!AT.1N S R> R ?1!;J@


Lifera 2o+e is /ocated in the home fo/der of the user running ?CCJ. ,hese instructions assume you have an insta//ed ?CCJ container A".A.8.C." in a fo/der that -i// be referred to as -0C;3/H0M1. 0nzip the dependencies archive 5-hich is do-n/oadab/e from Liferay's -eb site6 into -0C;3/H0M1+*#ee+home+a%%lib. @ut your J=%C driver here as -e//. ?CCJ contains a startup script in the bin fo/der of the app/ication server direct) ory. 1ou -i// need to edit this fi/e and change some of the arguments. ?n <indo-s systems, the fi/ename of the script is oc;*'cmd. ?n Linu4 7 0ni4 systems, the fi/ename of the script is oc;*. 9ind the /ine in this fi/e that contains the JB:ARGS variab/e2
EK$8FOS @N&=ELEK$L8FOS

:odify the /ine so it reads /i.e the fo//o-ing2


EK$8FOS @N&=ELEK$L8FOS -)oc=j.jm<.security.pro<y.off true -;ms635m -;m<635m -;;*$a<"ermSi>e 56?m

0ATA(AS
A.

AN0

!1NN

!T.1N

P11L

$f you are using Liferay's bui/t)in data source, you can s.ip this section. C/ic. Administration )V 3D"C 9esources'

!. 8. C.

Illustration F! 0C;3! 3D"C 9esources 0nder Connection Pools, c/ic. Create' Se/ect 6ew Connection Pool and c/ic. Continue' Give it a name, such as LiferayPool. $f you are not using an ?rac/e database, you -i// have to specify the connection factory c/ass manua//y. 9or e4amp/e,

C!

$nsta//ing Liferay for an >nterprise

$nitia/ Setup the connection factory c/ass for :ySFL is com'mys7l'*dbc'*dbc#'o%tional'Mys7l& ConnectionPoolData)ource. *. 9i// out the J=%C 0RL to your database. 1ou shou/d have a/ready configured your database and optiona//y run the Liferay create script.

Illustration G! 0C;3! Connection Pool +. '. (. C/ic. (inish. 0nder Data )ources, c/ic. Create. Se/ect Managed Data )ource 5de) fau/t6 and c/ic. Continue. Give it a name 5LiferayData)ource6 and a J&=$ /ocation of *dbc+LiferayPool. Se/ect the Connection @oo/ you created in the previous step and then c/ic. (inish.

$nsta//ing Liferay for an >nterprise

C8

$nitia/ Setup

Illustration K! 0C;3! Liferay Data )ource #. C/ic. the 4est Connection icon. $f you are not using an ?rac/e database, change the test SFL to something /i.e )1L1C4 H from User/, and then c/ic. ,est. 1ou shou/d get a message saying Connection to ILiferayData)ourceI es& tablished successfully. $f not, go bac. and chec. your settings.

A". C/ic. the 0C;3! home /in. in the top /eft of the page.

.NSTALL.NG L.* RA5


A. !. C/ic. A%%lications. C/ic. De%loy. Leave the defau/t se/ected under Archive, and c/ic. the "rowse button. %ro-se to -here your Liferay .-ar fi/e is.

8.

Illustration J! De%loying the Liferay 'war file on 0C;3 <ith the /ocation of the Liferay .-ar fi/e in the Archive Location fie/d, c/ic. 6ext. <ait a -hi/e -hi/e ?CCJ up/oads the Liferay .-ar fi/e. $nsta//ing Liferay for an >nterprise

CC

$nitia/ Setup C. *. +. ,he ne4t screen a//o-s you to give the app/ication a name and set its conte4t root. 0se Liferay for the name and +%ortal as the conte4t root. C/ic. 6ext. C/ic. the 6ext /in. at the bottom right of the page. C/ic. the 0: button at the top of this page. 1ou -i// be brought bac. to the previous screen. C/ic. the De%loy button at the top right of the screen. ?CCJ -i// then dep/oy Liferay.

'. (.

Illustration ! )etting the de%loyment o%tions on 0C;3 C/ic. the 9eturn button at the top of the page. &e4t, navigate to the Liferay ;ome fo/der. Create a fi/e ca//ed %ortal&ext'%ro%& erties in this fo/der. Add a directive for @orta/ Conte4t, then give it a va/ue of +%ortal'
portal.ct< /portal

$f you are using Liferay's bui/t)in data source, add the database settings2
jdbc.default.driver&lass'ame com.mys(l.jdbc.)river jdbc.default.url jdbc*mys(l*//localhost/jettyportal+ use,nicode true-character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.default.username root jdbc.default.password root

$f you are using ?CCJ's data source, add the J&=$ name instead2
jdbc.default.jndi.name jdbc/!iferay"ool

=o the same thing for the :ai/ Session. $f you are using the bui/t)in config) uration, set the fo//o-ing properties for your system2
mail.session.mail.pop2.host localhost mail.session.mail.pop2.password mail.session.mail.pop2.port 334 mail.session.mail.pop2.user mail.session.mail.smtp.auth false mail.session.mail.smtp.host localhost mail.session.mail.smtp.password mail.session.mail.smtp.port 56 mail.session.mail.smtp.user mail.session.mail.store.protocol pop2 mail.session.mail.transport.protocol smtp

$f you are using ?CCJ's mai/ session, add the J&=$ name instead2 $nsta//ing Liferay for an >nterprise C*

$nitia/ Setup
mail.session.jndi.name mail/$ailSession

Save and c/ose the fi/e. #. Shut do-n and restart the server. $n your bro-ser, go to http277/oca/host2((((7porta/. 1ou shou/d see Liferay's defau/t home page.

4P/4=/51 36*4?*6= !oading code-source*/0*/!iferay//ools/8pplication Servers/ oc=jLe<tendedL3432=4/j5ee/home/applications/ !iferay/liferay-portal-6.5.5/R.S-I'0/lib/portal-impl.jarQ/system.properties 4P/4=/51 36*4?*66 !oading code-source*/0*/!iferay//ools/8pplication Servers/ oc=jLe<tendedL3432=4/j5ee/home/applications/ !iferay/liferay-portal-6.5.5/R.S-I'0/lib/portal-impl.jarQ/portal.properties 4P/4=/51 36*4?*66 !oading file*/0*/!iferay//ools/8pplication Servers/oc=jLe<tendedL3432=4/j5ee/home/applications/!iferay /liferay-portal-6.5.5/R.S-I'0/classes/portal-e<t.properties 36*4T*45,P1= I'0N 36*4T*42,356 I'0N lect.$yS%!)ialect U)ialect)etector*?=V )etermining dialect for $yS%! 6 U)ialect)etector*PTV ,sing dialect org.hibernate.dia-

4P/4=/51 36*4T*46 !oading code-source*/0*/!iferay//ools/8pplication Servers/ oc=jLe<tendedL3432=4/j5ee/home/applications/ !iferay/liferay-portal-6.5.5/R.S-I'0/lib/portal-impl.jarQ/captcha.properties 36*4T*4?,26P I'0N U"ortalImpl*5=2V "ortal lib directory /0*/!iferay//ools/8pplication Servers/oc=jLe<tendedL3432=4/j5ee /home/applications/!iferay/liferay-portal-6.5.5/R.S-I'0/lib/ 36*4T*54,623 I'0N UServer)etector*34=V )etected server oc=j 544P-=-51 36*4T*52 com.sun.portal.container.service.Service$anager&onte<t!istenerImpl conte<tInitiali>ed I'0N* "S&L&S"&S443 * Started initiali>ing Service$anager 544P-=-51 36*4T*52 com.sun.portal.container.service.Service$anager addService I'0N* "S&L&S"&S44= * Service added, 'ame* com.sun.portal.container.service.&oordinationService, Implementation* com.sun. portal.container.service.coordination.impl.&oordinationServiceImpl 544P-=-51 36*4T*52 com.sun.portal.container.service.Service$anager addService I'0N* "S&L&S"&S44= * Service added, 'ame* com.sun.portal.container.service.&achingService, Implementation* com.sun.porta l.container.service.caching.impl.&achingServiceImpl 544P-=-51 36*4T*52 com.sun.portal.container.service.Service$anager addService I'0N* "S&L&S"&S44= * Service added, 'ame* com.sun.portal.container.service.&lient&achingService, Implementation* com.sun .portal.container.service.caching.impl.&lient&achingServiceImpl 544P-=-51 36*4T*52 com.sun.portal.container.service.Service$anager addService I'0N* "S&L&S"&S44= * Service added, 'ame* com.sun.portal.container.service.)eploymentServiceL!ocal, Implementation* com. sun.portal.container.service.deployment.impl.)eploymentService!ocalImpl 544P-=-51 36*4T*52 com.sun.portal.container.service.Service$anager addService I'0N* "S&L&S"&S44= * Service added, 'ame* com.sun.portal.container.service.&ontainer.ventService, Implementation* com.su n.portal.container.service.coordination.impl.&ontainer.ventServiceImpl

C+

$nsta//ing Liferay for an >nterprise

$nitia/ Setup
544P-=-51 36*4T*52 com.sun.portal.container.service.Service$anager addService I'0N* "S&L&S"&S44= * Service added, 'ame* com.sun.portal.container.service."olicyService, Implementation* com.liferay.po rtal.portletcontainer."olicyServiceImpl 544P-=-51 36*4T*52 com.sun.portal.container.service.Service$anager addService 544P-=-51 36*4T*5= com.sun.portal.container.service.Service$anager&onte<t!istenerImpl conte<tInitiali>ed I'0N* "S&L&S"&S445 * 0inished initiali>ing Service$anager 544P-=-51 36*4T*5= com.sun.portal.portletcontainer.impl."ortlet&ontainer&onte<t!istenerImpl conte<tInitiali>ed I'0N* "S"!L"&&S"&"&I4442 * Starting "ortlet&ontainer 5.3 4P/4=/51 36*4T*5= Starting !iferay "ortal Standard .dition 6.5.5 A8ugustine / Suild 6545 / 0ebruary 54, 544PB 36*4T*62,444 I'0N 341=64=3 UMot)eploy,til*?=V Initiali>ing hot deploy manager

36*4T*62,26P I'0N U8uto)eploy)ir*341V 8uto deploy scanner started for &*\)ocuments and Settings\Steven\liferay\deploy 4P/4=/51 36*4T*6= Nracle &ontainers for E5.. 34g A34.3.2.=.4B 36*34*65,1T6 I'0N initiali>ed U"lugin"ackage,til*33=1V Feloading repositories

R S.N 9.6.4
Lifera 2o+e is one fo/der above Resin's insta// /ocation. A. !. =o-n/oad and insta// Resin into your preferred directory. 9rom no- on, the directory -here you insta//ed Resin -i// be referred to as -91)I6/H0M1. >dit -91)I6/H0M1+conf+resin'conf. Rep/ace /ines +")+C -ith2
9class-loader: 9tree-loader 9tree-loader path D@Gresin.homeH/libD/: path D@Gserver.rootH/libD/:

9compiling-loader path D@ Gserver.root)irH/common/classesD/: 9library-loader 9/class-loader: path D@Gserver.root)irH/common/libD/:

And add the fo//o-ing2


9database: 9jndi-name:jdbc/!iferay"ool9/jndi-name: 9driver type Dcom.mys(l.jdbc.)riverD: 9url:jdbc*mys(l*//localhost/lportal+use,nicode true-amp7character.ncoding ,/0-19/url: 9user:9/user: 9password:9/password: 9/driver: 9prepared-statement-cache-si>e:19/prepared-statement-cache-si>e: 9ma<-connections:549/ma<-connections: 9ma<-idle-time:24s9/ma<-idle-time:

$nsta//ing Liferay for an >nterprise

C'

$nitia/ Setup
9/database: 9resource 9init: 9mail.store.protocol:imap9/mail.store.protocol: 9mail.transport.protocol:smtp9/mail.transport.protocol: 9mail.imap.host:localhost9/mail.imap.host: 9mail.pop2.host:localhost9/mail.pop2.host: 9mail.smtp.host:localhost9/mail.smtp.host: 9/init: 9/resource: 9system-property java<.<ml.parsers.)ocumentSuilder0actory Dorg.apache.<erces.ja<p.)ocumentSuilder0actoryImplD /: 9system-property java<.<ml.parsers.S8;"arser0actory Dorg.apache.<erces.ja<p.S8;"arser0actoryImplD /: 9system-property java<.<ml.transform./ransformer0actory Dorg.apache.<alan.processor./ransformer0actoryImplD /: 9system-property "arserD /: org.<ml.sa<.driver Dorg.apache.<erces.parsers.S8;jndi-name Dmail/$ailSessionD type Djava<.mail.SessionD:

8.

Go to -91)I6/H0M1 and create ne- directory ca//ed common+lib. =o-n/oad mys7l&connector&*ava&C-versionD&bin '*ar and copy to this directory. ,his is the J=%C connector for :ySFL. $f you are using another database, substitute this -ith the appropriate driver. =o-n/oad the Liferay @orta/ =ependencies and unzip into -91)& I6/H0M1+common+lib. =e/ete contents of -91)I6/H0M1+weba%%s+9004. 0nzip /iferay)porta/)4.4.4.-ar to -91)I6/H0M1+weba%%s+9004. $f you are using Resin 8.A.# or higher, remove -91)I6/H0M1+lib+%ortlet&J '*ar. ,his contains the o/d @ort/et A." c/asses. ,he @ort/et !." c/asses are bac.) -ards compatib/e, so this shou/d not affect anything. &e4t, you -i// need severa/ .Iar fi/es -hich are inc/uded as part of the Liferay source distribution. :any app/ication servers ship -ith these a/ready on the c/ass path, but Resin does not. ,he best -ay to get the appropriate versions of these fi/es is to do-n/oad the Liferay source code and get them from there. ?nce you have do-n/oaded the Liferay source, unzip it to a tempor) ary fo/der. A. Go to -LI(19AA/)0U9C1+lib+develo%ment+ and copy activation'*ar and mail'*ar to -91)I6/H0M1+common+lib' Copy sax%ath'*ar and xalan'*ar to -91)I6/H0M1+lib' Go to -LI(19AA/)0U9C1+lib+%ortal and copy xercesIm%l'*ar and xml&a%is'& *ar to -91)I6/H0M1+lib'

C. *. +. '.

(.

!. #.

,o start the server, open a command prompt, navigate to the WR>S$&M;?:> and type2
java -jar lib/resin.jar start

C(

$nsta//ing Liferay for an >nterprise

$nitia/ Setup A". ?pen your bro-ser to http277/oca/host2("(". 1ou shou/d see the defau/t Liferay home page.

R S.N 9.8.4
Lifera 2o+e is one fo/der up from Resin's insta// /ocation. A. =o-n/oad and insta// Resin 8.!.A into your preferred directory. 9rom noon, the directory -here you insta//ed Resin -i// be referred to as -91)& I6/H0M1. >dit -91)I6/H0M1+conf+resin'conf. Rep/ace /ines /ine #)A8 -ith2
9tree-loader path D@Gresin.homeH/e<t-libD/: 9tree-loader path D@Gresin.rootH/e<t-libD/: 9tree-loader path D@Gresin.homeH/libD/: 9tree-loader path D@Gresin.rootH/libD/: 9compiling-loader path D@Gserver.root)irH/common/classesD/: 9library-loader path D@Gserver.root)irH/common/libD/:

!.

8.

Search ZIvm)argV tag in resin'conf and rep/ace -hat is there -ith the fo//o-) ing2
9jvm-arg:-;m<56?m9/jvm-arg: 9jvm-arg:-;ss3m9/jvm-arg: 9jvm-arg:-)com.sun.management.jm<remote9/jvm-arg: 9jvm-arg:-;m<345=m9/jvm-arg: 9jvm-arg:-;;*$a<"ermSi>e 56?m9/jvm-arg: 9jvm-arg:-)file.encoding ,/0-19/jvm-arg: 9jvm-arg:-)user.time>one O$/9/jvm-arg:

C.

Go to -91)I6/H0M1 and create a ne- directory ca//ed common+lib. =o-n/oad mys7lconnector&*ava&C-versionD&bin '*ar and copy to this directory. ,his is the J=%C connector for :ySFL. $f you are using another database, substitute this -ith the appropriate driver. =o-n/oad the Liferay @orta/ =ependencies and unzip into -91)& I6/H0M1+common+lib. =e/ete the contents of -91)I6/H0M1+weba%%s+9004. 0nzip /iferay)porta/)4.4.4.-ar to -91)I6/H0M1+weba%%s+9004. &e4t, you -i// need severa/ .Iar fi/es -hich are inc/uded as part of the Liferay source distribution. :any app/ication servers ship -ith these a/ready on the c/ass path, but Resin does not. ,he best -ay to get the appropriate versions of these fi/es is to do-n/oad the Liferay source code and get them from there. ?nce you have do-n/oaded the Liferay source, unzip it to a tempor) ary fo/der. Go to -LI(19AA/)0U9C1+lib+develo%ment+ Copy sax%ath'*ar to -91)&

*. +. '. (.

$nsta//ing Liferay for an >nterprise

C#

$nitia/ Setup I6/H0M1+common+lib. #. ,o start the server, open a command prompt, navigate to the WR>S$&M;?:> and type2

A". Iava )Iar /ib7resin.Iar start ?pen your bro-ser to http277/oca/host2("(". 1ou shou/d see the defau/t Liferay home page.

T1/!AT =.=.4
Lifera 2o+e is one fo/der above ,omcat's insta// /ocation. A. =o-n/oad and insta// ,omcat *.*.D into your preferred directory. 9rom noon, the directory -here you insta//ed ,omcat -i// be referred to as W,?:) CA,M;?:>. 3ote) 9or J=E * users2 move -40MCA4/H0M1+weba%%s+9004+@1"& I6(+lib+xercesIm%l'*ar to -40MCA4/H0M1+common+endorsed. J=E A.C is no /onger supported in Liferay *.4 and above. !. Create and edit -40MCA4/H0M1+conf+Catalina+localhost+9004'xml to set up the porta/ -eb app/ication.
9&onte<t path DD: 9/&onte<t:

8. C.

=o-n/oad /iferay)porta/)4.4.4.-ar. =o-n/oad Liferay's @orta/ =ependencies. Create a -40M& CA4/H0M1+common+lib+ext directory and unzip the dependencies G$@ in there. $f the fi/es do not e4tract to this directory, ma.e sure they are in the correct directory by moving them there. >dit W,?:CA,M;?:>7conf7cata/ina.properties2
common.loader @Gcatalina.homeH/common/classes,\ ...\ @Gcatalina.homeH/common/lib/e<t/C.jar

*.

+.

:a.e sure your database server is insta//ed and is -or.ing. $f it's insta//ed in a different machine, ma.e sure that it's accessib/e from the one -here Liferay is being insta//ed. Configure data sources for your database. :a.e sure the J=%C driver for your database is accessib/e by ,omcat. ?btain the J=%C driver for your ver) sion of the database server. $n the case of :ySFL use mys7l&connector&*ava& C-versionD&bin'*ar. &e4t, copy the JAR fi/e to -40MCA4/H0M1+common+lib+ext. >dit -40MCA4/H0M1+conf+Catalina+localhost+9004'xml.
9&onte<t...: 9Fesource name Djdbc/!iferay"oolD

'.

(.

*"

$nsta//ing Liferay for an >nterprise

$nitia/ Setup
auth D&ontainerD type Djava<.s(l.)ataSourceD driver&lass'ame Dcom.mys(l.jdbc.)riverD url Djdbc*mys(l*//localhost/lportal+ use,nicode true-amp7character.ncoding ,/0-1D username DD password DD ma<8ctive D344D ma<Idle D24D ma<Rait D34444D /: 9/&onte<t:

#.

%e sure to enter the user name and pass-ord to your database in the appro) priate fie/ds above.

A". Create a mai/ session bound to mail+Mail)ession. >dit -40M& CA4/H0M1+conf+Catalina+localhost+9004'xml and configure a mai/ session.
9&onte<t...: 9Fesource name Dmail/$ailSessionD auth D&ontainerD type Djava<.mail.SessionD mail.transport.protocol DsmtpD mail.smtp.host DlocalhostD mail.store.protocol DimapD mail.imap.host DlocalhostD /: 9/&onte<t:

AA. Configure JAAS. >dit -40MCA4/H0M1+conf+Catalina+localhost+9004'xml and configure a security rea/m.


9&onte<t...: 9Fealm class'ame Dorg.apache.catalina.realm.E88SFealmD app'ame D"ortalFealmD user&lass'ames Dcom.liferay.portal.security.jaas."ortal"rincipalD role&lass'ames Dcom.liferay.portal.security.jaas."ortalFoleD debug DPPD use&onte<t&lass!oader DfalseD /: 9/&onte<t:

AC. Create -40MCA4/H0M1+conf+*aas'config.


"ortalFealm G com.liferay.portal.kernel.security.jaas."ortal!ogin$odule H7 re(uired7

A*. >dit -40MCA4/H0M1+bin+catalina'bat 5on <indo-s6 or -40M& CA4/H0M1+bin+catalina'sh 5on Linu4 7 :ac 7 0ni46 so that ,omcat can refer)

$nsta//ing Liferay for an >nterprise

*A

$nitia/ Setup ence the /ogin modu/e.


rem ----- .<ecute... set E8K8LN"/S -;ms351m -;m<635m -)file.encoding ,/01 -)user.time>one O$/ -)java.security.auth.login.config J&8/8!I'8LMN$. J/conf/jaas.config

A+. =e/ete contents -40MCA4/H0M1+weba%%s+9004 directory. ,his undep/oys the defau/t ,omcat home page. A'. 0npac. /iferay)porta/)4.4.4.-ar to -40MCA4/H0M1+weba%%s+9004. A(. 9or supporting 0,9)( 0R$ >ncoding, edit -40MCA4/H0M1+conf+server'xml2
9Q-- )efine a non-SS! M//"/3.3 &onnector on port 1414 --: 9&onnector port D1414D ma<MttpMeaderSi>e D13P5D ma</hreads D364D minSpare/hreads D56D

ma<Spare/hreads DT6D redirect"ort D1==2D load/imeout DtrueD /:

enable!ookups DfalseD accept&ount D344D connection/imeout D54444D ,FI.ncoding D,/0-1D disable,p-

A#. Run ,omcat, point bro-ser to http277/oca/host2("(". 1ou shou/d see the de) fau/t Liferay home page.

W (L1G.! A < 67
Lifera 2o+e is one fo/der above the home fo/der of the domain in -hich Liferay is insta//ed. ,hese instructions assume that you have a/ready configured a domain and serv) er, and that you have access to the <ebLogic conso/e.

0P
A.

N0 N!5 JARS

&avigate to the fo/der -hich corresponds to the domain to -hich you -i// be insta//ing Liferay. $nside this fo/der is a lib fo/der. 0nzip the Liferay depend) encies archive to this fo/der. Copy the J=%C driver for your database to this fo/der as -e//. 1ou -i// a/so need the xercesIm%l'*ar or you -i// get SAD parsing errors after you dep/oy Liferay. 1ou may do-n/oad this from http2774erces.apache.org. Copy the xercesIm%l'*ar fi/e into this directory. Create a fo/der ca//ed endorsed in -@1"L0.IC&H0M1+*roc5itKJ/ ?J/J;+*re+lib, then copy rhino'*ar, serialiLer'*ar$ and xalan'*ar to the fo/der that you Iust cre) ated.

!. 8.

C.

*!

$nsta//ing Liferay for an >nterprise

$nitia/ Setup

0ATA(AS !1N*.G-RAT.1N
$f you -ant <ebLogic to manage your data source, use the fo//o-ing procedure. $f you -ant to use Liferay's bui/t)in data source, you can s.ip this section. A. %ro-se to your <ebLogic Conso/e. C/ic. the Loc5 M 1dit button above the =omain Structure tree on the /eft side of the page. 9rom the =omain Structure tree on the /eft, se/ect =ata Sources. ,hen c/ic. the 6ew button on the right side of the screen. Give the =ata Source a name, such as LiferayData)ource. =efine the J&=$ name as *dbc+LiferayPool. Se/ect your =atabase ,ype and the =river c/ass, and then c/ic. the 6ext button. Accept the defau/ts on the ne4t screen by c/ic.ing 6ext.

!.

8. C. *. +. '.

Illustration #! @ebLogic! Data )ources

?n the ne4t screen, put in your Database 6ame$ Host 6ame$ Database User 6ame$ and Password' $f you have been fo//o-ing the defau/ts -e have been using so far, you -ou/d use l%ortal$ localhost$ root$ and no pass-ord as the va/) ues. C/ic. &e4t. ,he ne4t screen a//o-s you to test your database configuration. C/ic. the 4est Connection button. $f the test succeeds, you have configured your data) base correct/y. Chec. off the server you -ant to dep/oy this =ata Source to 5AdminServer is the defau/t6. C/ic. 9inish. C/ic. the Activate Changes button on the /eft, above the =omain Structure tree.

(.

#.

/A.L !1N*.G-RAT.1N
$f you -ant <ebLogic to manage your mai/ sessions, use the fo//o-ing procedure. $f you -ant to use Liferay's bui/t)in mai/ sessions, you can s.ip this section. A. !. 8. C. *. +. $n the =omain Structure tree, se/ect Mail )essions' ,hen c/ic. the Loc5 M 1dit button again to enab/e modifying these settings. C/ic. the 6ew button -hich is no- enab/ed on the right side of the screen. Give the :ai/ Session a name, such as LiferayMail. Se/ect your ne- Liferay:ai/ session from the /ist by c/ic.ing on it. ?n the screen that appears, define the J&=$ name as mail+Mail)ession. C/ic. the )ave button. C/ic. the 4argets tab. Chec. off the server you -ant to dep/oy this =ata Source to 5AdminServer is the defau/t6.

$nsta//ing Liferay for an >nterprise

*8

$nitia/ Setup '. C/ic. the Activate Changes button on the /eft side of the screen, above the =o) main Structure tree.

0 PL15 L.* RA5


A. C/ic. the De%loyments option in the =omain Structure tree on the /eft side of the screen. !. C/ic. the Loc5 M 1dit button above the =omain Structure tree. C/ic. the Install button on the right side of the screen. C/ic. the U%load your fileNsO /in.. %ro-se to -here you have stored the Liferay .-ar fi/e, se) /ect it, and then c/ic. 6ext. Se/ect the Liferay .-ar fi/e from the /ist and c/ic. 6ext. Leave Install this de%loyment as an a%%lication se/ected and c/ic. &e4t.

8. C. *.

+. '. Illustration 2! @ebLogic! Mail )essions

(. Give the app/ication a name 5the defau/t name is fine6. Leave the other defau/ts se/ected and then c/ic. (inish. #. <ebLogic -i// no- dep/oy Liferay. <hen it is finished, a summary screen is disp/ayed. C/ic. the Activate Changes /in. on the /eft above the =omain Struc) ture tree.

A". Create a %ortal&ext'%ro%erties fi/e in the Liferay ;ome fo/der, -hich is one fo/der up from your domain's home fo/der. $f you are using Liferay's bui/t)in data source, add the database settings2
jdbc.default.driver&lass'ame com.mys(l.jdbc.)river jdbc.default.url jdbc*mys(l*//localhost/lportal+ use,nicode true-character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.default.username root jdbc.default.password root

$f you are using <ebLogic's data source, add the J&=$ name instead2

*C

$nsta//ing Liferay for an >nterprise

$nitia/ Setup

jdbc.default.jndi.name jdbc/!iferay"ool

Illustration ;! De%loying Liferay on @ebLogic K'#

=o the same thing for the :ai/ Session. $f you are using the bui/t)in config) uration, set the fo//o-ing properties for your system2
mail.session.mail.pop2.host localhost mail.session.mail.pop2.password mail.session.mail.pop2.port 334 mail.session.mail.pop2.user mail.session.mail.smtp.auth false mail.session.mail.smtp.host localhost mail.session.mail.smtp.password mail.session.mail.smtp.port 56 mail.session.mail.smtp.user mail.session.mail.store.protocol pop2 mail.session.mail.transport.protocol smtp

$f you are using <ebLogic's mai/ session, add the J&=$ name instead2
mail.session.jndi.name mail/$ailSession

AA. $n the =ep/oyments screen, se/ect the Liferay app/ication and c/ic. the )tart button. Se/ect )ervicing All 9e7uests in the pop up. A!. C/ic. Aes to continue on the ne4t screen. Liferay -i// start. 1ou -i// be ab/e to get to it by bro-sing to http277Zserver nameV2'""A. $f your bro-ser is running on the same machine upon -hich you have insta//ed Liferay, the 0RL is http277/oca/host2'""A.

1RA!L W (L1G.! 67.9


$f you sti// have the main<ebApp modu/e insta//ed, you -i// need to remove it first. Copy the dependency .Iars and the J=%C driver to the domain7/ib directory. Start <ebLogic.

$nsta//ing Liferay for an >nterprise

**

$nitia/ Setup

0ATA(AS !1N*.G-RAT.1N
$f you -ant <ebLogic to manage your data source, use the fo//o-ing procedure. $f you -ant to use Liferay's bui/t)in data source, you can s.ip this section.

A. !. 8.

Illustration ?! Creating a data source in @ebLogic J'2 Se/ect 3D"C Data )ources' C/ic. 6ew. Give your data source a name, such as Liferay Data )ource. ,he J&=$ name shou/d be *dbc+LiferayPool. Choose the type of database. 9rom the screen shot, you can see that -e have chosen :ySFL. ,he database driver c/ass shou/d be chosen for you automat) ica//y. C/ic. 6ext t-ice. 1ou shou/d be on the Connection Pro%erties screen. >nter the database name, the host name, the port, the database user name, and the pass-ord. <ebLogic -i// use this information to construct the appropriate $nsta//ing Liferay for an >nterprise

C.

*+

$nitia/ Setup J=%C 0RL to connect to your database. C/ic. 6ext. *. <ebLogic -i// no- confirm -ith you the information that it gathered. 9or :ySFL, some additiona/ parameters need to be added to the 0RL. :odify the J=%C 0RL so that it has the proper parameters2
jdbc*mys(l*//localhost/lportal+ use,nicode true-character.ncoding ,/0-1- \ use0ast)ate"arsing false

+. '. (.

C/ic. 4est Configuration to ma.e sure <ebLogic can connect to your database successfu//y. $f it does, c/ic. (inish. 1ou -i// be bac. to the /ist of data sources. &otice that your ne- data source has no va/ue in the 4arget co/umn. C/ic. on your data source to edit it. C/ic. the 4argets tab and chec. off the server instance5s6 to -hich you -ish to dep/oy your data source. ,hen c/ic. )ave.

/A.L !1N*.G-RAT.1N
A. !. 8. Se/ect Mail )essions and create a ne- mai/ session -hich points to your mai/ server. Give it the name Liferay :ai/ and give it the J&=$ name of mail+Mail)ession and c/ic. 6ext. Choose your server and then c/ic. (inish.

0 PL15 L.* RA5


A. Create a %ortal&ext'%ro%erties fi/e in the Liferay ;ome fo/der, -hich is one fo/der up from your domain's home fo/der. $f you are using Liferay's bui/t)in data source, add the database settings2
jdbc.default.driver&lass'ame com.mys(l.jdbc.)river jdbc.default.url jdbc*mys(l*//localhost/lportal+ use,nicode true-character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.default.username root jdbc.default.password root

$f you are using <ebLogic's data source, add the J&=$ name instead2
jdbc.default.jndi.name jdbc/!iferay"ool

=o the same thing for the :ai/ Session. $f you are using the bui/t)in config) uration, set the fo//o-ing properties for your system2
mail.session.mail.pop2.host localhost mail.session.mail.pop2.password mail.session.mail.pop2.port 334 mail.session.mail.pop2.user mail.session.mail.smtp.auth false mail.session.mail.smtp.host localhost mail.session.mail.smtp.password

$nsta//ing Liferay for an >nterprise

*'

$nitia/ Setup
mail.session.mail.smtp.port 56 mail.session.mail.smtp.user mail.session.mail.store.protocol pop2 mail.session.mail.transport.protocol smtp

$f you are using <ebLogic's mai/ session, add the J&=$ name instead2
mail.session.jndi.name mail/$ailSession

Save and c/ose the fi/e. !. Se/ect De%loyments and c/ic. the Install button. Se/ect the Liferay .-ar fi/e from the fi/e system or c/ic. the U%load Aour (ileNsO /in. to up/oad it, and then c/ic. 6ext. Leave Install this de%loyment as an a%%lication se/ected and c/ic. 6ext. $f the defau/t name is appropriate for your insta//ation, .eep it. ?ther-ise, give it a name of your choosing and c/ic. 6ext. C/ic. (inish. After the dep/oyment finishes, c/ic. )ave.

8. C. *.

Ti#$ +fter Liferay completes installing& you may see an error initiali,ing the 'eb -roxy portlet. .ecause the /(L parser configured by default within 'ebLogic cannot compile a style sheet in this portlet& Liferay disables it by default. To re"enable this portlet& extract xalan.0ar and seriali,er.0ar from the Liferay .war archive and copy them to your JD 1s endorsed folder for libraries. %f you are using J2ockit& you may find this folder in 3.ea 4ome560rockit7!8979560re6lib6ext.

W (SP3 R :.6
Ti#$ Throughout this installation and configuration process& 'eb(phere will prompt you to )lick (ave to apply changes to *aster )onfiguration. Do so intermittently to save your changes.

Lifera 2o+e is in a fo/der ca//ed liferay in the home fo/der of the user $= that is run) ning <ebSphere.

.NSTALLAT.1N
A. !. =o-n/oad the Liferay @orta/ <AR fi/e. =o-n/oad and e4tract these Liferay Iars to webs%here+a%%server+lib+ext. =ependency /ibraries 5Liferay @orta/ =ependencies6 1our database J=%C driver .Iar Current/y you a/so need to copy %ortlet'*ar from the Liferay =ependen)

*(

$nsta//ing Liferay for an >nterprise

$nitia/ Setup cies archive into @eb)%here+A%%)erver+*ava+*re+lib+ext, as <ebSphere a/ready contains o/der versions of the port/et .Iar -hich must be over) ridden at the highest /eve/ of the c/ass path. ,his issue may be fi4ed in future re/easesU chec. the Liferay <i.i for updates to this issue.

0ATA(AS !1N*.G-RAT.1N
A. !. 8. Start <ebSphere. ?pen Administrative Conso/e and /og in. C/ic. 9esources, c/ic. 3D"C Providers.

Illustration B! @eb)%here B' 3D"C Providers C. *. +. C/ic. 6ew. 9or name, enter the name of the J=%C provider 5e.g. My)8L 3D"C Provider6. 9or $mp/ementation c/ass name, enter the imp/ementation c/ass for your data) base driver's connection poo/ data source 9or :ySFL, enter2
com.mys(l.jdbc.jdbc5.optional.$ys(l&onnection"ool)ataSource

'.

C/ic. 6ext.

$nsta//ing Liferay for an >nterprise

*#

$nitia/ Setup

Illustration G! Clear out anything in the class %ath'

(. #.

Illustration F! @eb)%here B' 6ew 3D"C Provider C/ear any te4t in c/ass path. 1ou a/ready copied the necessary .Iars to a /ocation on the server's c/ass path. C/ic. 6ext.

Illustration K! 3D"C Provider summary screen A". AA. A!. A8. AC. A*. C/ic. (inish' C/ic. Data )ources under Additional Pro%erties. C/ic. 6ew. >nter a name2 liferaydatabasesource. >nter J&=$2 *dbc+LiferayPool. >verything e/se shou/d stay at the defau/t va/ues.

+"

$nsta//ing Liferay for an >nterprise

$nitia/ Setup

Illustration #J! Liferay data source on @eb)%here B' A+. A'. A(. A#. C/ic. 6ext' 0nder Additional Pro%erties, c/ic. Custom Pro%erties. C/ic. 6ew. Create three custom properties by entering &ame, Ba/ue and c/ic.ing ?E for each ro- in the fo//o-ing tab/e. Name !. user :. serverName ;. databaseName root localhost lportal >alue

$nsta//ing Liferay for an >nterprise

+A

$nitia/ Setup

!".

Illustration # ! @eb)%here B' Custom Pro%erties 1ntry <hen done correct/y, custom properties shou/d /oo. /i.e this2

+!

$nsta//ing Liferay for an >nterprise

$nitia/ Setup

!A.

Illustration ##! Liferay Custom Pro%erties C/ic. Data )ources )V 4est Connection to test.

/A.L !1N*.G-RAT.1N
A. !. 8. C. C/ic. 9esources )V Mail Providers. C/ic. "uilt&in Mail Provider. C/ic. Mail )essions. C/ic. 6ew. A. !. 3a+e) liferaymail 43*I 3a+e2 mail+Mail)ession

$nsta//ing Liferay for an >nterprise

+8

$nitia/ Setup

*. +. '. (. #.

Illustration #2! Creating a Mail )ession on @eb)%here B' C/ic. 0:. C/ic. )ecurity. C/ic. )ecure administration$ a%%lications$ and infrastructure. Se/ect 1nable a%%lication security. =ese/ect Use 3ava # security to restrict a%%lication access to local resources'

+C

$nsta//ing Liferay for an >nterprise

$nitia/ Setup

.NSTALL L.*
A. !.

RA5

C/ic. A%%lications )V Install new a%%lications' %ro-se for /iferay)porta/)4.4.4.-ar.

8. C.

Illustration #;! Installing the Liferay 'war file on @eb)%here B' >nter conte4t root +. C/ic. 6ext. 9or Steps A to 8, c/ic. 6ext to app/y defau/ts.

$nsta//ing Liferay for an >nterprise

+*

$nitia/ Setup

*. +.

Illustration #?! )elect the installation o%tions Choose the :ai/ Session and =ata Source, and then c/ic. 6ext Specify the virtua/ host upon -hich you -ant Liferay to run.

++

$nsta//ing Liferay for an >nterprise

$nitia/ Setup

Illustration #B! )elect the virtual host '. At the Summary Screen, c/ic. (inish'

Illustration #F! @eb)%here B' installation %rocess (. #. <ait for the insta//ation process to comp/ete. Save this configuration to master configuration by c/ic.ing on )ystem admin& istration and )ave Changes to Master 9e%ository.

A". Create a %ortal&ext'%ro%erties fi/e in the Liferay ;ome fo/der. 9or <ebSphere, this is a fo/der ca//ed liferay in the home fo/der of the user that is running <ebSphere. $f you are using Liferay's bui/t)in data source, add the database $nsta//ing Liferay for an >nterprise +'

$nitia/ Setup settings2


jdbc.default.driver&lass'ame com.mys(l.jdbc.)river jdbc.default.url jdbc*mys(l*//localhost/lportal+ use,nicode true-character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.default.username root jdbc.default.password root

$f you are using <ebSphere's data source per the instructions above, add the J&=$ name instead2
jdbc.default.jndi.name jdbc/!iferay"ool

=o the same thing for the :ai/ Session. $f you are using the bui/t)in config) uration, set the fo//o-ing properties for your system2
mail.session.mail.pop2.host localhost mail.session.mail.pop2.password mail.session.mail.pop2.port 334 mail.session.mail.pop2.user mail.session.mail.smtp.auth false mail.session.mail.smtp.host localhost mail.session.mail.smtp.password mail.session.mail.smtp.port 56 mail.session.mail.smtp.user mail.session.mail.store.protocol pop2 mail.session.mail.transport.protocol smtp

$f you are using <ebSphere's mai/ session, add the J&=$ name instead2
mail.session.jndi.name mail/$ailSession

Save and c/ose the fi/e.

START L.* RA5 P1RTAL


A. !. App/ications. C/ic. 1nter%rise A%%lications.

+(

$nsta//ing Liferay for an >nterprise

$nitia/ Setup

Illustration #G! )tarting Liferay on @eb)%here B' 8. C. *. 0ninsta// DefaultA%%lication, Plants"y@eb)%here and )am%les.allery. Se/ect liferay&%ortal'war, c/ic. )tart' ?pen up bro-ser and point to http277/oca/host2#"(". ,he defau/t Liferay home page -i// be disp/ayed.

W (SP3 R B.7
Lifera 2o+e is in a fo/der ca//ed liferay in the home fo/der of the user $= that is run) ning <ebSphere. A. !. =o-n/oad the Liferay @orta/ <AR fi/e. =o-n/oad and e4tract these Liferay Iars to webs%here+a%%server+lib+ext. A. !. =ependency /ibraries 5Liferay @orta/ =ependencies6 J=%C =river for your database

0ATA(AS !1N*.G-RAT.1N
$f you -ant <ebSphere to manage the database connections, fo//o- the instruc) tions be/o-. A. Start <ebSphere.

$nsta//ing Liferay for an >nterprise

+#

$nitia/ Setup

!. 8. C.

Illustration #K! @eb)%here F'J 3D"C Providers ?pen Administrative Conso/e and /og in. C/ic. 9esources 3D"C Providers. C/ic. 6ew.

'"

$nsta//ing Liferay for an >nterprise

$nitia/ Setup

*. +. '. (. #.

Illustration 2J! @eb)%here F'J! )elect 3D"C Provider 9or name, enter the name of J=%C provider 5e.g. My)8L 3D"C Provider6. 9or $mp/ementation c/ass name, enter2
com.mys(l.jdbc.jdbc5.optional.$ys(l&onnection"ool)ataSource

C/ic. 6ext. C/ear any te4t in c/ass path. 1ou a/ready copied the necessary .Iars to a /oca) tion on the server's c/ass path. C/ic. 6ext.

A". C/ic. (inish' AA. C/ic. Data )ources under Additional Pro%erties.

Illustration 2 ! @eb)%here F'J! Database Pro%erties $nsta//ing Liferay for an >nterprise 'A

$nitia/ Setup A!. C/ic. 6ew. A8. >nter a name2 liferaydatabasesource. AC. >nter J&=$2 *dbc+LiferayPool. A*. >verything e/se shou/d stay at the defau/t va/ues. Save the data source. 1". <hen finished, go bac. into the data source and c/ic. Custom Pro%erties, and then c/ic. the )how (ilter (unction button. ,his is the second from /ast of the sma// icons under the 6ew and Delete buttons. A'. ,ype user into the search terms and c/ic. .o.

Illustration 2#! Modifying data source %ro%erties in @eb)%here F A(. Se/ect the user property and give it the va/ue of the user name to your data) base. C/ic. ?E and save to master configuration. A#. =o another fi/ter search for the ur/ property. Give it a va/ue that points to your database. 9or e4amp/e, the :ySFL 0RL -ou/d be2 *dbc!mys7l!++localhost+ l%ortalPuseUnicodeQtrueMcharacter1ncodingQU4(&GMuse(astDateParsingQfalse. C/ic. ?E and save to master configuration. !". =o another fi/ter search for the pass-ord property. >nter the pass-ord for the user $= you added ear/ier as the va/ue for this property. C/ic. ?E and save to master configuration. !A. Go bac. to the data source page by c/ic.ing it in the breadcrumb trai/. C/ic. the ,est Connection button. $t shou/d connect successfu//y.

/A.L !1N*.G-RAT.1N
A. !. '! C/ic. 9esources &R Mail &R Mail Providers. C/ic. the %ui/t)$n :ai/ @rovider for your node and server. $nsta//ing Liferay for an >nterprise

$nitia/ Setup 8. C. *. C/ic. Mail )essions, and then c/ic. the 6ew button. Give it a name of liferaymail and a J&=$ name of mail+Mail)ession. C/ic. 0: and save to master configuration. C/ic. )ecurity .lobal )ecurity and dese/ect Use 3ava # security to restrict a%& %lication access to local resources if it is se/ected. C/ic. A%%ly.

.NSTALL L.*
A. !. 8. C. *. +.

RA5

C/ic. A%%lications &R 6ew A%%lication &R 6ew 1nter%rise A%%lication. %ro-se to the Liferay .-ar fi/e and c/ic. 6ext. Leave (ast Path se/ected and c/ic. 6ext, and then c/ic. 6ext again. :a.e sure your server is se/ected and c/ic. 6ext. Eeep the conte4t root set to 7 and c/ic. 6ext. C/ic. (inish. <hen Liferay has insta//ed, c/ic. )ave to Master Configuration.

START L.*
A.

RA5

Create a %ortal&ext'%ro%erties fi/e in the Liferay ;ome fo/der. 9or <ebSphere, this is a fo/der ca//ed liferay in the home fo/der of the user that is running <ebSphere. $f you are using Liferay's bui/t)in data source, add the database settings2
jdbc.default.driver&lass'ame com.mys(l.jdbc.)river jdbc.default.url jdbc*mys(l*//localhost/lportal+ use,nicode true-character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.default.username root jdbc.default.password root

!.

$f you are using <ebSphere's data source per the instructions above, add the J&=$ name instead2
jdbc.default.jndi.name jdbc/!iferay"ool

=o the same thing for the :ai/ Session. $f you are using the bui/t)in config) uration, set the fo//o-ing properties for your system2
mail.session.mail.pop2.host localhost mail.session.mail.pop2.password mail.session.mail.pop2.port 334 mail.session.mail.pop2.user mail.session.mail.smtp.auth false mail.session.mail.smtp.host localhost mail.session.mail.smtp.password mail.session.mail.smtp.port 56 mail.session.mail.smtp.user mail.session.mail.store.protocol pop2 mail.session.mail.transport.protocol smtp

$f you are using <ebSphere's mai/ session, add the J&=$ name instead2 $nsta//ing Liferay for an >nterprise '8

$nitia/ Setup
mail.session.jndi.name mail/$ailSession

8. C. *. +.

Save and c/ose the fi/e. C/ic. A%%lication 4y%es &R @eb)%here 1nter%rise A%%lication. 0ninsta// the defau/t app/ication. Se/ect the Liferay app/ication and c/ic. )tart.

/a'in) Li%era& !oe+ist with 1ther Java

A##lications

Liferay @orta/ by defau/t is configured to sit at the root 5i.e., +6 of your app/ication server. =edicating your app/ication server to running on/y Liferay @orta/ is a good practice, a//o-ing for separation bet-een your porta/ environment and your -eb ap) p/ication environment. ,his is genera//y a best practice for porta/s, -hich by defini) tion are app/ication deve/opment p/atforms in and of themse/ves. 9or that reason, your instance of Liferay is /i.e/y to be hosting many app/ications, and even integrat) ing severa/ of them together on a sing/e page. 9or this reason, you are going to -ant to ma.e sure your porta/ environment has a// the resources it needs to do this, and configuring it so that it is the so/e consumer of any other .-ar fi/es that get dep/oyed to the app/ication server he/ps to ma.e sure that your system performs optima//y. $f, ho-ever, you -ant Liferay to share space on an app/ication server -ith other app/ications, there is no reason -hy you cannot do that. $n this instance, you may not -ant to ma.e Liferay the defau/t app/ication in the root conte4t of the server. ,here are t-o steps to modifying this behavior2 A. !. =ep/oy Liferay in a conte4t other than root 5for e4amp/e +%ortal6. :odify the %ortal&ext'%ro%erties fi/e to te// Liferay the conte4t to -hich it has been dep/oyed.

,o change the fi/e, open it in a te4t editor. @/ace the %ortal'ctx property at the top of the fi/e2
portal.ct< /

,his defau/t setting defines Liferay @orta/ as the app/ication that sits at the root conte4t. $f you change it to something e/se, say +%ortal, for e4amp/e, you can then de) p/oy Liferay in that conte4t and it -i// /ive there instead of at the root conte4t. A fu// discussion of the %ortal&ext'%ro%erties fi/e appears in Chapter C. 3ote for 5ebLogic 6$er$) <ebLogic a/so reHuires that you modify the weblo& gic'xml fi/e -hich is inc/uded -ith Liferay. $n this fi/e are tags for the conte4t root2
9conte<t-root:/9/conte<t-root:

Change this so that it matches the path you set in your %ortal&ext'%ro%erties fi/e. 1ou -i// have to modify the weblogic'xml fi/e inside the Liferay .-ar itse/f. >4tract the fi/e from the .-ar fi/e, modify it, and then put it bac. in the .-ar fi/e. ,hen dep/oy the modified Liferay .-ar fi/e to the server in the proper conte4t.

'C

$nsta//ing Liferay for an >nterprise

$nitia/ Setup

Summar&
,his chapter is a guide to everything about insta//ing Liferay. <hether you choose a Liferay bund/e or an e4isting app/ication server, Liferay @orta/ integrates seam/ess/y -ith your enterprise Java environment. $t is supported on more app/ica) tion servers than any other porta/ p/atform, a//o-ing you to preserve your invest) ment in your app/ication server of choice, or giving you the freedom to move to a dif) ferent app/ication server p/atform. ,he choice is yours2 Liferay @orta/ -on't get in your -ay, and you can fee/ safe .no-ing that you have the freedom to use the soft) -are that is best for your organization.

Summary

'*

3. CONFIGURATION

?nce Liferay is successfu//y insta//ed, you can begin configuring it to fit it to your environment and your particu/ar porta/ proIect. 1ou can perform many of these con) figuration tas.s through Liferay's port/et)driven user interface. 1ou -i// -ant to customize your porta/ by configuring various settings for it, such as emai/ notifications, integration -ith services such as L=A@, creating users, user groups, organizations, and ro/es, and readying your porta/ to have its content and app/ications /oaded by your deve/opers. ,his chapter covers these activities2

LiferaySs User Interface! ;o- to navigate around Liferay and ma.e use of the Contro/ @ane/. Liferay Administration! ;o- to administer a Liferay porta/. .lobal Portal )ettings! @ass-ord po/icies, Settings, :onitoring, and more.

Li%era&'s -ser .nter%ace


Liferay is a %ortal server. ,his means that it is designed to be a sing/e environment -here a// of the app/ications a user needs can run, and these are integrated together in a consistent and systematic -ay. $f an app/ication /ives outside of the porta/, the porta/ shou/d be ab/e to consume some resource of the app/ication 5such as an RSS feed or a subset of functiona/ity in a KdashboardL app/ication6 so that the end user can see everything he or she interacts -ith at a g/ance. ,o achieve this, a// of the app/ication functiona/ity -ithin Liferay @orta/ is in fragments of the page ca//ed %ortlets. @ort/ets are -eb app/ications that run in a por) tion of a -eb page. ,he heart of any porta/)based -eb site is its port/ets, because port) /ets are -here a// of the functiona/ity is imp/emented. Liferay's core is a port/et con) tainer, and the container's Iob is to aggregate the set of port/ets that are to appear on any particu/ar page and disp/ay them proper/y to the user. $n this -ay, one or many app/ications can reside on a page, and the user can 5at the administrator's discretion6

Configuration arrange them in the -ay that -or.s best for the user. @ort/et app/ications, /i.e serv/et app/ications, have become a Java standard -hich various porta/ server vendors have imp/emented. ,he Java standard defines the port) /et specification. A JSR)A+( or JSR)!(+ standard port/et shou/d be dep/oyab/e on any port/et container -hich supports those standards. @ort/ets are p/aced on the page in a certain order by the end user and are served up dynamica//y by the porta/ server. @orta/ app/ications come genera//y in t-o f/avors2 A6 mu/tip/e port/ets can be -ritten to provide sma// amounts of functiona/ity and then are aggregated by the porta/ server into a /arger app/ication, or !6 -ho/e app/ications can be -ritten to reside in on/y one or a fe- port/et -indo-s. ,he choice is up to those designing the app/ication. =eve/opers on/y have to -orry about -hat happens inside of the port/et itse/fU the porta/ server hand/es bui/ding out the page as it is presented to the user. @ort/ets are not difficu/t to bui/d, and Java standard port/ets can be -ritten by any Java deve/oper -ith e4perience in -riting -eb app/ications. Liferay provides a @/ugins Soft-are =eve/opment Eit that ma.es creating port/et proIects easy. 9or fur) ther information about the @/ugins S=E, p/ease see the Liferay Develo%erSs .uide. Additiona//y, Liferay supports port/ets -ritten in other programming /anguages, such as @;@, Ruby, Groovy, or @ython. Samp/e port/ets -ritten in these /anguages are avai/ab/e to do-n/oad from our Sourceforge site 5http277sourceforge.net7proIects7 /porta/6 or can be chec.ed out from our Subversion repository 5https277/porta/.svn.) sourceforge.net7svnroot7/porta/6.

Navi)atin) Li%era&
<hen you see Liferay's defau/t interface for the first time, you -i// see -hat -e ca// the =oc. in the upper right hand corner of the screen. ,he =oc. is the .ey to navigating -ithin the supp/ied Liferay themes2 it provides /in.s to a// the g/oba/ functions a user needs, such as /ogging in and out and s-itching bet-een various community and organization pages. %y defau/t, it contains Illustration 22! 4he default Liferay Doc5' on/y t-o /in.s2 Home and )ign In. ,o shothese /in.s, a// you need to do is ro// your mouse cursor over the =oc., and it -i// e4) pand. ,o sign into Liferay for the first time, you can c/ic. the )ign In /in.. 1ou -i// then be presented -ith the Sign In &ortlet. ,his port/et a//o-s a user 5or a prospective user6 to do severa/ things2 sign in to Liferay, create a ne- account on the porta/, or have a pass-ord reminder emai/ed if the user has forgotten his or her pass-ord. ,o sign in for the first time, don't create an account for yourse/f. <e -i// do that /ater. $f you -ere to create a ne- account on the porta/ for yourse/f no-, it -ou/d be created using Liferay's defau/ts, -hich means the account -ou/d not have access to the admin) istrative port/ets you need in order to set up Liferay for your organization. 9or this reason, you -i// need to sign in as the defau/t administrative user. ,his user's creden) tia/s are2

'(

Liferay's 0ser $nterface

Configuration 6$er 3a+e) test[/iferay.com &a$$1ord) test Go ahead and sign into your ne- porta/ using these credentia/s. As you can see, Liferay by defau/t uses one's emai/ address as the user name. ,his can be changed /ater if you don't /i.e this functiona/ity, but it is genera//y a good practice to .eep it this -ay. 0sers' emai/ addresses are not norma//y things they -i// forget, and they are uniHue to each user, so they ma.e good candidates for user $=s. ,he first page that -i// be disp/ayed -hen a user /ogs in for the first time is the ,erms of 0se page. ,his page is disp/ayed to the user before he or she is a//o-ed to ac) cess the porta/. %y defau/t, your users -i// have to agree to your terms of service be) fore they -i// be a//o-ed to used the porta/. ,his page can be customized to contain -hatever te4t you -ant, or the feature can be disab/ed a/together. ,o continue, you -i// need to agree to the ,erms of Service. ?nce you /og in as the administrative user, you -i// see that /itt/e has changed. ,he Sign $n port/et no- disp/ays the name of the user 5-hose rather unimaginative name is ,est ,est6 -ho is /ogged in, and the =oc. no- disp/ays the te4t K<e/come, ,est ,estNL $f you hover your mouse over the doc. no-, ho-ever, you -i// see that there are many more /in.s in it2 2o+e) ta.es you to the home page. Control &anel) ta.es you to the admin) istrative functions of Liferay. % Account) /ets you edit your user in) formation. Sign 7ut) /ogs you out of the porta/. Add Application) opens the Add App/ic) ation -indo- -hich a//o-s you to add port) /ets to the page. La out 8e+plate) disp/ays the Layout ,emp/ate -indo- -hich a//o-s you to choose different /ayouts for the page. %anage &age$) ta.es you to the page administration screen, -here you can add and de/ete pages, change the order of the pages, and configure severa/ other things about pages. 8oggle #dit Control$) ,his -i// /et you turn on and off the edit contro/s in the top of the port/et -indo-s. ,his is he/pfu/ for ad) ministrators -ho -ant to /oo. at a page they're -or.ing on and see it the -ay a regu) /ar user -ou/d.

Illustration 2;! AdministratorSs Doc5

% &lace$) sho-s you the community and organization pages in the porta/ to

Liferay's 0ser $nterface

'#

Configuration -hich you can navigate. $f you ro// your mouse over My Places, the =oc. -i// e4pand, sho-ing a// of the p/aces in the porta/ to -hich you have access. $nitia//y, the p/ace you are on -i// be high/ighted. 1ou -i// see that you are in the Guest community, on the pub/ic pages. Liferay a//o-s for various configurations of pages for end users2 you can configure it so that some or a// users have their o-n pages, pub/ic and private 5or both6, upon -hich they can p/ace the port/ets they need to use. ,he administrator account by de) fau/t has its o-n pages. %ecause you are /ogged in -ith an account that has Adminis) trator privi/eges, you can see everything in the porta/. &e- in Liferay *.! is the Control Panel, a ne- interface -hich provides a sing/e p/ace to go for a// of Liferay's administrative functions. $n versions of Liferay prior to *.!, you needed to add the administrative port/ets to a page some-here, and a good p/ace to do that -as on the Administrator's private pages. &o- a// you need to do is go up to the =oc. and se/ect Control Panel. ,his is a much easier and faster -ay to access Liferay's administrative functions and -i// be the user interface going for-ard. <ith that said, the administrative port/ets are sti// avai/ab/e, and you can sti// provide access to them if you -ish.

Illustration 2?! LiferaySs Control Panel

Navi)atin) the !ontrol Panel


,he contro/ pane/ is very easy to navigate. ?n the /eft side is a /ist of headings -ith functions underneath them. ,he headings are in a/phabetica/ order, but the functions are in a /ogica/ order.

("

Liferay's 0ser $nterface

Configuration 6$er 3a+e) ,he first section is a/-ays the /ogged in user's persona/ space. ;ere, you can change your account information and manage your o-n persona/ pages. Content) ,he Content section contains /in.s to a// of Liferay's content manage) ment functions. 1ou can maintain -eb content, documents, images, boo.mar.s, a ca/) endar, administer a message board, configure a -i.i, and more. &ortal) ,he @orta/ section a//o-s porta/ administrators to set up and maintain the porta/. ,his is -here you can add and edit users, organizations, communities, ro/es, and configure the settings of the porta/. Ser!er) ,he Server section contains administrative functions for configuring porta/ instances, p/ugins, and more. A// of the functions that you -i// need to maintain the porta/ or its content can be found in the contro/ pane/. Additiona//y, deve/opers can -rite port/ets -hich can a/so be added to the contro/ pane/. 9or further information about this, you can ta.e Liferay's Portal Develo%er course or see the Liferay Develo%erSs .uide.

Portal Architecture
%efore -e dive into the user interface for adding and maintaining various porta/ resources, it is best to go over the concepts Liferay uses to organize a porta/. @orta/s are accessed by Users. Users can be co//ected into User .rou%s. Users can be/ong to 0rganiLations. 0rganiLations can be grouped into hierarchies, such as ;ome ?ffice )V Regiona/ ?ffice )V Sate//ite ?ffice. Users$ .rou%s$ and 0rganiLations can be/ong to Communities that have a common in) terest. ,he simp/est -ay to thin. about this is that you have users and various -ays those users can be grouped together. Some of these groupings fo//o- an administrat) ive/y organized hierarchy, and other groupings may be done by the users themse/ves 5such as different users from mu/tip/e organizations starting a community ca//ed K=og LoversL that has a common interest in dogs6. And other groupings may be done administrative/y via Ro/es for other functions that may cut across the porta/ 5such as a Message "oard Administrators ro/e made up of users from mu/tip/e communities and organizations, a//o-ing those users to administer any message board in the porta/6. ,his -ay of organizing porta/ concepts may be i//ustrated in the fo//o-ing man) ner2 $n the i//ustration be/o-, each arro- may be read using the -ords Kcan be a member of.L So this means that ?rganizations can be members of Communities, Com) munities can be members of Ro/es, 0sers can be members of anything, and so on. ,hough this seems very comp/e4, it provides a po-erfu/ mechanism for porta/ admin) istrators to configure porta/ resources and security in a consistent and robust man) ner. $t is important to note that the diagram i//ustrates on/y users and their co//ec)

@orta/ Architecture

(A

Configuration

Pages

Organizations

Organization Roles

Roles

Users

User Groups

Pages

Communities

Community Roles

Illustration 2B! Liferay %ortal resources tions. @ermissions do not f/o- through a// of these co//ections2 permissions can be as) signed to ro/es on/y.

-sers
0sers can be co//ected in mu/tip/e -ays. ,hey can be members of organization hierarchies, such as Liferay, $nc. Security $nternet Security. ,hey can be co//ec) ted into arbitrary user groups, such as "loggers, -hich -ou/d enab/e them to create b/og entries in their persona/ space. ,hey can be members of communities -hich dra- together common interests. And they can have ro/es -hich describe their func) tions in the system, and these ro/es can be scoped by @orta/, ?rganization, or Com) munity.

-ser Grou#s
0ser Groups are simp/e, arbitrary co//ections of users, created by administrators. ,hey can be members of communities or ro/es. @ermissions cannot be assigned to 0ser Groups. ,hough 0ser Groups do not have pages /i.e some of the other co//ec) tions of users 5such as Communities or ?rganizations6, they do have page temp/ates -hich can be used to customize users' persona/ sets of pages. ,his -i// be fu//y de) scribed be/o-.

Roles
,here are three .inds of ro/es2 @orta/ Ro/es

(!

@orta/ Architecture

Configuration ?rganization Ro/es Community Ro/es

,hese are ca//ed ro/e sco%es. Ro/es are used to define permissions across their scope2 across the porta/, across an organization, or across a community. 9or e4amp/e, consider a ro/e -hich grants access to create a :essage %oard category. A @orta/ ro/e -ou/d grant that access across the porta/, -herever there -as a :essage %oard port) /et. A Community ro/e -ou/d grant that access on/y -ithin a sing/e community. An ?r) ganization ro/e -ou/d grant that access on/y -ithin an ?rganization. %ecause Ro/es are used strict/y for porta/ security, they a/so do not have pages, /i.e Communities and ?rganizations. 0sers, 0ser Groups, Communities, or ?rganizations can be members of a ro/e.

1r)anizations
?rganizations are hierarchica/ co//ections of 0sers. ,hey are one of the t-o types of porta/ resources that can have pages. ,here is a/so a specia/ type of ?rganization ca//ed a location, -hich can define -here users are specifica//y /ocated. ?rganizations are handy for defining -here a user be/ongs in a particu/ar hier) archy. 9or e4amp/e, if you are imp/ementing Liferay for a /arge organization, it may he/p to define user Joe Smith via his position in the organization chart. $f Joe Smith is a Sa/es >ngineer /ocated in the &e- Jersey office, -or.ing in the &orth >ast division of the Sa/es department, he might be a member of the fo//o-ing organizations2 Sa/es &orth >ast =ivision &e- Jersey Location

&o- say that you have p/aced an Asset @ub/isher port/et as a static port/et on every user's home page 5via a 0ser Group page temp/ate6 so that you can inform em) p/oyees of various announcements via the content management system. $f you tagged your content appropriate/y, you cou/d ensure that Joe Smith gets any announcements that are meant for Sa/es, the &orth >ast =ivision, or the &e- Jersey /ocation. ?rganizations can be members of Communities.

!ommunities
Communities are co//ections of 0sers -ho have a common interest. Liferay's de) fau/t pages are in the Guest community, because everyone3-hether they are an) onymous or members of the porta/3has a common interest in the defau/t, pub/ic pages of your site. ,here are three types of Communities2 ?pen Restricted ;idden

@orta/ Architecture

(8

Configuration An ?pen Community 5the defau/t6 a//o-s porta/ users to Ioin and /eave the Com) munity -henever they -ant to, using the Contro/ @ane/ or a Communities port/et ad) ded to a page to -hich they have access. A Restricted Community reHuires that users be added to the Community by a community administrator. 0sers may use the Con) tro/ @ane/ or the Communities port/et to reHuest membership. A ;idden community is Iust /i.e a Restricted community, -ith the added concept that it does not sho- up at a// in the Communities port/et or the Contro/ @ane/.

-sin) the !ontrol Panel


,he &ortal section of the Contro/ @ane/ is used for most administrative tas.s. 1ou -i// find there an interface for the creation and maintenance of 0sers ?rganizations Communities 0ser Groups Ro/es @ass-ord @o/icies Authentication options, inc/uding Sing/e Sign)?n and L=A@ integration =efau/t 0ser Associations Reserved Screen &ames :ai/ ;ost &ames >mai/ &otifications

Additiona//y, it a//o-s you to configure many server settings, inc/uding2

1ou -i// use the @orta/ section of the Contro/ @ane/ to create your porta/ struc) ture, imp/ement security, and administer your users. &ote that on/y users -ith the Administrator ro/e3a porta/ scoped ro/e3have permission to vie- this section of the Contro/ @ane/.

Addin) -sers
Let's begin by adding a user account for yourse/f. <e -i// then configure this ac) count so that it has the same administrative access as the defau/t administrator ac) count. Go up to the =oc. and c/ic. the Control Panel /in., if you aren't there a/ready. ,hen under the Portal category, c/ic. Users. C/ic. the Add button. 1ou -i// then be presented -ith the Add 0ser form. 9i// out the form using your name and emai/ address. <hen you are finished, c/ic. )ave'

(C

0sing the Contro/ @ane/

Configuration

Illustration 2F! 4he Add User screen' ,he page -i// then reappear -ith a message saying that the save -as successfu/, and there -i// no- be an e4panded form -hich a//o-s you to fi// out a /ot more in) formation about the user. 1ou don't have to fi// anything e/se out right no-, but one thing is important to note2 -hen the user $= -as created, a pass-ord -as automatic) a//y generated and, if Liferay has been correct/y insta//ed 5see Chapter !6, an emai/ message -ith the pass-ord in it -as sent to the user. ,his of course reHuires that Liferay can proper/y communicate -ith your S:,@ mai/ server in your organization. $f you have not yet set up your mai/ server, you -i// need to use this screen to change the defau/t pass-ord for the user $= to something you can remember. 1ou can do this by c/ic.ing on the Password /in. in the bo4 on the right, entering the ne- pass) -ord in the t-o fie/ds, and c/ic.ing )ave. &e4t, you -i// -ant to give your user account the same administrative rights as the defau/t administrator's account. ,his -i// a//o- you to perform administrative tas.s -ith your o-n $= instead of having to use the defau/t $=. And this a//o-s you to ma.e your porta/ more secure by de/eting or disab/ing the defau/t $=. C/ic. the 9oles /in.. 1ou -i// then be ta.en to a screen -hich sho-s the ro/es to -hich your $= is current/y assigned. %y defau/t, you shou/d have one ro/e2 Power User. %y defau/t, a// users are a/so assigned the @o-er 0ser ro/e. 1ou can give this ro/e cer) tain permissions if you -ish or disab/e it a/together 5-e -i// see ho- to do this /ater6. 1ou can a/so define the defau/t ro/es a ne- user receivesU -e -i// go over this /ater

0sing the Contro/ @ane/

(*

Configuration

Illustration 2G! LiferaySs User Account editor' a/so. ,o ma.e yourse/f an Administrator, c/ic. the )elect /in.. A -indo- -i// pop up -ith a /ist of a// the ro/es in the system. Se/ect the Administrator ro/e from the /ist and the -indo- -i// disappear and you -i// see that the ro/e has been added to the /ist of ro/es to -hich you are assigned. &e4t, c/ic. the )ave button, -hich is at the bottom of the b/ue bar of /in.s on the right. 1ou are no- an administrator of the porta/. Log out of the porta/ and then /og bac. in -ith your o-n user $=.

-ser /ana)ement
$f you c/ic. the Users /in. on the /eft of the Contro/ @ane/, you -i// see that there are no- t-o users in the /ist of users. $f you -anted to change something about a par) ticu/ar user, you can c/ic. the Actions button ne4t to that user. #dit 6$er) ,his ta.es you bac. to the >dit 0ser page, -here you can modify any) thing about the user. &er+i$$ion$) ,his a//o-s you to define -hich Ro/es have permissions to edit the user. %anage &age$) $f the user has pages, this a//o-s you to edit them. I+per$onate 6$er) ,his opens another bro-ser -indo- -hich a//o-s you to bro-se the site as though you -ere the user. *eacti!ate) C/ic.ing this -i// deactivate the user's account.

(+

0sing the Contro/ @ane/

Configuration &ote that most users -i// not be ab/e to perform most of the above 5in fact, they -on't even have access to this section of the Contro/ @ane/6. %ecause you have admin) istrative access, you can perform a// of the above functions.

1r)anizations
?rganizations in Liferay are meant to mode/ organizations in rea/ /ife. ,hey can be used to represent different companies, non)profit organizations, churches, schoo/s, c/ubs, and so on. ,hey have been used to represent a sports /eague, -ith vari) ous sports 5soccer, baseba//, bas.etba//, etc.6 and their teams as sub)organizations. $f you have a co//ection of users that a// be/ong to the same grouping, you may be ab/e to mode/ that as an organization. 1our porta/ may have on/y one organization or severa/, depending on -hat .ind of site you are bui/ding. 9or e4amp/e, a corporate site may mode/ its o-n organization hierarchy in Liferay, -hi/e a socia/ net-or.ing site may have users from many separ) ate organizations -ho access the site. ?rganizations can have a hierarchy to un/im) ited /eve/s, and 0sers can be members of one or many organizations3inside of a hier) archy or across hierarchies. Additiona//y, ?rganizations can be associated -ith Ro/es. ?ne app/ication of this in a corporate setting cou/d be an $, Security group. 1ou may have an organization -ithin your $, organization that hand/es security for a// of the app/ications company) -ide. $f you had users as members of this organization, you cou/d grant the Adminis) trator ro/e you Iust granted to your o-n $= to the -ho/e ?rganization, thereby giving the members of the $, Security organization administrative access to the porta/. $f a user in this organization /ater -as hired by the ;uman Resources department, the simp/e administrative act of moving the user from the $, Security organization to the ;R organization -ou/d remove this privi/ege from the user, since the user -ou/d no /onger be in an organization that has the Administrator ro/e. %y adding the user to the ;R organization, any ro/es the ;R organization has 5such as access to a benefits system in the porta/6 -ou/d be transferred to the user. $n this manner, you can design your porta/ to correspond -ith your e4isting organization chart, and have users' per) missions ref/ect their positions in the chart. ?f course, this is on/y one -ay to design it. $f you have more comp/e4 reHuire) ments, you can combine ?rganizations -ith 0ser Groups and scoped Ro/es to as) semb/e the sets of permissions you -ish to grant to particu/ar users. ?rganizations are one of t-o types of Liferay resources 5the other being Com) munities6 that can have its o-n pages. ,his a//o-s members of the organizations 5if they are granted the Manage Pages permission6 to maintain their o-n pages. ,hey can have a set of pub/ic pages -hich inc/ude information and app/ications appropriate for guests or /ogged in users -ho are not members of the ?rganization to ma.e use of 5such as a he/p des. tic.et entry system for an $, page6, and they can have a set of private pages -ith app/ications for the organization's o-n use 5such as the bac.)end port/ets of the same tic.eting system6. ,o add an organization, c/ic. the 0rganiLations /in. on the /eft side of the Contro/ @ane/, and then c/ic. the Add button. 3a+e) ,he name of the organization. 0sing the Contro/ @ane/ ('

Configuration

Illustration 2K! Adding an organiLation' 8 pe) 0se this to choose -hether this is a regu/ar organization or a /ocation. &arent 7rgani9ation) C/ic. the )elect /in. to bring up a -indo- -hich a//o-s you to se/ect the organization in the system that is the direct parent of the organiza) tion you are creating. C/ic. the 9emove button to remove the current/y configured parent. 9i// out the information for your organization and c/ic. )ave. As before -ith users, the form reappears and you can enter more information about the organization. ?rganizations can have mu/tip/e emai/ addresses, posta/ ad) dresses, -eb sites, and phone numbers associated -ith them. ,he )ervices /in. can be used to indicate the operating hours of the organization, if any. 9or no-, c/ic. the <iew All button. ,his -i// ta.e you bac. to the /ist of organiza) tions. C/ic. the Actions button ne4t to the ne- organization you have created. 1ou -i// then see the many actions you can ta.e to manipu/ate this organization. #dit) Lets you edit the organization. %anage &age$) Lets you create and manage pub/ic and private pages for the ?r) ganization. A$$ign 6$er :ole$) Lets you assign ?rganization)scoped ro/es to users. %y de) fau/t, ?rganizations are created -ith three ro/es2 ?rganization Administrator, ?rgan) ization :ember, and ?rganization ?-ner. 1ou can assign one or more of these ro/es to users in the organization. A// members of the ?rganization get the ?rganization :ember ro/e. A$$ign %e+ber$) ,a.es you to a screen -here you can search and se/ect users in the porta/ to be assigned to this organization as members. Add 6$er) Adds a ne- user in the porta/ -ho -i// be a member of this organiza) tion. ;ie1 6$er$) Sho-s a /ist of users -ho are members of this organization. (( 0sing the Contro/ @ane/

Configuration Add :egular 7rgani9ation) Lets you add a chi/d organization to this organiza) tion. ,his is ho- you create hierarchies of organizations -ith parent)chi/d re/ation) ships. Add Location) Lets you add a chi/d Location, -hich is a specia/ type of organiza) tion that cannot have any chi/dren added to it. ;ie1 Suborgani9ation$) Sho-s a /ist of a// the organizations that are chi/dren of this organization. *elete) =e/etes this organization from the porta/. 1ou -i// have to ensure that the organization has no users in it first. Ti#$ Note that you are already a member of the organi,ation you created& because you created it. .y creating an organi,ation& you become both a member and have the <rgani,ation <wner role& which gives you full rights to the organi,ation.

!ommunities
Communities are very much /i.e ?rganizations e4cept that they are not hier) archica/. ,hey are designed instead to be is/ands to themse/ves -hich anyone from any organization 5or from no organization at a//6 can Ioin. 1ou can use Communities, therefore, in any situation -here you need to cut across the organizationa/ structure of your porta/, or -here you have a site that -ou/d app/y to a/most anybody. 9or e4amp/e, a corporate $ntranet running Liferay may have sites for a// the or) ganizations in the company2 Sa/es, :ar.eting, product groups, $nformation ,echno) /ogy, ;uman Resources, and so on. %ut -hat about the corporate hea/th and fitness centerJ ,hat's something that everybody in the company3regard/ess of organization 3potentia//y has an interest in, and may -ant to Ioin. ,hat's a good candidate for a Community. 0sing the same scenario, the home page for the $ntranet is probab/y best p/aced in a community that any member of the porta/ can access. 9or other .inds of -eb sites, you may -ant to use communities to bring peop/e together -ho have a common interest. $f you -ere bui/ding a photo sharing -eb site out of Liferay, you may have communities based on the types of photos peop/e -ant to share. So those -ho enIoy ta.ing pictures of /andscapes can Ioin a Landscapes com) munity, and those -ho enIoy ta.ing pictures of sunsets can Ioin a Sunsets community. And if they /ose interest, they can /eave those communities too. ,he defau/t home page in Liferay is in a community ca//ed Guest, and this is -here you -ou/d put your pub/ic -eb site. As you can see, there are severa/ scenarios in -hich you -ou/d -ant to use something /i.e a community instead of an organiza) tion, and this is -hy they have a distinct ro/e -ithin Liferay @orta/. Communities can be created and managed in t-o -ays. ,he first is through the Contro/ @ane/, /i.e every other user 7 page co//ection in Liferay. ,he second is through the % Co++unitie$ port/et, -hich can be added to any page in Liferay. <hy t-o -aysJ %ecause the :y Communities port/et a/so doub/es as a -ay to navigate from community to community, and a//o-s users to bro-se the /ist of communities

0sing the Contro/ @ane/

(#

Configuration and se/ect -hether or not they -ant to Ioin one 5if it is open or restricted6. ,his en) ab/es you as a porta/ administrator to provide users -ith this functiona/ity -ithout giving them access to the Contro/ @ane/. ,o add a community, c/ic. the Communities /in. on the /eft side of the Contro/ @ane/ in the @orta/ section, and then c/ic. the Add button. 3a+e) >nter the name of the community you -ish to create. *e$cription) >nter some descriptive te4t about the community. 8 pe) ,here are three .inds of communities2 0%en, 9estricted, and Private. An open community appears in the :y Communities port/et and users can Ioin and /eave the community -henever they -ant. A restricted community is the same e4cept users can on/y reHuest membership. A community administrator must then e4p/icit/y grant or deny users' reHuests to Ioin. A private community does not appear in the :y Com) munities port/et and users must be added to it manua//y by a community administrat) or. Acti!e) Communities can be active or inactive. $f a community is inactive, no data can be added to it. 8ag$) 1ou can use Liferay's tagging mechanism on the community. ,his is he/p) fu/ if the community has a specific, topica/ purpose -ithin the porta/. ?nce you have created a community, it -i// appear in the /ist of communities in the Contro/ @ane/. ,he operations you can perform on it are very simi/ar to the opera) tions you can perform on organizations. #dit) Lets you edit the community. %anage &age$) Lets you create and manage pub/ic and private pages for the community. A$$ign 6$er :ole$) Lets you assign community)scoped ro/es to users. %y defau/t, communities are created -ith three ro/es2 Community Administrator, Community :ember, and Community ?-ner. 1ou can assign one or more of these ro/es to users in the community. A// members of the community get the Community :ember ro/e. A$$ign %e+ber$) ,a.es you to a screen -here you can search and se/ect users in the porta/ to be assigned to this community as members. 4oin<Lea!e) $f you are not a member of the community, you -i// have a Join or ReHuest :embership option. $f you are a member of the community you -i// see an option to /eave the community. *elete) 0sers -ith administrative access to the porta/ or -ho are o-ners of the community can de/ete it.

!1//-N.T5 PR1>.S.1N.NG
Communities are idea/ -or.spaces for teams to co//aborate on common proIects. ,hey provide an iso/ated area -here a group of peop/e can p/ace a// of their data per) taining to a particu/ar topic, and many organizations have used them for this pur) pose. $t is a far better -ay to share data than using emai/ and a shared fo/der on a net) #" 0sing the Contro/ @ane/

Configuration -or.. $nstead, Liferay's =ocument Library port/et empo-ers users to access and up) date documents simu/taneous/y, and a// versions of the documents are preserved. A Ca/endar port/et can be used to .eep trac. of the team's appointments and meetings, and can send notifications out to the team. A <i.i port/et can be used to document the proIect as it progresses. A :essage %oards port/et can be used to .eep a// team discussions in one p/ace. ,o enab/e the ad)hoc creation of communities for this purpose, Liferay *.!.8 and above a//o-s porta/ administrators to create communities based on temp/ates. <hat this means is that you can create a temp/ate community that has a pre)defined set of pages and port/ets, and then use that temp/ate to very Huic./y create mu/tip/e com) munities that are pre)popu/ated -ith those pages and port/ets. 1ou can create temp/ates for open, restricted, and private communities. Addi) tiona//y, you can create a defau/t temp/ate that app/ies to a// .inds of communities. 9or our e4amp/e, -e -i// -or. -ith the defau/t temp/ate. Go to the Contro/ @ane/ and c/ic. Communities. C/ic. the Add button and create a community ca//ed D1(AUL4/41MPLA41. :a.e it a private community. ?nce the com) munity has been created, c/ic. Actions Manage Pages, and then c/ic. the )ettings tab. Se/ect Activate )taging.

Illustration ;J! Activating )taging on the community tem%late' &o- go ahead and use the Public Pages or Private Pages tabs to create pages in the temp/ate and popu/ate them -ith port/ets. 1ou can a/-ays use the <iew Pages button to vie- the pages you are creating, to add port/ets, and to change /ayouts. ,hese pages -i// be surrounded by a red border. ,his indicates that you are -or.ing in a staging environment. ,hat's a// you need to do. =on't pub/ish the changes to the temp/ateU /eave it in staging mode. Any future communities that you create -i// have the same /ayouts and port/ets as -hat you have p/aced in the =>9A0L,M,>:@LA,>.

0sing the Contro/ @ane/

#A

Configuration

Illustration ; ! Po%ulating %ages in the community tem%late ,o further refine this, you can create other .inds of temp/ates for specific types of communities in the same manner. $f community is open, use the name 0P16/41MPLA41 to create a temp/ate for open communities. 0se the name 91)49IC41D/41MPLA41 to create a temp/ate for re) stricted communities. 0se the name P9I<A41/41MPLA41 to create a temp/ate for private communities. ,he D1(AUL4/41MPLA41 -e have Iust created app/ies to a// types of communities. $f you -ant a// ne-/y created communities to have a 9orums page -ith a :essage %oards port/et on it, you -ou/d create that in the =>9A0L,M,>:@LA,>. ,his feature stream/ines the community creation process for administrators, ma.ing it very easy to Huic./y create communities for teams.

-ser Grou#s
0ser Groups are arbitrary groupings of users. ,hese groups are created by porta/ administrators to group users together -ho don't have an obvious organizationa/ or community)based attribute or aspect -hich brings them together. Groups cannot have permissions /i.e ro/es, but 0ser Groups can be added to Ro/es. <hy -ou/d you use 0ser Groups, thenJ ,hey come into p/ay -hen you have comp/e4 security reHuire) ments and for page temp/ates, -hich -e -i// discuss be/o-. Creating a 0ser Group is easy. C/ic. the User .rou%s /in. and then c/ic. the Add button. ,here are on/y t-o fie/ds to fi// out2 &ame 5the name of the 0ser Group6 and =escription 5an optiona/ description of -hat the group is for6. C/ic. )ave and you -i// then be bac. to the /ist of groups. As -ith the other resources in the porta/, you can c/ic. the Actions button to per) form various operations on 0ser Groups. #dit) A//o-s you to modify the name or description of the 0ser Group. &er+i$$ion$) ,his a//o-s you to define -hich 0sers, 0ser Groups, or Ro/es have permissions to edit the 0ser Group. %anage &age$) ,hough 0ser Groups don't have pages of their o-n, you can cre)

#!

0sing the Contro/ @ane/

Configuration ate %age tem%lates for a group. <hen a 0ser Group has page temp/ates, any users ad) ded to the group -i// have the group's pages copied to their persona/ pages. ,his a/) /o-s you to do things /i.e create a "loggers user group -ith a page temp/ate that has the %/ogs and Recent %/oggers port/ets on it. ,he first time users -ho are added to this group /og in to the porta/, this page -i// get copied to their persona/ pages. ,hey -i// then automatica//y have a b/og page that they can use. A$$ign %e+ber$) ,a.es you to a screen -here you can search for and se/ect users in the porta/ to be assigned to this 0ser Group. ;ie1 6$er$) Lets you vie- the users -ho are in the 0ser Group. *elete) =e/etes the 0ser Group.

-S R GR1-PS AN0 PAG T /PLAT

Liferay a//o-s users to have a persona/ set of pub/ic and private pages that each user can customize at -i//. ,he defau/t configuration of those pages can be determ) ined by the porta/ administrator through the %ortal&ext'%ro%erties fi/e and optiona//y by providing the configuration in a LAR fi/e. ,hough this has been a /ong)time feature of Liferay, it -as not very f/e4ib/e or easy to use. Liferay version *.A introduced the concept of %age tem%lates -hich are tied to 0ser Groups. ,his enab/es administrators to provide the same configuration for the persona/ pages of a// 5or Iust a subset of6 users, using Liferay's G0$ instead of the properties fi/e. $n some cases you may -ant to provide a different configuration for each user depending on his or her profi/e. 9or e4amp/e, in a porta/ for 0niversity stu) dents, staff and undergraduates -ou/d get different defau/t pages and port/ets in their persona/ space. 1ou can a/so set it up so that different groups are combined together to create the desired defau/t configuration. <hen a user is assigned to a user group, the configured page temp/ates are copied direct/y to the user's persona/ pages.

-S R GR1-P PAG T

/PLAT S$

*.N.NG PAG T /PLAT S *1R A -S R GR1-P

,he a 0ser Group's page temp/ates can be administered using the Contro/ @ane/. ,he User .rou%s /in. /ists a// the e4isting user groups and a//o-s you to perform sever) a/ actions on each of them. %y se/ecting the Manage Pages action the administrator -i// access the common Liferay 0$ for creating pages and organizing them in a hierarchy.

0sing the Contro/ @ane/

#8

Configuration

Illustration ;#! Manage Pages action on a User .rou%' &ote that it is possib/e to create both pub/ic and private pages. >ach set -i// be used as temp/ates to be copied to the user's persona/ pub/ic or private page sets re) spective/y -hen the user becomes a member of the user group.

Illustration ;2! Adding a Page 4em%late $n the screen shot above, the administrator has created a ne- private page ca//ed

#C

0sing the Contro/ @ane/

Configuration Aou are a student -ithin the )tudents user group. Since the page created is a port/et page, the administrator can no- c/ic. the <iew Pages button to open the page and add as many port/ets as desired to that page and configure them as needed. Let's assume for this e4amp/e that the Loan Calculator and Calendar port/ets are se/ected.

APPL5.NG

T3 PAG T /PLAT S (5 ASS.GN.NG / /( RS T1 T3 -S R GR1-P

,he ne4t step -i// be to assign an e4isting user to that group to verify that the page temp/ate is copied as a user's private page. ,o do this, c/ic. Actions Assign Members action in the /ist of avai/ab/e user groups.

Illustration ;;! Assigning Members to a User .rou% %y c/ic.ing the Available tab in the ne4t screen, a /ist of a// avai/ab/e users is sho-n. 9rom that /ist, one or more users can be se/ected to ma.e them members of the user group. <hen the U%date Associations button is c/ic.ed, the users become members of the group and copies of any pub/ic or private page temp/ates -hich are configured for the user group are copied to their page sets. $n the previous e4amp/e, a user that a/ready had an e4isting page ca//ed @elcome -i// no- have a ne- page ca//ed Aou Are A )tudent the ne4t time she accesses her per) sona/ space. ,hat page -i// contain t-o port/ets2 Loan Calculator and Calendar as con) figured by the 0ser Group administrator2

0sing the Contro/ @ane/

#*

Configuration

Illustration ;?! 4em%late co%ied to a userSs %age set'

A00.T.1NAL

0 TA.LS

%ecause the pages are copied to a user's set of pages, those pages are no- o-ned by the user and they can be changed at any time if the porta/ is set up to a//o- users to edit their persona/ pages. <hen a user is removed from a user group the associated pages -on't be removed2 they have become that user's pages. ,he system is smart enough, ho-ever, to detect -hen a user is added again to a group of -hich he or she -as a/ready a part, and the pages are not added again. $f an administrator modifies page temp/ates for a 0ser group after users have a/ready been added to the group, those changes -i// be used -hen ne- users are as) signed to the user group. Since the pages are temp/ates, ho-ever, the changes -on't be app/ied to users that -ere a/ready members of the user group.

!1/P1S.NG A PAG 1-T

1*

S > RAL -S R GR1-PS

0sers can be/ong to many user groups. $f you have temp/ates defined for a num) ber of groups, this may resu/t having many page temp/ates copied to users' pages. ,o prevent this, you can combine pages from different user groups into a sing/e page. Let's e4pand our previous e4amp/e by dividing the Students into (irst Aear )tu& dents, )econd Aear )tudents, 4hird Aear )tudents, International )tudents, and Pros%ective )tudents. 9or each of these types of students -e -ant them to have a page -ith the Loan Calculator and Calendar, but depending on -hich type -e a/so -ant other dif) ferent port/ets to be on that page too. ,his can be achieved by using a naming convention for the pages. $f t-o or more pages of different user groups have the same name, they -i// be combined into a sing/e page -hen they are copied to a user's persona/ pages set. $n the e4amp/e above, a 0ser -as added to a )tudents group -hich had a page ca//ed Aou are a )tudent. $f the administrator creates a page temp/ate -ith the same name 5Aou are a )tudent6 in the (irst Aear )tudents group and puts in it an RSS port/et pointing to information interesting for them, that page -ou/d be combined -ith the Aou are a )tudent page that's in the )tudents group, and the resu/ting page -ou/d con) tain the port/ets configured for both 0ser Groups2

#+

0sing the Contro/ @ane/

Configuration

Illustration ;B! Combined %ortlet %ages'

PAG !1/(.NAT.1N R-L S


,he fo//o-ing ru/es are used -hen composing a page by combining pages from different user groups2 $f a user becomes a member of a 0ser Group that has a page temp/ate -ith the same name in the same set 5pub/ic or private6 as a page that the user a/ready has, those pages -i// be combined. $f any of the pages has the name trans/ated to severa/ /anguages, on/y the defau/t /anguage is considered in the comparison. ,he port/ets on the ne- page -i// be copied to the bottom of the eHuiva/ent co/umns of the e4isting page. $f the e4isting and the ne- pages have different /ayout temp/ates, the e4ist) ing one is preserved. $f the ne- /ayout temp/ate has port/ets in co/umns that do not e4ist in the e4isting page, those port/ets -i// be automatica//y copied to the first co/umn of the e4isting /ayout temp/ate.

As you can see, it is possib/e to have a very f/e4ib/e configuration for the defau/t pages of porta/ users. 9urthermore, that configuration can be changed at any time us) ing the 0$ administrators are used to and then assigning users to ne- user groups. <hi/e these e4amp/es are some-hat simp/e, the system a//o-s for as many user groups as desired. %y using the convention of matching the page names it is possib/e to bui/d any defau/t page composition that you -ant for your users.

0sing the Contro/ @ane/

#'

Configuration

Roles
Ro/es are groupings of users that share a particu/ar function -ithin the porta/, according to a particu/ar scope. Ro/es can be granted permissions to various functions -ithin port/et app/ications. ,hin. of a ro/e as a description of a function, such as :es) sage %oard Administrators. A ro/e -ith that name is /i.e/y to have permissions to functions of the :essage %oard port/et de/egated to it. 0sers -ho are p/aced in this ro/e then inherit those permissions. Ro/es are scoped by @orta/, ?rganization, or Community. ,he Contro/ @ane/ ma.es it easy for you to assign users to Ro/es and to assign permissions to Ro/es. 1ou on/y have to go to one p/ace2 the 9oles /in.. 9rom there, you can add ro/es scoped by @orta/, ?rganization, or Community from one interface. ,o create a Ro/e, c/ic. the 9oles /in., and then c/ic. the Add button. ,ype a name for your ro/e and an optiona/ description. ,he drop do-n bo4 at the bottom of the form /ets you choose -hether this is a Regu/ar, Community, or ?rganization ro/e. <hen you have finished, c/ic. )ave. 1ou -i// be bac. at the /ist of ro/es. ,o see -hat functions you can perform on your ne- ro/e, c/ic. the Actions button. #dit) C/ic. this action to edit the ro/e. 1ou can change its name or description. &er+i$$ion$) ,his a//o-s you to define -hich 0sers, 0ser Groups, or Ro/es have permissions to edit the Ro/e. *efine &er+i$$ion$) C/ic. this to define -hat permissions this ro/e has. ,his is out/ined in the ne4t section. A$$ign %e+ber$) ,a.es you to a screen -here you can search and se/ect users in the porta/ to be assigned to this ro/e. ,hese users -i// inherit any permissions given to the ro/e. ;ie1 6$er$) Lets you vie- the users -ho are in the Ro/e. *elete) =e/etes the Ro/e.

Illustration ;F! Defining Permissions on a 9ole'

0 *.N.NG P

R/.SS.1NS 1N A

R1L

Ro/es e4ist as a buc.et for granting permissions to the users -ho are members of them. So one of the main tas.s you -i// be doing -ith a ro/e is granting it the permis) sions that you -ant members of the ro/e to have.

#(

0sing the Contro/ @ane/

Configuration <hen you c/ic. the Define Permissions action on a @orta/ scoped Ro/e, you are giv) en a choice of t-o .inds of permissions that can be defined for this ro/e2 Portal Permis& sions and Portlet Permissions. 9or other Ro/es, you on/y see the port/et permissions. @orta/ permissions cover porta/)-ide activities that are in severa/ categories, such as Community, Location, ?rganization, @ass-ord @o/icy, etc. ,his a//o-s you to create a Ro/e that, for e4amp/e, can create ne- Communities in the porta/. ,his -ou/d a//o- you to grant users that particu/ar permission -ithout ma.ing them overa// porta/ administrators. @ort/et permissions cover permissions that are defined -ithin various port/ets. C/ic.ing the Portlet Permissions button brings you to a page -here you can bro-se the names of the port/ets that are current/y insta//ed in your porta/. ?nce you choose a port/et, you can then define the actions -ithin this port/et that the ro/e -i// have per) mission to perform.

0sing the Contro/ @ane/

##

Configuration $f -e stic. -ith our e4amp/e of a Message "oards Admin ro/e, -e -ou/d then find the %e$$age -oard$ port/et in the /ist and c/ic. on it. A ne- page -ith configurab/e permissions -ou/d then be disp/ayed 5see right6. >ach possib/e action to -hich permissions can be granted is /isted. ,o grant a permission, choose the scope of the permission. 1ou have t-o choices2 1nter%rise and Communit& ies. Granting >nterprise permissions means that permission to the action -i// be granted across the porta/, in any community or organization -here there is a :essage %oards port) /et. $f you choose Communities, a button appears ne4t to the permis) sion a//o-ing you to choose one or more communities in -hich the per) mission -i// be va/id. ,his /ets you pic. and choose specific communities 5for a porta/ scoped ro/e6 in -hich these permissions are va/id for users in this ro/e. ?nce you have chosen the per) missions granted to this ro/e, c/ic. )ave. 9or a :essage %oards Admin ro/e, you -ou/d /i.e/y grant >nter) prise permissions to every action /is) ted. After you c/ic. )ave, you -i// see a /ist of a// permissions that are cur) rent/y granted to this ro/e. 9rom here, you can add more permissions 5by c/ic.ing Add Portlet Permissions or Add Portal Permissions6, or go bac. by c/ic.) ing a /in. in the breadcrumb /ist or the 9eturn to (ull Page /in.. Ro/es are very po-erfu/, and a/) /o- porta/ administrators to define various permissions in -hatever com) Illustration ;G! Message "oards %ermissions' binations they /i.e. ,his gives you as much f/e4ibi/ity as possib/e to bui/d the site you have designed.

A""

0sing the Contro/ @ane/

Configuration

SP !.AL N1T

A(1-T T3

P1W R -S RS R1L

%y defau/t, many port/ets -ithin Liferay are configured so that @o-er 0sers have access to them, but regu/ar users do not. $f you decide to remove the @o-er 0sers ro/e from the defau/t user associations 5see be/o- on page A"!6, you -i// need to modify the permissions on certain port/ets. ,o do this, see the section on @/ugins Configura) tion be/o- 5page AAC6.

Glo"al Server Settin)s


&o- that you have navigated in the Contro/ @ane/, you shou/d be pretty fami/iar -ith ho- it -or.s, and hopefu//y no- you are comfortab/e e4p/oring around the vari) ous options on the /eft. <e have focused so far on the maintenance of users and porta/ security. ,he remaining /in.s in the Portal category focus on various porta/ settings -hich cover ho- the porta/ operates and integrates -ith other systems you may have.

Password Policies
@ass-ord po/icies can he/p to enhance the security of your porta/. 0sing pass) -ord po/icies, you can set pass-ord ru/es such as pass-ord strength, freHuency of pass-ord e4piration, and more. Additiona//y, you can app/y different ru/e sets to dif) ferent sets of porta/ users. $f you are vie-ing a page other than the Contro/ @ane/, go up to the =oc. and se) /ect the Contro/ @ane/. &e4t, c/ic. on the Password Policies /in. on the /eft side of the screen in the Portal category. 1ou -i// see that there is a/ready a defau/t pass-ord po/icy in the system. 1ou can edit this in the same manner as you edit other resources in the porta/2 c/ic. Actions and then c/ic. 1dit. 1ou -i// then see the @ass-ord @o/icy settings form2 Changeable) Se/ects -hether a user can change his or her pass-ord. Change :e=uired) Se/ects -hether a user must change his or her pass-ord upon first /og in. %ini+u+ Age) 1ou can choose ho- /ong a pass-ord must remain in effect be) fore it can be changed. S nta( Checking) A//o-s you to choose -hether dictionary -ords can be in pass-ords as -e// as the minimum pass-ord /ength. &a$$1ord 2i$tor ) Eeeps a history 5-ith a defined /ength6 of pass-ords and -on't a//o- users to change their pass-ords to one that -as previous/y used. &a$$1ord #(piration) Lets you choose an interva/ -here pass-ords can be act) ive before they e4pire. 1ou can se/ect the age, the -arning time, and a grace /imit. Lockout) A//o-s you to set the number of fai/ed /og in attempts before a user's account becomes /oc.ed. 1ou can choose -hether an administrator needs to un/oc. the account or if it becomes un/oc.ed after a specific duration. 9rom the /ist of pass-ord po/icies, you can perform severa/ other actions.

G/oba/ Server Settings

A"A

Configuration #dit) %rings you to the form above and a//o-s you to modify the pass-ord po/icy. &er+i$$ion$) ,his a//o-s you to define -hich 0sers, 0ser Groups, or Ro/es have permissions to edit the @ass-ord @o/icy. A$$ign %e+ber$) ,a.es you to a screen -here you can search and se/ect users in the porta/ to be assigned to this pass-ord po/icy. ,he pass-ord po/icy -i// be en) forced for any users -ho are added here. *elete) ,his sho-s up for any pass-ord po/icies that you add beyond the defau/t po/icy. 1ou cannot de/ete the defau/t po/icy.

Settin)s
,he Settings /in. is -here most of the g/oba/ porta/ settings are2 >eneral) ,his /ets you configure g/oba/ settings, such as the company name, do) main, the virtua/ host, a g/oba/ porta/ /ogo, and more. Authentication) A//o-s you to configure /ogin $=s, connection to L=A@, and Sing/e Sign)?n. *efault 6$er A$$ociation$) Lets you configure defau/t membership to Ro/es, 0ser Groups, and Communities for ne- users. :e$er!ed Credential$) Lets you reserve screen names and emai/ addresses so that users cannot register using them. 1ou might use this to prevent users from regis) tering on the porta/ -ith user names that contain profanity or that sound officia/, such as admin or %resident. %ail 2o$t 3a+e$) 1ou can add a /ist of other mai/ servers besides your main one here. #+ail 3otification$) Liferay sends emai/ notifications for certain events, such as user registrations, pass-ord changes, etc. 1ou can customize those messages here. <e -i// go over these settings in detai/ be/o-.

N RAL

,he .eneral /in. a//o-s you to set the name of the company 7 organization 7 site -hich is running the porta/. 1ou can a/so set the virtua/ host, the mai/ domain, and severa/ other items of misce//aneous information about the organization.

A-T3 NT.!AT.1N$ G

N RAL

S TT.NGS

,he Authentication /in. has severa/ tabs under it. A// of these are used for config) uring ho- users -i// authenticate to Liferay. %ecause Liferay supports a number of authentication methods, there are settings for each. ,he genera/ settings affect on/y Liferay functiona/ity, and don't have anything to do -ith any of the integration options on the other tabs. ,his tab a//o-s you to cus) tomize Liferay's out)of)bo4 behavior regarding authentication. Specifica//y, the .ener& al tab a//o-s you to se/ect from severa/ g/oba/ authentication settings2 A"! G/oba/ Server Settings

Configuration Authenticate via emai/ address 5defau/t6, screen name, or user $= 5a numer) ica/ $= auto)generated in the database3not recommended6. >nab/e 7 =isab/e automatic /ogin. $f enab/ed, Liferay a//o-s user to chec. a bo4 -hich -i// cause the site to KrememberL the user's /og in by p/acing a coo.ie on his or her bro-ser. $f disab/ed, users -i// have to /og in manua//y. >nab/e 7 =isab/e 9orgot @ass-ord functiona/ity. >nab/e 7 =isab/e account creation by strangers. $f you are running an $nter) net site, you -i// probab/y -ant to /eave this on so that visitors can create accounts on your site. >nab/e 7 =isab/e account creation by those using an emai/ address in the do) main of the company running the site 5-hich you Iust set on the Genera/ tab6. >nab/e 7 =isab/e emai/ address verification. $f you enab/e this, Liferay, -i// send users a verification emai/ -ith a /in. bac. to the porta/ to verify the emai/ address they entered is a va/id one they can access.

%y defau/t, a// settings e4cept for the /ast are enab/ed by defau/t. ?ne defau/t that is important is that users -i// authenticate by their emai/ address. Liferay defau/ts to this for severa/ reasons2 A. !. An emai/ address is, by definition, uniHue to the user -ho o-ns it. @eop/e can genera//y remember their emai/ addresses. $f you have a user -ho hasn't /ogged into the porta/ for a -hi/e, it is possib/e that he or she -i// forget his or her screen name, especia//y if the user -as not a//o-ed to use his or her screen name of choice 5because somebody e/se a/ready used it6. $f a user changes his or her emai/ address, if it is not used to authenticate, it is more /i.e/y that the user -i// forget to update his or her emai/ address in his or her profi/e. $f the user's emai/ address is not updated, a// notifications sent by the porta/ -i// fai/ to reach the user. So it is important to .eep the emai/ address at the forefront of a user's mind -hen he or she /ogs in to he/p the user .eep it up to date.

8.

9or these reasons, Liferay defau/ts to using the emai/ address as a user name.

A-T3 NT.!AT.1N$ L0AP


Connecting Liferay to an L=A@ directory has become much easier and is no- a straightfor-ard process through the Contro/ @ane/. ,here are sti//, ho-ever, t-o p/aces in -hich you can configure the L=A@ settings2 the %ortal&ext'%ro%erties fi/e 5-hich -i// be covered in the ne4t chapter6 and the Contro/ @ane/3-here the settings -i// get stored in the database. &ote that if you use both, the settings in the database -i// override the settings in %ortal&ext'%ro%erties. 9or this reason, -e recommend for most users that you use the Contro/ @ane/ to configure the L=A@ settings3it's easier and does not reHuire a restart of Liferay. ,he on/y compe//ing reason to use the %ortal& ext'%ro%erties fi/e is if you have many Liferay nodes -hich -i// be configured to run against the same L=A@ directory. $n that case, for your initia/ dep/oyment, it may be easier to copy the %ortal&ext'%ro%erties fi/e to a// of the nodes so that the first time they G/oba/ Server Settings A"8

Configuration start up, the settings are correct. Regard/ess of -hich method you use, the settings are the same. ,he L=A@ settings screen is very detai/ed, so -e -i// /oo. at it in chun.s.

GL1(AL >AL- S
,here are t-o g/oba/ L=A@ settings. #nabled) Chec. this bo4 to enab/e L=A@ Authentication. :e=uired) Chec. this bo4 if L=A@ authentication is reHuired. Liferay -i// then not a//o- a user to /og in un/ess he or she can successfu//y bind to the L=A@ directory first. 0nchec. this bo4 if you -ant to a//o- users that have Liferay accounts but no L=A@ accounts to /og in to the porta/.

0 *A-LT >AL- S
Severa/ /eading directory servers are /isted here. $f you are using one of these, se) /ect it and the rest of the form -i// be popu/ated -ith the proper defau/t va/ues for that directory.

!1NN

!T.1N

,hese settings cover the basic connection to L=A@. -a$e &ro!ider 6:L) ,his te//s the porta/ -here the L=A@ server is /ocated. :a.e sure that the machine on -hich Liferay is insta//ed can communicate -ith the L=A@ server. $f there is a fire-a// bet-een the t-o systems, chec. to ma.e sure that the ap) propriate ports are opened. -a$e *3) ,his is the %ase =istinguished &ame for your L=A@ directory. $t is usu) a//y mode/ed after your organization. 9or a commercia/ organization, it may /oo. something /i.e2 dcQcom%anynamehere$dcQcom' &rincipal) %y defau/t, the administrator $= is popu/ated here. $f you have re) moved the defau/t L=A@ administrator, you -i// need to use the fu//y Hua/ified name of the administrative credentia/ you do use. 1ou need an administrative credentia/ because Liferay -i// be using this $= to synchronize user accounts to and from L=A@. Credential$) ,his is the pass-ord for the administrative user. ,his is a// you need in order to ma.e a regu/ar connection to an L=A@ directory. ,he rest of the configuration is optiona/2 genera//y, the defau/t attribute mappings are sufficient data to synchronize bac. to the Liferay database -hen a user attempts to /og in. ,o test the connection to your L=A@ server, c/ic. the 4est LDAP Connection but) ton. $f you are running your L=A@ directory in SSL mode to prevent credentia/ in) formation from passing through the net-or. unencrypted, you -i// have to perform e4tra steps to share the encryption .ey and certificate bet-een the t-o systems. 9or e4amp/e, assuming your L=A@ directory happens to be :icrosoft Active =ir) ectory on <indo-s Server !""8, you -ou/d ta.e the fo//o-ing steps to share the certi) A"C G/oba/ Server Settings

Configuration ficate2 ?n the <indo-s !""8 =omain Contro//er, open the Certificates ::C snapin. >4) port the Root Certificate Authority certificate by se/ecting Certificates NLocal Com%uterO mmc sna%in &R 4rusted 9oot Certification Authorities &R My9ootCACertificate6ame' Right c/ic. this certificate and se/ect All 4as5s )V ex%ort )V select D19 encoded binary E'?JK 'C19. Copy the e4ported 'cer fi/e to your Liferay @orta/ server. As -ith the CAS insta// 5see the be/o- section entit/ed Single Sign07n6, you -i// need to import the certificate into the cacerts 5eystore. ,he import is hand/ed by a command /i.e the fo//o-ing2
keytool -import -trustcacerts -keystore /some/path/jdk3.6.4L33/jre/lib/security/cacerts -storepass changeit -noprompt -alias $yFoot&8 -file /some/path/$yFoot&8.cer

,he 5eytool uti/ity ships as part of the Java S=E. ?nce this is done, go bac. to the L=A@ page in the Contro/ @ane/. :odify the L=A@ 0RL in the -a$e *3 fie/d to the secure version by changing the protoco/ to htt%s and the port to +8+ /i.e the fo//o-ing2
ldaps*//my!dapServerMostname*?2?

Save the changes. 1our Liferay @orta/ -i// no- use L=A@ in secure mode for au) thentication.

-S RS
,his section contains settings for finding users in your L=A@ directory. Authentication Search ?ilter) ,he search fi/ter bo4 can be used to determine the search criteria for user /ogins. %y defau/t, Liferay uses the emai/ address as a user /ogin name. $f you have changed this setting3-hich can be done on the .eneral tab that's ne4t to the LDAP tab in the )ettings&RAuthentication section of the Contro/ @ane/ 3you -i// need to modify the search fi/ter here, -hich has by defau/t been configured to use the emai/ address attribute from L=A@ as search criteria. 9or e4amp/e, if you changed Liferay's authentication method to use the screen name instead of the emai/ address, you -ou/d modify the search fi/ter so that it can match the entered /ogin name2
Acn IscreenLnameIB

I+port Search ?ilter) =epending on the L=A@ server, there are different -ays to identify the user. Genera//y, the defau/t setting 5ob*ectClassQinet0rgPerson6 is fine, but if you -ant to search for on/y a subset of users or users that have different obIect c/asses, you can change this. 6$er %apping) ,he ne4t series of fie/ds a//o-s you to define mappings from L=A@ attributes to Liferay fie/ds. ,hough your L=A@ user attributes may be different from L=A@ server to L=A@ server, there are five fie/ds that Liferay reHuires to be mapped in order for the user to be recognized. 1ou must define a mapping to the cor) responding attributes in L=A@ for the fo//o-ing Liferay fie/ds2 Screen &ame

G/oba/ Server Settings

A"*

Configuration @ass-ord >mai/ Address 9irst &ame Last &ame

,he Contro/ @ane/ provides defau/t mappings for common/y used L=A@ attrib) utes. 1ou can a/so add your o-n mappings if you -ish. 8e$t L*A& 6$er$) ?nce you have your attribute mappings set up 5see above6, c/ic. the 4est LDAP Users button, and Liferay -i// attempt to pu// L=A@ users and match them up -ith their mappings as a previe-.

Illustration ;K! 4esting LDAP Users

GR1-PS
,his section contains settings for mapping L=A@ groups to Liferay. I+port Search ?ilter) ,his is the fi/ter for finding L=A@ groups that you -ant to map to Liferay. >nter the L=A@ group attributes that you -ant retrieved for this map) ping. ,he fo//o-ing attributes can be mapped2 Group &ame =escription 0ser

8e$t L*A& >roup$) C/ic. the 4est LDAP .rou%s to disp/ay a /ist of the groups re) turned by your search fi/ter.

A"+

G/oba/ Server Settings

Configuration

Illustration ?J! Ma%%ing LDAP .rou%s'

./P1RT<

4P1RT

I+port #nabled) Chec. this bo4 to cause Liferay to do a mass import from your L=A@ directory. $f you -ant Liferay to on/y synchronize users -hen they /og in, /eave this bo4 unchec.ed. =efinite/y /eave this unchec.ed if you are -or.ing in a c/ustered environment. ?ther-ise, a// of your nodes -ou/d try to do a mass import -hen each of them starts up. $f you chec. the bo4, severa/ other options -i// become avai/ab/e. I+port on Startup #nabled) Chec. this bo4 to have Liferay run the import -hen it starts up. ,his bo4 on/y appears if you chec. Im%ort 1nabled above. I+port Inter!al) ,he import runs on a schedu/e. Se/ect ho- often you -ant the import to run. ,his se/ection bo4 on/y appears if you chec. Im%ort 1nabled above. #(port #nabled) Chec. this bo4 to enab/e Liferay to e4port user accounts from the database to L=A@. Liferay uses a /istener to trac. any changes made to the 0ser obIect and -i// push these changes out to the L=A@ server -henever the 0ser obIect is updated. &ote that by defau/t on every /ogin, fie/ds such as LastLoginDate are updated. <hen e4port is enab/ed, this has the effect of causing a user e4port every time the user /ogs in. 1ou can disab/e this by setting the fo//o-ing property in your %ortal&ext'& %ro%erties fi/e2
users.update.last.login false

6$er$ *3) >nter the /ocation in your L=A@ tree -here the users -i// be stored. <hen Liferay does an e4port, it -i// e4port the users to this /ocation. 6$er *efault 7b@ect Cla$$e$) <hen a user is e4ported, the user is created -ith the /isted defau/t obIect c/asses. ,o find out -hat your defau/t obIect c/asses are, use an L=A@ bro-ser too/ such as 3E%lorer to /ocate a user and vie- the ?bIect C/ass attrib) utes that are stored in L=A@ for that user. >roup$ *3) >nter the /ocation in your L=A@ tree -here the groups -i// be stored. <hen Liferay does an e4port, it -i// e4port the groups to this /ocation.

G/oba/ Server Settings

A"'

Configuration 6$e L*A& &a$$1ord &olic ) Liferay uses its o-n pass-ord po/icy by defau/t. ,his can be configured on the Password Policies /in. in the Portal section on the /eft side of the Contro/ @ane/. $f you -ant to use the pass-ord po/icies defined by your L=A@ directory, chec. this bo4. ?nce this is enab/ed, the Password Policies tab -i// dis) p/ay a message stating that you are not using a /oca/ pass-ord po/icy. 1ou -i// nohave to use your L=A@ directory's mechanism for setting pass-ord po/icies. Liferay does this by parsing the messages in the L=A@ contro/s that are returned by your L=A@ server. %y defau/t, the messages in the L=A@ contro/s that Liferay is /oo.ing for are the messages that are returned by the 9edora =irectory Server. $f you are using a different L=A@ server, you -i// need to customize the messages in Liferay's %ortal&ext'& %ro%erties fi/e, as there is not yet a G0$ for setting this. See be/o- for instructions de) scribing ho- to do this. ?nce you have comp/eted configuring L=A@, c/ic. the )ave button.

L0AP 1PT.1NS N1T A>A.LA(L

.N T3

G-.

,hough most of the L=A@ configuration can be done from the Contro/ @ane/, there are severa/ configuration parameters that are on/y avai/ab/e by editing %ortal& ext'%ro%erties. ,hese options -i// be avai/ab/e in the G0$ in future versions of Liferay @orta/, but for no- they can on/y be configured by editing the properties fi/e. $f you need to change any of these options, copy the L=A@ section from the %ortal'%ro%erties fi/e into your %ortal&ext'%ro%erties fi/e. &ote that since you have a/ready configured L=A@ from the G0$, any settings from the properties fi/e that match set) tings a/ready configured in the G0$ -i// be ignored. ,he G0$, -hich stores the settings in the database, a/-ays ta.es precedence over the properties fi/e.
ldap.auth.method bind #ldap.auth.method password-compare

Set either bind or pass-ord)compare for the L=A@ authentication method. %ind is preferred by most vendors so that you don't have to -orry about encryption strategies. @ass-ord compare does e4act/y -hat it sounds /i.e2 it reads the user's pass-ord out of L=A@, decrypts it, and compares it -ith the user's pass-ord in Liferay, syncing the t-o.
ldap.auth.password.encryption.algorithm ldap.auth.password.encryption.algorithm.types $)6,SM8

Set the pass-ord encryption to used to compare pass-ords if the property lda%'auth'method is set to pass-ord)compare.
ldap.import.method Uuser,groupV

$f you set this to user$ Liferay -i// import a// users from the specified portion of the L=A@ tree. $f you set this to grou%, Liferay -i// search a// the groups and import the users in each group. $f you have users -ho do not be/ong to any groups, they -i// not be imported.
ldap.error.password.age age ldap.error.password.e<pired e<pired ldap.error.password.history history ldap.error.password.not.changeable not allowed to change

A"(

G/oba/ Server Settings

Configuration
ldap.error.password.synta< synta< ldap.error.password.trivial trivial ldap.error.user.lockout retry limit

,hese properties are a /ist of phrases from error messages -hich can possib/y be returned by the L=A@ server. <hen a user binds to L=A@, the server can return con& trols -ith its response of success or fai/ure. ,hese contro/s contain a message describ) ing the error or the information that is coming bac. -ith the response. ,hough the contro/s are the same across L=A@ servers, the messages can be different. ,he proper) ties described here contain snippets of -ords from those messages, and -i// -or. -ith Red ;at's 9edora =irectory Server. $f you are not using that server, the -ord snippets may not -or. -ith your L=A@ server. $f they don't, you can rep/ace the va/) ues of these properties -ith phrases from your server's error messages. ,his -i// en) ab/e Liferay to recognize them.

S.NGL S.GN,1N
Sing/e Sign)?n so/utions a//o- you to provide a sing/e /og in credentia/ for mu/) tip/e systems. ,his a//o-s you to have peop/e authenticate to the Sing/e Sign)?n product and they -i// be automatica//y /ogged in to Liferay and to other products as -e//. Liferay at the time of this -riting supports severa/ sing/e sign)on so/utions. ?f course if your product is not yet supported, you may choose to imp/ement support for it yourse/f by use of the e4tension environment3or your organization can choose to sponsor support for it. @/ease contact sa/es[/iferay.com for more information about this.

A-T3 NT.!AT.1N$ ! NTRAL A-T3 NT.!AT.1N S R>.! ?!AS@


CAS is an authentication system that -as origina//y created at 1a/e 0niversity. $t is a -ide/y)used open source sing/e sign)on so/ution, and -as the first SS? product to be supported by Liferay. @/ease fo//o- the documentation for CAS to insta// it on your app/ication server of choice. 1ou can use the version that Liferay provides on our -eb site or the officia/ version from the JA)S$G -eb site. ,he reason for the difference is simp/y that ne-er versions reHuire J=E * and above on/y. <e provide the o/der ones for use -ith Liferay C.C.! and be/o-, so that users can have a fu// environment that runs on J=E A.C. Ti#$ %f you are using Liferay 5.x& use the newer versions of )+( from the J+" (%= web site. %f you are using Liferay #.x& use the older >ale versions of )+( from Liferay1s (ourceforge archives.

1our first step -i// be to copy the CAS c/ient .Iar fi/e to Liferay's /ibrary fo/der. ?n ,omcat, this is in T4omcat HomeR+weba%%s+9004+@1"&I6(+lib. ?nce you've done this, the CAS c/ient -i// be avai/ab/e to Liferay the ne4t time you start it.

G/oba/ Server Settings

A"#

Configuration ,he CAS Server app/ication reHuires a proper/y configured Secure Soc.et Layer certificate on your server in order to -or.. $f you -ish to generate one yourse/f, you -i// need to use the 5eytool uti/ity that comes -ith the J=E. 1our first step is to gener) ate the .ey. &e4t, you e4port the .ey into a fi/e. 9ina//y, you import the .ey into your /oca/ Java .ey store. 9or pub/ic, $nternet)based production environments, you -i// need to either purchase a signed .ey from a recognized certificate authority 5such as ,ha-te or Berisign6 or have your .ey signed by a recognized certificate authority. 9or $ntranets, you shou/d have your $, department pre)configure users' bro-sers to ac) cept the certificate so that they don't get -arning messages about the certificate. ,o generate a .ey, use the fo//o-ing command2
keytool -genkey -alias tomcat -keypass changeit -keyalg FS8

$nstead of the pass-ord in the e4amp/e 5changeit6, use a pass-ord that you -i// be ab/e to remember. $f you are not using ,omcat, you may -ant to use a different a/ias as -e//. 9or 9irst and Last name, enter localhost$ or the host name of your server. $t cannot be an $@ address. ,o e4port the .ey to a fi/e, use the fo//o-ing command2
keytool -e<port -alias tomcat -keypass changeit -file server.cert

9ina//y, to import the .ey into your Java .ey store, use the fo//o-ing command2
keytool -import -alias tomcat -file J0I!.L'8$.J -keystore @E8K8LMN$./jre/lib/security/cacerts -keypass changeit

$f you are on a <indo-s system, rep/ace -3A<A/H0M1 above -ith U3A<A/H0M1U. ?f course, a// of this needs to be done on the system on -hich CAS -i// be running. ?nce your CAS server is up and running, you can configure Liferay to use it. ,his is a simp/e matter of navigating to the )ettings )V Authentication )V CA) tab in the Con) tro/ @ane/. >nab/e CAS authentication, and then modify the 0RL properties to point to your CAS server. #nabled) Set this to true to enab/e CAS sing/e sign)on. I+port fro+ L*A&) A user may be authenticated from CAS and not yet e4ist in the porta/. Se/ect this to automatica//y import users from L=A@ if they do not e4ist in the porta/. ,he rest of the settings are various 0RLs, -ith defau/ts inc/uded. Change localhost in the defau/t va/ues to point to your CAS server. <hen you are finished, c/ic. )ave. After this, -hen users c/ic. the )ign In /in. from the =oc., they -i// be directed to the CAS server to sign in to Liferay.

A-T3 NT.!AT.1N$ NTL/


&,L: is a :icrosoft protoco/ that can be used for authentication through :i) crosoft $nternet >4p/orer. ,hough :icrosoft has adopted Eerberos in modern ver) sions of <indo-s server, &,L: is sti// used -hen authenticating to a -or.group. #nabled) Chec. the bo4 to enab/e &,L: authentication. *o+ain Controller) >nter the $@ address of your domain contro//er. ,his is the

AA"

G/oba/ Server Settings

Configuration server that contains the user accounts you -ant to use -ith Liferay. *o+ain) >nter the domain 7 -or.group name.

A-T3 NT.!AT.1N$ 1P N.0


?pen$= is a ne- sing/e sign)on standard -hich is imp/emented by mu/tip/e vendors. ,he idea is that mu/tip/e vendors can imp/ement the standard, and then users can register for an $= -ith the vendor they trust. ,he credentia/ issued by that vendor can be used by a// the -eb sites that support ?pen$=. Some high profi/e ?pen) $= vendors are A?L 5http277openid.ao/.com7screenname6, Live=oor 5http277pro) fi/e./ivedoor.com7username6, and LiveJourna/ 5http277username./iveIourna/.com6. @/ease see the ?pen$= site 5http277---.openid.net6 for a more comp/ete /ist. ,he obvious main benefit of ?pen$= for the user is that he or she no /onger has to register for a ne- account on every site in -hich he or she -ants to participate. 0sers can register on one site 5the ?pen$= provider's site6 and then use those credentia/s to authenticate to many -eb sites -hich support ?pen$=. :any -eb site o-ners often strugg/e to bui/d communities because end users are re/uctant to register for so many different accounts. Supporting ?pen$= ma.es it easier for site o-ners to bui/d their communities because the barriers to participating 5i.e., the effort it ta.es to register for and .eep trac. of many accounts6 are removed. A// of the account information is .ept -ith the ?pen$= provider, ma.ing it much easier to manage this information and .eep it up to date. Liferay @orta/ can act as an ?pen$= consumer, a//o-ing users to automatica//y re) gister and sign in -ith their ?pen$= accounts. $nterna//y, the product uses ?pen$=C) Java 5http277code.goog/e.com7p7openidCIava76 to imp/ement the feature. ?pen$= is enab/ed by defau/t in Liferay, but can be disab/ed on this tab.

ATLASS.AN !R1W0
At/assian Cro-d is a -eb)based Sing/e Sign)?n product simi/ar to CAS. Cro-d can be used to manage authentication to many different -eb app/ications and directory servers. %ecause At/assian Cro-d imp/ements an ?pen$= producer, Liferay -or.s and has been tested -ith it. Simp/y use the ?pen$= authentication feature in Liferay to /og in using Cro-d.

A-T3 NT.!AT.1N$ 1P NSS1


?penSS? is an open source sing/e sign)on so/ution that comes from the code base of Sun's System Access :anager product. Liferay integrates -ith ?penSS?, a//o-ing you to use ?penSS? to integrate Liferay into an infrastructure that contains a mu/ti) tude of different authentication schemes against different repositories of identities. 1ou can set up ?penSS? on the same server as Liferay or a different bo4. 9o//othe instructions at the ?penSS? site 5http277opensso.dev.Iava.net6 to insta// ?penSS?. ?nce you have it insta//ed, create the Liferay administrative user in it. 0sers are mapped bac. and forth by screen names. %y defau/t, the Liferay administrative user G/oba/ Server Settings AAA

Configuration has a screen name of test, so in ?penSS?, you -ou/d register the user -ith the $= of test and an emai/ address of testVliferay'com. ?nce you have the user set up, /og in to ?pen SS? using this user. $n the same bro-ser -indo-, go to the 0RL for your server running Liferay and /og in as the same user, using the emai/ address testVliferay'com. Go to the Contro/ @ane/ and c/ic. )ettings &R Authentication &R 0%en))0. :odify the three 0RL fie/ds 5Login 0RL, Logout 0RL, and Service 0RL6 so that they point to your ?penSS? server 5i.e., on/y modify the host name portion of the 0RLs6, c/ic. the 1nabled chec. bo4, and then c/ic. )ave' Liferay -i// then redirect users to ?penSS? -hen they c/ic. the )ign In /in..

A-T3 NT.!AT.1N$ S.T /.N0 R


Site:inder is a sing/e sign)on imp/ementation from Computer Associates. Liferay *.! no- has bui/t)in integration -ith Site:inder. Site:inder uses a custom ;,,@ header to imp/ement its sing/e sign)on so/ution. ,o enab/e Site:inder authentication in Liferay, chec. the 1nabled bo4 on the )iteMinder tab. $f you are a/so using L=A@ -ith Liferay, you can chec. the Im%ort from LDAP bo4. $f this bo4 is chec.ed, user authenticated from Site:inder that do not e4ist in the porta/ -i// be imported from L=A@. ,he /ast fie/d defines the header Site:inder is using to .eep trac. of the user. ,he defau/t va/ue is a/ready popu/ated. $f you have customized the fie/d for your in) sta//ation, enter the custom va/ue here. <hen you are finished, c/ic. )ave.

0 *A-LT -S R ASS1!.AT.1NS
,he Default User Associations /in. has three fie/ds a//o-ing you to /ist 5one per /ine6 communities, ro/es, and user groups that you -ant ne- users to be members of by defau/t. Liferay's defau/t is to have ne- users be members of both the 0sers ro/e and the @o-er 0sers ro/e. ,he @o-er 0sers ro/e used to a//o- users to have their o-n set of pages -here they can add their o-n port/ets, such as b/ogs, mai/, or ca/endar. ,his is no- provided to a// users and can be modified using the %ortal&ext'%ro%erties fi/e. 1ou can no- use the @o-er 0sers ro/e to provide your o-n differentiation bet-een regu/ar users and users to -hom you -ish to give more privi/eges in the porta/, or you can remove it a/) together. $f you have defined other user groups, communities, or ro/es that you -ant ne-/y created users to be members of by defau/t, enter them here. 9or e4amp/e, you may have defined page temp/ates in certain user groups to pre)popu/ate end users' private pages. $f there is a particu/ar configuration that you -ant everyone to have, you may -ant to enter those user groups here.

R S R> 0 !R 0 NT.ALS
,he ne4t /in. is 9eserved Credentials. 1ou can enter screen names and emai/ ad) dresses here that you don't -ant others to use. Liferay -i// then prevent users from AA! G/oba/ Server Settings

Configuration registering -ith these screen names and emai/ addresses. 1ou might use this feature to prevent users from creating $=s that /oo. /i.e administrative $=s or that have re) served -ords in their names.

/A.L 31ST NA/ S


,he ne4t /in. is Mail Host 6ames. 1ou can enter 5one per /ine6 other mai/ host names besides the one you configured on the Genera/ tab. Liferay -i// fai/ over to these host names in the event that the connection to the main one fai/s.
/A.L

N1T.*.!AT.1NS

,here are three tabs under the 1mail 6otifications /in.. ,he )ender tab a//o-s you to set the porta/ administration name and emai/ address. %y defau/t, this is 3oe "loggs and testVliferay'com. 1ou can change it to anything you -ant. ,his name and address -i// appear in the 9rom fie/d in a// emai/ messages sent by the porta/. ,he other t-o tabs 5Account Created 6otification and Password Changed 6otification6 a//o- you to customize the emai/ messages that are sent to users on those t-o events. A /ist of to.ens for inserting certain va/ues 5such as the porta/ 0RL6 is given if you -ish to use those.

.0 NT.*.!AT.1N
,he identification section has severa/ /in.s for addresses, phone numbers, and other information you can configure in your porta/. ,his a//o-s you to set up contact information for the organization that is running the porta/

/.S! LLAN 1-S$ 0.SPLA5 S TT.NGS


,his section a//o-s you to set the defau/t porta/ /anguage and the time zone. 1ou can a/so set the porta/)-ide /ogo -hich appears in the top /eft corner of themes that are configured to disp/ay it. %e carefu/ -hen using this option to choose an image fi/e that fits the space. $f you pic. something that is too big, it -i// mess up the navigation.

/onitorin)
,he ne4t /in. on the /eft side of the Contro/ @ane/ is for monitoring. 0sing this, you can see a// of the /ive sessions in the porta/. 9or performance reasons, this setting is genera//y turned off in production, but if you have it turned on, you can vie- the active sessions here.

Plu)ins !on%i)uration
,he @/ugins Configuration /in. has tabs for each .ind of p/ugin you can insta// in Liferay. 1ou can use these tabs to configure -hat porta/ ro/es have access to the p/u) gins. 9or e4amp/e, if you -anted to /imit the use of the :essage %oards port/et to Iust @o-er 0sers, you cou/d use the Portlets tab here and remove the 0sers ro/e and /eave on/y the @o-er 0sers ro/e in the fie/d. ,o do this, simp/y c/ic. on the port/et you -ant

G/oba/ Server Settings

AA8

Configuration and enter the ro/e names in the fie/d provided. Any ro/es you enter here -i// be ab/e to use this port/et. &ote that this is for basic configuration and security. $f you -ant to disab/e or en) ab/e access to certain port/ets comp/ete/y, this is -here you'd do that. 9or more fine) grained permissions, use the Ro/es section of the Contro/ @ane/ and the Actions Define Permissions button to configure more specific permissions.

Server Administration
,he Server Administration /in. /ets you perform various tas.s re/ating to admin) istration of the overa// porta/ server, as opposed to administering resources in the porta/. C/ic.ing the /in. ma.es this abundant/y c/ear2 you're immediate/y presented -ith a graph sho-ing the resources avai/ab/e in the JB:.

R S1-R! S
,he first tab is ca//ed 9esources. ,his tab contains the aforementioned graph p/us severa/ server -ide actions that an administrator can e4ecute. ,hese are2 >arbage collection) 1ou can send in a reHuest to the JB: to begin the garbage co//ection tas.. Clearing cache$) 1ou can send in a reHuest to the JB: to c/ear a sing/e B: cache, the c/uster cache, or the database cache. :einde() 1ou can send in a reHuest to regenerate a// search inde4es. $f you are not using a So/r search server 5see Chapter + for further information on that6, this -i// impact porta/ performance, so try not to do this e4cept at non)pea. times. >enerate 8hread *u+p) $f you are performance testing, you can generate a thread dump -hich can be e4amined /ater to determine if there are any dead/oc.s and -here they might be.

L1G L

> LS

;ere you can dynamica//y modify the /og /eve/s for any c/ass hierarchy in the porta/. $f you have custom code that you have dep/oyed -hich isn't in the /ist, you can use the Add Category tab to add it. $f you change the /og /eve/ near the top of the c/ass hierarchy 5such as at com'liferay6, a// the c/asses under that hierarchy -i// have their /og /eve/s changed. $f you are testing something specific, it is much better to be as spe) cific as you can -hen you change /og /eve/s, as by modifying them too high in the hierarchy you can generate a /ot more /og messages than you probab/y need.

S5ST / PR1P RT. S


,his tab sho-s an e4haustive /ist of system properties for the JB:, as -e// as many Liferay system properties. ,his information can be used for debugging purposes or to chec. the configuration of the current/y running porta/.

AAC

G/oba/ Server Settings

Configuration

P1RTAL PR1P RT. S


,his tab sho-s an e4haustive /ist of the porta/ properties. ,hese properties can be customized as -i// be seen in the ne4t chapter. $f you need to chec. the current va/ue of a particu/ar property, it can be vie-ed from this screen -ithout having to shut do-n the porta/ or open any properties fi/es.

S3-T01WN
$f you ever need to shut do-n your Liferay @orta/ server -hi/e users are /ogged in, you can use the Shutdo-n tab to inform your /ogged)in users of the impending shutdo-n. 1ou can define the number of minutes unti/ the shutdo-n and a custom message that -i// be disp/ayed. 0sers -i// see your message at the top of their porta/ pages for the duration of time you specified. <hen the time e4pires, a// porta/ pages -i// disp/ay a message say) ing the porta/ has been shut do-n. At this point, the server -i// need to be restarted to restore access.

1P N1**.!
Liferay @orta/ contains a JSR)A'" comp/iant document repository. ,his repository a//o-s users to up/oad documents in many formats into a fo/der structure that they define. ?pen?ffice.org is an open source office suite -hich is norma//y run in graphica/ mode to create documents, but it can be run in KserverL mode. <hen run in server mode, ?pen?ffice.org can be used to convert documents to and from a// of the fi/e types it supports. Liferay's =ocument Library port/et can ma.e use of this feature to automatica//y convert documents on the f/y. 1ou -ou/d use this tab to te// Liferay ho- to connect to your running instance of ?pen?ffice.org. 1ou can insta// ?pen?ffice.org on the same server upon -hich Liferay is running. ?nce you have it insta//ed, you can start ?pen?ffice.org in server mode -ith the fo//o-ing command2
soffice -headless -accept Dsocket,host 35T.4.4.3,port 13447urp7D -nofirststartwi>ard

As you can see, the command above specifies that ?pen?ffice.org -i// run on port (A"", -hich is the defau/t port in the Contro/ @ane/. $f you can use this port, a// you need to do is chec. the 1nabled bo4, and Liferay -i// be integrated -ith ?pen?ffice.org. $f you have something e/se running on this port, find a port that is open and spe) cify it both in the command above and on the Contro/ @ane/'s ?pen?ffice.org config) uration page. <hen you are finished, c/ic. )ave.

Portal .nstances
Liferay @orta/ a//o-s you to run more than one porta/ instance on a sing/e server. =ata for each porta/ instance are .ept separate from every other porta/ instance. A//

G/oba/ Server Settings

AA*

Configuration porta/ data, ho-ever, is .ept in the same database. >ach porta/ instance reHuires its o-n domain name. Liferay -i// direct users to the proper porta/ instance based on this domain name. So before you configure an in) stance, configure its domain name in your net-or. first. <hen you're ready to add an instance, c/ic. the Add button here. 1ou'// be prompted for three fie/ds2 5eb I*) A genera/ convention is to use the domain name for this. $t's a user)gen) erated $= for the instance. ;irtual 2o$t) @ut the domain name you configured in your net-or. here. <hen users are directed to your Liferay server via this domain name, Liferay -i// then be ab/e to send them to the proper porta/ instance. %ail *o+ain) >nter the domain name for the mai/ host for this instance. Liferay -i// use this to send emai/ notifications from the porta/. <hen you are finished fi//ing out the form, c/ic. )ave. &o- navigate to the porta/ using your ne- domain name. 1ou -i// see that you are brought to -hat /oo.s /i.e a c/ean insta// of Liferay. ,his is your ne- porta/ instance -hich can no- be configured any -ay you /i.e.

Plu)ins .nstallation
,he Plugins Installation /in. sho-s a// of the p/ugins that are current/y insta//ed. ,hese are divided into tabs for port/ets, themes, /ayout temp/ates, ;oo. p/ugins, and <eb p/ugins. $f you -ant to insta// a ne- p/ugin, c/ic. the Install More Portlets button. 1ou -i// then be brought to the &lugin In$taller, -here you can bro-se Liferay's re) pository of port/ets or insta// your o-n p/ugins. ,he @/ugin $nsta//er -i// be covered in the ne4t chapter.

Summar&
,his chapter has described the resources in Liferay @orta/ that can be configured to bui/d the site you need to bui/d. <e have seen ho- to navigate Liferay's user inter) face so that you can get any-here you need to in the porta/. <e have a/so /oo.ed at overa// porta/ architecture and ho- you might go about designing your site using Liferay. &e4t, -e -ent in)depth through Liferay's Contro/ @ane/. 0sing the Contro/ @ane/, -e /earned ho- to manage users, organizations, user groups, and ro/es. <e a/so /earned ho- to configure various server settings, such as authentication, L=A@ integ) ration, and sing/e sign)on. <e a/so /earned ho- to associate users by defau/t -ith dif) ferent user groups, communities, and ro/es, and -e sa- ho- to reserve screen names and emai/ addresses so that users cannot register in the porta/ -ith them. &e4t, -e sa- ho- to vie- and configure overa// server settings. <e sa- ho- to vie- the memory current/y being used by the server, as -e// as ho- to initiate garbage co//ection, a thread dump, search engine re)inde4ing, and the c/earing of various caches. <e /earned ho- to debug parts of the porta/ by changing /og /eve/s, and by vie-ing the various properties that are defined in the porta/. AA+ Summary

Configuration 9ina//y, -e /earned ho- to proper/y notify users that the porta/ is about to shut do-n and ho- to enab/e the ?pen?ffice.org integration. ,he abi/ity to run mu/tip/e porta/ instances on one insta//ation of Liferay -as covered, and -e sa- ho- to viethe p/ugins that are current/y insta//ed. A// of this information shou/d he/p to bring you -e// on your -ay to becoming a seasoned Liferay @orta/ Administrator.

Summary

AA'

4. LIFERAY COLLABORATION SUITE

Liferay @orta/ ships -ith a robust suite of co//aboration app/ications -hich you can use to bui/d communities of users for your site. ,hese app/ications are best)of) breed app/ications -ith a// the features you -ou/d e4pect of standa/one versions that are outside a porta/. ,he difference -ith Liferay's co//aboration suite, ho-ever, is that a// of the app/ications share a common /oo. and fee/, security mode/, and architec) ture. And they inherit a// of the strengths of being a part of the Liferay deve/opment p/atform, so you can use them in combination -ith Liferay's user management and Content :anagement features to bui/d a -e//)integrated, feature)rich -eb site. ,his chapter -i// focus on the use of Liferay's co//aboration suite. 1ou -i// /earn ho- to set up and administer2 %/ogs Ca/endars Chat :ai/ :essage %oards <i.is

1ou -i// see ho- a// of these features can -or. together to provide an enhanced e4perience for your users, as -e// as giving you the too/s to he/p bui/d a community that .eeps coming bac..

Sco#es
&e- in Liferay *.! is the concept of )co%es as it app/ies to port/ets instead of ro/es. As -e /earned ear/ier, ro/es can be scoped by the porta/, by a community, or by an or) ganization. ,his means that the ro/e on/y ta.es effect for the scope in -hich it resides.

Liferay Co//aboration Suite 9or e4amp/e, a :essage %oards Administrator ro/e -ith comp/ete access to the :es) sage %oards port/et -ou/d have different permissions based on the Ro/e's scope. $f it's a regu/ar ro/e, members have permission to administer message boards across the porta/. $f it's a community ro/e, members have permission to administer message boards on/y -ithin the community in -hich they are members of the ro/e. $f it's an organization ro/e, members have permission to administer message boards on/y -ith) in the organization in -hich they are members of the ro/e. $n a simi/ar fashion to this, some Liferay port/ets can no- have scopes that go beyond Iust the specific community or organization upon -hich the port/et has been p/aced. 1ou can no- scope them by page. 9irst of a//, -hat do -e mean by the -ord sco%eJ Scopes are another term for a set of data that is iso/ated from another set of data stored in the porta/ database. 9or e4) amp/e, if you p/ace a :essage %oards port/et on t-o different communities, each :es) sage %oard has its o-n set of data. ,hat is ho- there can be t-o, t-enty, or !",""" dif) ferent message boards in the porta/, because each has its o-n sco%e of data. $n previous versions of Liferay, scopes -ere hard)coded to be /imited to organiz) ations and communities. $f you have -hat -e -ou/d ca// a non&instanceable port/et, that's another -ay of saying the port/et is sco%able. 1es, neither of those are rea/ -ords, but they are an attempt to communicate the fact that each instance of the port/et has its o-n data set, and that data set is /imited by a scope that is defined as be/onging to a community or organization. $n Liferay *.!, you can no- set the scope to be for any page. ,his a//o-s you to add any number of these port/ets to a community or organization, and as /ong as they appear on different pages, they -i// have different sets of data. ,his a//o-s you to have more than one message board per community or organization if you -ish. 0n/ess other-ise noted, a// of the port/ets in this chapter support scopes. ,his gives you much more f/e4ibi/ity in ho- you -ant to set up your porta/. %y defau/t, ho-ever, the scope remains the same as it a/-ays has, and is set to be by the com) munity or organization. $f you -ant to change the scope, it on/y ta.es a fe- simp/e steps. A. !. 8. C. *. C/ic. the :enu icon in the port/et -indo- 5the one -ith the three dots6. Se/ect Configuration. Se/ect the )co%e tab. :odify the Scope to be the current page. C/ic. )ave.

,hat's a// it ta.es to change the scope for a particu/ar port/et instance. %y setting the scope to %age, you can add as many of these port/ets to a particu/ar community or organization as you -ant, provided they a// are added to different pages.

A!"

Scopes

Liferay Co//aboration Suite

Illustration ? ! Changing the sco%e for a %ortlet'

Archived Setu#s
Another ne- feature for Liferay *.! is Archived Setups. ,his means that once you configure a port/et, you can save those settings in an KarchiveL that the porta/ can .eep trac. of. $f someone then goes in and changes the settings of a particu/ar port/et, it then becomes easy to revert those changes bac. to the origina/, archived configura) tion. ,o create an archived setup, c/ic. the Configuration option from the menu in the port/et's tit/e bar. $f the current settings of the port/et you are configuring are the ones you -ant to archive, c/ic. the Archived tab. $f not, change and save the settings unti/ you have the port/et configured the -ay you -ant it, and then c/ic. the Archived tab. ,here is on/y one fie/d to fi// out2 a name for your archive. Create a name for your archive and c/ic. )ave. 1ou -i// no- see your archive in the /ist. $f for -hatever reas) on you need to revert the port/et to these archived settings, you can c/ic. Actions 9estore ne4t to the archived setup you -ant to restore. 0n/ess other-ise noted, a// of the port/ets in this chapter support this feature. ,his is particu/ar/y usefu/ for port/ets that have a /ot of configuration options, such as the :essage %oards port/et.

Permissions
A// of Liferay's port/ets support Liferay's robust, fine)grained permissions sys) tem. $f your needs are more basic, the port/ets a/so support the standard JSR)!(+ per) missions -hich define -hether or not a user can see a port/et. ,o configure these per) missions, go to the Configuration menu, and you -i// see a tab ca//ed @ermissions. ,his -i// sho- you a tab/e of Ro/es defined in the porta/. Se/ect -hich ro/es are a//o-ed to see the port/et and -hich ro/es are a//o-ed to configure the port/et, and then c/ic. )ubmit. A// Java standard port/ets support these permissions.

@ermissions

A!A

Liferay Co//aboration Suite

Sharin)
As the concept of the -eb as an app/ication itse/f rather than a number of is/ands of app/ications ta.es ho/d in the mindshare of the $nternet's users, -idgets have be) come very popu/ar no-adays. ,his concept is sometimes referred to as K<eb !."L and is very much enab/ed by -idgets. So -hat is a -idgetJ A -idget is a sma// piece of code that can be inc/uded on any -eb site that provides a piece of functiona/ity, but does not necessari/y have to be hosted by that -eb site. $f you have ever embedded a 1ou,ube video on your o-n -eb site so that users cou/d -atch a video -ithout actu) a//y having to visit http277youtube.com, then you have a/ready used a -idget. Liferay supports using its port/ets as -idgets. 1ou can embed a particu/ar in) stance of a port/et running on your site into another site, such as 9aceboo., to -hich you have access to add content. ,his opens up a -ho/e ne- avenue of e4posure to your -eb site that you -ou/d not other-ise have had. ,o share one of your port/ets as a -idget, go to the Configuration option in the menu in the port/et's tit/e bar. ,hen c/ic. the )haring tab. 0nder this are three tabs.

An& We" Site


Copy and paste the snippet of code into the -eb site to -hich you -ant to add the port/et as a -idget. ,hat's a// you need to do. <hen a user /oads the page on the other -eb site, the code -i// pu// the re/evant port/et from your site and disp/ay it.

*ace"oo'
1ou can add any Liferay port/et as an app/ication on 9aceboo.. ,o do this, you must first get a deve/oper .ey. A /in. for doing this is provided to you in the 9aceboo. tab. 1ou -i// have to create the app/ication on 9aceboo. and get the .ey and canvas page 0RL from 9aceboo.. ?nce you have done this, you can copy and paste their va/) ues into the 9aceboo. tab. 1our port/et -i// no- be avai/ab/e on 9aceboo. as a 9ace) boo. app/ication.

A!!

Sharing

Liferay Co//aboration Suite

*riends

Illustration ?#! LiferaySs forums in (aceboo5

,he fina/ sub)tab in the )haring tab is ca//ed (riends. ,his tab has a sing/e chec. bo4 that a//o-s you to give your friends permission to add the app/ication as a -idget to another -eb site. ,his cou/d be particu/ar/y usefu/ for your b/og or your ca/endar if you -ish to share them.

(lo)s
,he -ord "log is an apostrophe)/ess contraction of the t-o -ords web log. %/ogs -ere first popu/arized by -eb sites such as S/ashdot 5http277s/ashdot.org6 -hich have the format of a running /ist of entries to -hich users cou/d attach comments. ?ver time, more and more sites such as =igg, de/.icio.us, and &e-svine adopted the format, empo-ering users to share their opinions and generating /ive/y discussions. ?ver the course of time, b/ogging sites and app/ications began to appear, such as b/ogger.com, b/ogspot.com. ,ype@ad, <ord@ress, and <eb Ro//er. ,hese app/ications a//o- individuals to run their o-n -eb sites in the same format2 a running /ist of short artic/es to -hich readers -ho are registered -ith the site can attach threaded com) ments. @eop/e -ho run a b/og are ca//ed bloggers, and sometimes they bui/d a -ho/e community of readers -ho are interested in their b/og posts. Additiona//y, there are severa/ famous peop/e -ho run their o-n b/ogs. $t gives peop/e an out/et for se/f)e4) pression -hich they -ou/d not other-ise have, and the ubiHuity and -ide reach of %/ogs A!8

Liferay Co//aboration Suite the $nternet ensures that if you have something important and interesting to say, somebody -i// read it.

Illustration ?2! )lashdot$ one of the first blogs on the Internet' Liferay @orta/ has a port/et ca//ed the -log$ port/et -hich a//o-s you to provide a b/ogging service to users of your -eb site. $n fact, Liferay e4tensive/y uses the %/ogs port/et on http277---./iferay.com to provide emp/oyees -ith b/ogs of their o-n. $n addition to the %/ogs port/et, there is a/so a -log$ Aggregator port/et -hich can ta.e entries from mu/tip/e users' b/ogs and put them a// in one /arger /ist. <e -i// go over ho- to use both of these port/ets to create a b/ogging site for your users.

The (lo)s Portlet


,he %/ogs port/et is avai/ab/e from the Collaboration section of the Add App/ica) tion menu. 1ou -i// notice that it is an $nstanceab/e port/et, meaning that it can on/y be added once to any community or organization. ,his a//o-s you to use the %/ogs port/et to create a shared b/og to bui/d a site /i.e S/ashdot or to create mu/tip/e per) sona/ b/ogs to bui/d a site /i.e http277b/ogger.com. <hat's the differenceJ Adding the %/ogs port/et to a Community or ?rganization page creates a shared b/og for members of the Community or ?rganization. Adding the %/ogs port/et to a user's persona/ space creates a b/og for Iust that user. >ither -ay, the %/ogs port/et -or.s the same.

Illustration ?;! Initial view of the "logs %ortlet' %y defau/t, the %/ogs port/et -i// disp/ay the /atest entry in its entirety. Since -e have Iust added the port/et to a page, -e have no entries, so the port/et -i// be empty. %efore -e start adding entries, -e'// configure the port/et so that it disp/ays entries the -ay -e -ant it to.

A!C

%/ogs

Liferay Co//aboration Suite

!1N*.G-R.NG T3 (L1GS P1RTL T


C/ic. the menu button 5the one -ith three dots on it6, and then c/ic. Configura& tion. 1ou -i// see a page a//o-ing you to configure the various options for the %/ogs port/et2

Illustration ??! "logs Configuration %a(i+u+ Ite+$ to *i$pla ) ,his a//o-s you to choose the tota/ number of b/og entries to disp/ay on the initia/ page. 1ou can choose up to A"" to be disp/ayed. *i$pla St le) Choose bet-een 9u// Content, the Abstract, or Iust the ,it/e. Set) ting this to Abstract causes Liferay to disp/ay on/y the first 8" -ords of your b/og entries, -ith a 9ead More /in. at the bottom of each to a//o- users to read the -ho/e entry if they -ish. #nable :ating$) A//o-s you to enab/e your users to rate your b/og entires from one to five stars #nable Co++ent$) A//o-s readers to comment on your b/og entries. #nable Co++ent :ating$) A//o-s readers to rate the comments -hich are pos) ted to your b/og entries. %a(i+u+ Ite+$ to *i$pla ) Lets you configure the number of entries to appear in your RSS feed. *i$pla St le) Same as the disp/ay sty/e for the -eb, but -ith the RSS feed. %/ogs A!*

Liferay Co//aboration Suite ?or+at) Lets you choose bet-een RSS A.", RSS !.", or Atom formats for your feed. Set the settings the -ay you -ant them and c/ic. )ave' =epending on -hether this is a persona/ b/og or a shared b/og, you may -ant to modify the permissions on the b/og. %y defau/t, the permissions are set up for a per) sona/ b/og, so on/y the o-ner of the community to -hich the port/et has been added -i// be ab/e to add entries. $f you -ant to share a b/og -ith mu/tip/e users, it is easy to do. 9irst, create a ro/e for your b/oggers and add them to the ro/e. &e4t, c/ic. the Per& missions button on the %/ogs port/et. 1ou -i// no- see a /ist of both porta/ and Com) munity 7 ?rganization ro/es, and current/y on/y the o-ner is chec.ed. Chec. off any other ro/e that shou/d have the abi/ity to add b/og entries, and then c/ic. )ave. &o- you're ready to begin adding b/og entries. C/ic. the Add "log 1ntry button. 1ou -i// see the fo//o-ing data entry screen2

Illustration ?B! Adding a "log entry ,here isn't much difference bet-een this screen and any other data entry screen -ithin Liferay @orta/. 1ou get a tit/e, a -ay of schedu/ing -hen the entry is to appear, and a rich editor that a//o-s you to format your entry the -ay you -ant, comp/ete -ith embedded images, videos, and the /i.e. A!+ %/ogs

Liferay Co//aboration Suite &ote a/so that as you type, the entry is automatica//y saved as a draft at periodic interva/s. ,his gives you peace of mind in using the port/et from -ithin your bro-ser, as you -on't /ose your entry in the event of a bro-ser crash or net-or. interruption. 1ou can a/so tag your entries using the same tagging mechanism found every) -here e/se in the porta/. ,he %/ogs port/et a/so supports trac.bac.s. ,hese are specia/ /in.s that /et you or another site .no- if you or if someone e/se /in.ed to a b/og entry. 9or e4amp/e, if you -anted to -rite an entry in your b/og and reference someone e/se's entry, you might put the 0RL to the other entry in the 8rackback$ to Send fie/d. Simi/ar/y, if you -ant others -ho /in. to your b/og to /et you .no- about the /in. via trac.bac.s, /eave the Allo1 Inco+ing 8rackback$ bo4 chec.ed. ,his -i// generate a 0RL that is disp/ayed -ith your b/og entry. ?thers -ho -ant to /in. to your entry can use this 0RL for the /in., and every time the /in. is c/ic.ed on, your Liferay)po-ered site -i// .no- about it and -i// be ab/e to .eep trac. of the c/ic.s. ?nce you have finished your b/og entry, c/ic. Publish. 1ou'// go bac. to the /ist of entries, and you -i// see your entry. ;ere is -hat it /oo.s /i.e -hen the disp/ay sty/e is set to Abstract and the number of entries is set to A"2

Illustration ?F! (irst blog entry added' 1ou can see that in the summary vie-, you don't see the trac.bac. /in., and you on/y see the number of comments -hich have been added. $f you -ere to c/ic. the 9ead More /in., you -ou/d see the entirety of the artic/e, a// of the comments in a threaded vie-, and the trac.bac. /in. -hich others can use to /in. bac. to your b/og entry. Additiona//y, the fu// vie- of a b/og contains convenient /in.s to add b/og entries to popu/ar aggregating sites such as =igg, de/.icio.us, and others. ,his gives your read) ers an easy -ay to submit your b/og entries to these aggregators, potentia//y driving further traffic to your site. As you can see, the %/ogs port/et is a fu//)featured b/ogging app/ication -hich -i// give you and your users the abi/ity to enter the b/ogosphere -ith an app/ication that supports anything a b/ogger needs.

%/ogs

A!'

Liferay Co//aboration Suite

A))re)atin) (lo) ntries


1ou can set up a -ho/e -eb site devoted Iust to b/ogging if you -ish. ,he %/ogs Aggregator port/et a//o-s you to pub/ish entries from mu/tip/e b/oggers on one page, giving further visibi/ity to b/og entries. ,his port/et is a/so very easy and straightfor) -ard to set up. 1ou can add it to a page from the Collaboration category in the Add Ap) p/ication menu in the doc.. $f you c/ic. Configuration from the menu button in the tit/e bar of the port/et, you -i// see the %/ogs Aggregator's configuration page. 9rom here, you can set severa/ configuration options2

Illustration ?G! "logs Aggregator Configuration Selection %ethod) 1ou can se/ect 0sers or Scope here. $f you se/ect 0sers, the %/ogs Aggregator -i// aggregate the entries of every b/ogger on your system. $f you -ant to refine the aggregation, you can se/ect an ?rganization by -hich to fi/ter the users. $f you se/ect Scope, the %/ogs Aggregator -i// contain on/y entries of users -ho are in the current scope. ,his -i//, in essence, /imit the entries to members of the Community or ?rganization upon -hich the %/ogs Aggregator port/et resides. *i$pla St le) Just /i.e the %/ogs port/et, you can se/ect from severa/ different sty/es for disp/aying b/og entries. %a(i+u+ Ite+$ to *i$pla ) Se/ect ma4imum number of entries the port/et -i// disp/ay. #nable :SS Sub$cription) ,he aggregated entries can themse/ves be an RSS feed. Leave this bo4 se/ected if you -ant peop/e to be ab/e to subscribe to your aggreg) ated b/og entries.

A!(

%/ogs

Liferay Co//aboration Suite <hen you have finished setting the options in the port/et, c/ic. )ave. ,hen c/ic. 9eturn to (ull Page. As you -i// see, the %/ogs Aggregator /oo.s very much /i.e the %/ogs port/et, e4) cept that the entries come from more than one author.

!alendar
Liferay's Ca/endar port/et is a comp/ete ca/endaring so/ution. 1ou can schedu/e any number of events of different types, receive a/arms via emai/ or te4t message, im) port and e4port your ca/endar, and much more. Additiona//y, you can import and e4) port the ca/endar to the popu/ar iCa/endar format for use in other app/ications. $n a simi/ar -ay to the %/ogs port/et, you can use the Ca/endar port/et as a shared ca/endar on a community or organization's -eb site, or you can use the Ca/endar port/et as a persona/ ca/endar3or both.

!on%i)urin) the !alendar Portlet

Illustration ?K! 4he Liferay Calendar Portlet

Go to the Configuration option from the menu in the port/et's tit/e bar. 1ou have three tabs there -hich a//o- you to configure three different categories of options2 the K9romL fie/d in event reminder emai/s, the temp/ate for event reminder emai/s, and disp/ay settings for the port/et itse/f.
> NT

*R1/

Setting the >vent 9rom name and emai/ address a//o-s you to define the 9rom2 fie/d in the emai/ messages that you receive from the Ca/endar port/et. ,his can -or. -e// in conIunction -ith mai/ ru/es in your emai/ c/ient that can operate on these messages. %y defau/t, the name is set to Joe %/oggs and the emai/ address is set to test[/iferay.com.
> NT

/.N0 R

/A.L

,his tab /ets you customize the emai/ message that you receive from the port/et -hen you have an event for -hich you have configured a reminder. $t contains the same rich te4t editor that you see every-here e/se in Liferay, and this a//o-s you to format your message so that you -i// be ab/e to easi/y recognize it. Additiona//y, there Ca/endar A!#

Liferay Co//aboration Suite are severa/ variab/es -hich a//o- you to insert runtime va/ues into the message, and these are /isted underneath the te4t editor so that you can use them in the appropri) ate p/ace in your temp/ate. 9or e4amp/e, you might -ant the event start date and time and the event tit/e inc/uded in the emai/ reminder that you receive. $nserting the variab/es that correspond -ith those va/ues into your temp/ate -i// a//o- you to do that.

0.SPLA5 S TT.NGS
=isp/ay Settings for the ca/endar a//o- you to define -hich tab in the ca/endar is the defau/t -hen the port/et is first disp/ayed. %y defau/t, the summary tab is dis) p/ayed, but you may -ant the dai/y, -ee./y, or month/y vie- to be the defau/t. ,here are additiona/ settings for the summary tab2 you can se/ect -hether it has a horizonta/ or vertica/ /ayout, se/ect -hether it sho-s a mini month, or se/ect -heth) er it sho-s today's events.

-sin) the !alendar Portlet


,he Ca/endar port/et genera//y -or.s the -ay you -ou/d e4pect a ca/endar to -or.. $t inherits its interface from the rest of Liferay's port/et /ibrary, so you shou/d find common tas.s in the same p/ace that you find them in other Liferay port/ets. ,o get started, you may -ant to c/ic. the Permissions button. ;ere you can find a /ist of ro/es -ith chec. bo4es denoting -hether the ro/e has the Add 1vent or the 1x& %ort All 1vents permission. %y defau/t, on/y the o-ner has permissions to do these things, -hich means that by defau/t, the Ca/endar port/et is set up to be used in one's persona/ space. ?ut of the bo4, Liferay defau/ts to putting a Ca/endar port/et on a// users' private pages, so this is e4pected. $f you are going to be using the Ca/endar as a shared ca/endar, you may -ant to modify some things here. 9irst, create a porta/, community, or organization ro/e and add the users to -hom you -ish to grant access to the ca/endar to the ro/e. ,hen come bac. to the Ca/) endar port/et and c/ic. the Permissions button. Se/ect chec. the bo4es ne4t to the ro/e5s6 that shou/d have access to one or both of the functions 5Add 1vent or 1x%ort All 1vents6. ,hen c/ic. )ubmit. &o- you are ready to begin using your ca/endar. C/ic. the Add 1vent button. 1ou -i// see a form that a//o-s you to fi// out a// the information for your event. Start *ate<8i+e) ,he date and time the event starts. *uration) ;o- /ong the event -i// /ast. All *a #!ent) Chec. this bo4 to disassociate time from the event and ma.e it /ast a// day. 8i+e Aone Sen$iti!e) Leave this bo4 chec.ed to ma.e sure that the porta/ .eeps trac. of the event regard/ess of time zone. 8itle) ,he tit/e of the event. *e$cription) A description of the event.

A8"

Ca/endar

Liferay Co//aboration Suite 8 pe) Se/ect from a number of pre)configured event types. 1ou can change these in the %ortal&ext'%ro%erties fi/e. :epeat) $f the event repeats on a schedu/e, se/ect the schedu/e. #nd *ate) $f the event repeats on a schedu/e but there is an end to the set of meetings, enter the end date. :e+inder$) Se/ect -hether to send a reminder, ho- /ong before the event to send it, and through -hat medium 5emai/, te4t message, or instant message6 to send it. &ote that this feature is integrated -ith your profi/e on the porta/, so you -i// need to fi// out your mobi/e phone number and 7 or instant messenger $=s in order to use those features. <hen you have finished adding your event, c/ic. )ave. 1ou can vie- ca/endar events by day, -ee., month, year, or in a simp/e /ist.

!hat
Liferay's Chat port/et gives you a convenient -ay of a//o-ing your users to send each other instant messages -hen they are /ogged into your -eb site. $t appears as a bar at the bottom of every page, sho-ing -ho is /ogged on, their statuses, and any chats the /ogged)in user has had open.

Illustration BJ! LiferaySs Chat Portlet ,he Chat port/et is very simp/e to use. ,o change the settings, c/ic. )ettings. ;ere you can set your status, -hether to sho- if you are on/ine, and -hether to p/ay a sound if someone sends you a message -hi/e you have the -indo- or tab in the bac.) ground. ,he port/et sho-s you the number of your friends -ho are on/ine. ,o chat -ith one of them, c/ic. the 0nline (riends /in. and then c/ic. the friend's name. 1ou can then begin chatting -ith him or her. 1ou can have mu/tip/e chats open at a time, and Chat A8A

Liferay Co//aboration Suite even have one or more of them minimized. ,he Chat port/et is distributed -ith the Liferay bund/es, but is not inc/uded as part of the .-ar distribution, as it is a separate p/ugin. $f you insta//ed the Liferay .-ar manua//y on your app/ication server, you can insta// the Chat port/et by going to the Contro/ @ane/, c/ic.ing Plugins Installation, and then c/ic.ing the Install More Portlets button. 9ind the Chat port/et in the /ist, c/ic. on it, and then c/ic. Install.

/ail
Liferay's :ai/ port/et enab/es your users to interact -ith their emai/ using an easy to use, ubiHuitous -eb interface. $f your mai/ system supports the $:A@ protoco/, you can use the :ai/ port/et to integrate your users' mai/ -ith the rest of your -eb site. 1ou can a/so connect the :ai/ port/et to a mai/ account provided by Goog/e. ,he :ai/ port/et is distributed -ith the Liferay bund/es, but is not inc/uded as part of the .-ar distribution, as it is a separate p/ugin. $f you insta//ed the Liferay .-ar manua//y on your app/ication server, you can insta// the :ai/ port/et by going to the Contro/ @ane/, c/ic.ing Plugins Installation, and then c/ic.ing the Install More Portlets button. 9ind the :ai/ port/et in the /ist, c/ic. on it, and then c/ic. Install.

Illustration B ! Liferay Mail Portlet$ with messages blurred out to %rotect the owner of the account' ,o connect the :ai/ port/et -ith an emai/ account, c/ic. the Add a 6ew 1mail Ac& count /in.. 9rom there, you are given a choice bet-een an $:A@ account or a Gmai/ ac) count. Choose the option that you -ish, and fi// out the form that appears. 9or an $:A@ account, these fie/ds are necessary2 A8! :ai/

Liferay Co//aboration Suite #+ail Addre$$) ,he emai/ address -hich receives mai/ for this account. 6$er 3a+e) ,he user name for /ogging into the account. &a$$1ord) ,he pass-ord for /ogging into the account. Inco+ing I%A& Ser!er) ,he host name for your $:A@ 5$nternet :ai/ Access @ro) toco/6 server. Inco+ing &ort) ,he port upon -hich the $:A@ service is running. 6$e Secure Inco+ing Connection) Chec. this bo4 to use an encrypted connec) tion to the server, if your server supports it. 7utgoing S%8& Ser!er) ,he host name of your S:,@ 5Simp/e :ai/ ,ransfer @ro) toco/6 server. 7utgoing &ort) ,he port upon -hich the S:,@ service is running. 6$e Secure 7utgoing Connection) Chec. this bo4 to use an encrypted connec) tion to the server, if your server supports it. 9or a Gmai/ account, a// you need to do is provide your emai/ address and your pass-ord, and the port/et -i// ta.e care of the rest. <hen finished, c/ic. )ave. &e4t, c/ic. Chec5 Aour Mail. 1ou -i// be brought to an interface -hich a//o-s you to read your mai/ and compose ne- messages. ,o read a message, c/ic. on it. ,o compose a ne- message, c/ic. the Com%ose 1mail /in. on the /eft side of the port/et. 1ou -i// be brought to a form -hich a//o-s you to compose an emai/ message using the same rich te4t editor that appears every-here e/se in Liferay. ,he :ai/ port/et is a great -ay to integrate a fami/iar service -ith other co//abor) ation features that Liferay provides.

/essa)e (oards
Liferay's message boards are one of the most -ide/y used co//aboration features provided by the product. ,he app/ication is a state of the art forum app/ication simi/ar to many forums in -hich you may have participated. ,he difference, of course, is that Liferay's message boards can inherit the abi/ities of the Liferay deve/opment p/atform to provide an integrated e4perience that others cannot match. ,here are count/ess -eb sites out there -here it is c/ear/y evident that there is no /in. -hatsoever bet-een the main site and the message boards. $n some cases, users are even reHuired to register t-ice2 once for the main site and once for the mes) sage boards. Sometimes it is three times2 for the site, for the message boards, and for the shopping cart. %y providing a message boards port/et a/ong -ith a// of the other app/ications, Liferay can provide a uniHue, integrated approach to bui/ding your -eb site. A// of the integration -or. is done for you, and you can concentrate on bui/ding out the site that you -ant to bui/d. ,he :essage %oards port/et has a /ot of configuration options, but they are straightfor-ard to use and are the reason -hy this port/et is a fu//)featured forum ap) p/ication for your -eb site. ,o get started, add a :essage %oards port/et to your site. :essage %oards A88

Liferay Co//aboration Suite ?nce it is added, c/ic. the menu icon in the port/et's tit/e bar and c/ic. Configuration.

mail *rom
,he first tab is /abe/ed 1mail (rom. ,his tab a//o-s you to configure the emai/ ad) dress that messages from the :essage %oards port/et come from. %y defau/t, the name is Joe %/oggs and the emai/ address is test[/iferay.com.

/essa)e Added mail


,his tab a//o-s you to customize the emai/ message that users receive -hen a message is added to a topic to -hich they are subscribed. #nabled) 0nchec. the bo4 to disab/e the message added emai/. Sub@ect &refi() >nter a prefi4 that -i// be prepended to the subIect /ine of the emai/. ,his is usua//y done so that users can set up message fi/ters to fi/ter the notific) ations to a specific fo/der in their emai/ c/ients. -od ) >nter anything here that shou/d appear in the body of the emai/. Signature) >nter anything here that shou/d appear as part of the signature of the emai/. %e/o- the fie/ds is a section ca//ed *efinition of 8er+$ -hich defines certain variab/es -hich you can use in the fie/ds above to customize the emai/ message. Some of these variab/es are for the message board category name, the community name, and more.

/essa)e -#dated mail


,he :essage 0pdated >mai/ tab is identica/ to the :essage Added >mai/ tab, e4) cept it defines the emai/ message that users receive -henever a topic is updated.

Thread Priorities
1ou can define custom priorities for message threads. ,hese a//o- administrat) ors to tag certain threads -ith certain priorities in order to high/ight them for users. %y defau/t, three priorities are defined2 0rgent, Stic.y, and Announcement. ,o define a thread priority, enter its name, a 0RL to the image icon that represents it, and a pri) ority number -hich denotes the order in -hich that priority shou/d appear. ,here is a/so a fie/d on this form that a//o-s you to se/ect a /oca/ized /anguage for your priorities. $f you need to do this, you can se/ect the /anguage from the se/ection bo4.

-ser Ran's
0sers can be ran.ed according to the number of messages they have posted. 1ou can set up custom ran.s here. =efau/ts have been provided for you, going from zero messages a// the -ay up to A""".

A8C

:essage %oards

Liferay Co//aboration Suite $n addition to ran.s, you can a/so se/ect -ho is a KmoderatorL by -hat ro/es are he/d. =efau/ts are there for you -hich sho- you ho- to do this2
$oderator community-role*$essage Soards 8dministrator $oderator organi>ation*$essage Soards 8dministrator $oderator organi>ation-role*$essage Soards 8dministrator $oderator regular-role*$essage Soards 8dministrator $oderator user-group*$essage Soards 8dministrator

As you can see, a// you need to do is set the ran., the co//ection type, and the name of the type. $n the e4amp/e above, anyone -ho has a Community Ro/e, an ?r) ganization Ro/e, a regu/ar Ro/e, or is in a user group ca//ed Message "oards Administrat& or, or anyone -ho is the ?rganization ?-ner gets the :oderator ran.. As -ith thread priorities, on this tab you can define -hether your ran.s are /oc) a/ized in a particu/ar /anguage.

RSS
:essage board threads can be pub/ished as RSS feeds. ,his tab a//o-s you to define ho- the feeds are generated. %a(i+u+ Ite+$ to *i$pla ) Se/ect the number of items to disp/ay in the feed. *i$pla St le) Se/ect the sty/e. 1ou can pub/ish the fu// content, an abstract, or Iust the tit/e of a thread. ?or+at) Choose the format among RSS A.", RSS !.", or Atom A." formats.

Anon&mous Postin)
,his tab contains a sing/e chec. bo4. Chec. the bo4 if you -ant to enab/e an) onymous posting to the message boards. 0nchec. the bo4 if users must register on your site before posting to the message boards.

Ratin)s
,his tab a/so contains a sing/e chec. bo4. Chec. the bo4 if you -ant to a//ousers to rate the messages that are posted. 0nchec. the bo4 to disab/e this feature. <hen you have finished setting up the message boards, c/ic. )ave on the tab you are using and then c/ic. 9eturn to (ull Page.

Permissions
,he defau/t page that the :essage %oards port/et disp/ays has t-o buttons on it. C/ic. the one /abe/ed Permissions. ,his a//o-s you to define -hich ro/es have the abi/) ity to add a category of threads or to ban abusive users from the message boards. Se) /ect the ro/es and permissions you -ant to configure and then c/ic. )ubmit.

:essage %oards

A8*

Liferay Co//aboration Suite

Addin) !ate)ories
1ou are no- ready to add categories to your message boards. C/ic. the Add Cat& egory button. >nter a name for the category and a description of the category. At the bottom of the form is a chec. bo4 -hich a//o-s you to enab/e the mai/ing /ist func) tion. ,he mai/ing /ist function -or.s in concert -ith the message notification emai/s. $f a user subscribes to a message board category, he or she -i// get emai/s -hen someone posts messages to that category. >nab/ing the mai/ing /ist function a//o-s those users to simp/y rep/y to the notification messages in their emai/ c/ients, and those rep/ies -i// be posted to the thread automatica//y. ,o enab/e this functiona/ity, you -i// need a mai/ account for the category. ?nce you c/ic. the chec. bo4, a number of other options -i// appear. #+ail Addre$$) >nter the emai/ address of the account that -i// receive the mes) sages. &e4t, there are t-o tabs2 Incoming and 0utgoing. ,hese define the mai/ settings for receiving mai/ and for sending mai/. ,he $ncoming tab has the fo//o-ing options2 &rotocol) Se/ect @?@ or $:A@. Ser!er 3a+e) >nter the host name of the mai/ server you are using. Ser!er &ort) >nter the port on -hich your mai/ service is running. 6$e a Secure 3et1ork Connection) Chec. this bo4 to use an encrypted connec) tion if your server supports it. 6$er 3a+e) ,he /ogin name on the mai/ server. &a$$1ord) ,he pass-ord for the account on the server. :ead Inter!al B%inute$C) Liferay -i// po// the server at this interva/ /oo.ing for ne- messages to post. ,he ?utgoing tab has the fo//o-ing options2 #+ail Addre$$) >nter the emai/ address that messages from this category shou/d come from. $f you -ant your users to be ab/e to rep/y to the categories using emai/, this shou/d be the same address configured on the Incoming tab. 6$e Cu$to+ 7utgoing Ser!er) $f you need to use a different mai/ server than the one that is configured for the porta/, chec. this bo4. $f you chec. the bo4, a number of other options -i// appear. Ser!er 3a+e) >nter the host name of the S:,@ mai/ server you are using. Ser!er &ort) >nter the port on -hich your mai/ service is running. 6$e a Secure 3et1ork Connection) Chec. this bo4 to use an encrypted connec) tion if your server supports it. 6$er 3a+e) >nter the /ogin name on the mai/ server. &a$$1ord) >nter the pass-ord for the account on the mai/ server. A8+ :essage %oards

Liferay Co//aboration Suite <hen finished adding your category, c/ic. )ave. Add as many categories to your message boards as you -ish. &ote that categories can have subcategories. 1ou can add a number of top)/eve/ categories and then c/ic. on each one and add categories under that, to an un/imited /eve/. 9or usabi/ity reasons, you don't -ant to nest your categories too deep, or your users -i// have troub/e finding them. 1ou can a/-ays add more categories as your message boards gro-.

-sin) the /essa)e (oards


0pon seeing Liferay's :essage %oards port/et, your users -i// immediate/y recog) nize that the interface is simi/ar to many other imp/ementations they've seen before. :essage boards are nothing ne- to the $nternet, and many peop/e have been using them for Huite a /ong time. 9or that reason, Liferay's message boards -i// seem very fami/iar to your users. ,hreads can be vie-ed in many -ays. At the top of the port/et is a set of tabs2 Categories$ My Posts$ My )ubscri%tions$ 9ecent Posts$ and for administrative users, )tatist& ics and "anned Users. ,he Categories tab a//o-s users to bro-se the categories for an appropriate p/ace to post a thread. ,he :y @osts tab sho-s a// of the posts for the user that is current/y /ogged in. ,his is a convenient -ay to get bac. to a conversation you had once in order to retrieve some pertinent information. ,he :y Subscriptions tab a//o-s a user to manage thread subscriptions. $f you /ose interest in a particu/ar topic, you may -ant to visit this tab and unsubscribe from a thread. ,he Recent @osts tab sho-s a// posts from a// categories by date, so you can .eep up on a// the most recent discussions in the message boards. 9or administrators, the Statistics tab sho-s the number of categories, the num) ber of posts, and the number of participants in your message boards. $t a/so has a /ist of -ho the top posters to your message boards are. ,he %anned 0sers tab sho-s a// of the users -ho have been banned from posting on the message boards. ,o post a ne- message thread, go to the Categories tab, c/ic. on a category, and then c/ic. on the Post 6ew 4hread button. 1ou -i// see a message editing form. ,he body fie/d on this form is different from that of the other port/ets in Liferay. ,he reas) on for this is to support ""Code, -hich is a standard form of mar.up used in many message board products. %efore %%Code -as invented, many message board products -ou/d a//o- users to enter ;,:L to format their messages. ,his, ho-ever, enab/ed at) tac.ers to insert ma/icious code into the message board. %%Code -as invented to provide users a -ay of formatting their messages -ithout a//o-ing them to enter ;,:L. Simi/ar/y, Liferay supports %%Code in the message boards port/et because the other editor3-hich is used for the Content :anagement System, the %/ogs port/et, and other port/ets3produces ;,:L. ,his is appropriate for those other port/ets, as they are on/y used by privi/eged users, but it is not appropriate for the message boards. %esides this, many users of message boards are fami/iar -ith %%Code and are used to it, and the editor that is provided for Liferay's :essage %oards port/et ma.es it very easy to use. 0sers -ho have :oderator access to the board can modify the priority of mes) sages. 1ou can a/so use the editor to Huote from messages that you are rep/ying to, to :essage %oards A8'

Liferay Co//aboration Suite

Illustration B#! 1diting a message boards %ost' Aou can see the emoticons that are available in the editor' insert emoticons, to add preformatted te4t, and more. :essages that are posted to the message boards are sho-n by defau/t in a threaded vie-, so that rep/ies are attached to the proper parent message. ,his ma.es it easy to fo//o- a/ong -ith conversations. <hen vie-ing a message board thread, users are given severa/ options. At the top right of the thread are three icons, a//o-ing users to vie- threads in a f/at vie-, in a tree vie-, or in a combination vie-. A f/at vie- sho-s a// of the messages in the or) der in -hich they are posted. A tree vie- sho-s a// of the messages in a threaded vie-, so that rep/ies are ne4t to the messages they are rep/ying to. A combination vie- sho-s the threads at the top as subIects on/y, -ith the f/at vie- underneath. <hen vie-ing a thread, users can c/ic. /in.s a//o-ing them to post a ne- thread, subscribe to the thread they are vie-ing, or if they have administrative access, move a thread to another category. Subscribing to a thread causes Liferay to send the user an emai/ -henever a ne- message is posted to the thread. $f you have enab/ed the mai/ing /ist feature for the category in -hich the thread resides, users can simp/y rep/y to these messages in order to post bac. to the thread, -ithout having to visit your site. ,he :essage %oards port/et is a/so high/y integrated -ith Liferay's user manage) ment features. @osts on the message board sho- users' pictures if they have up/oaded one for themse/ves, as -e// as the dates that users created an $= on your site.

A8(

:essage %oards

Liferay Co//aboration Suite

/essa)e (oard Administrative *unctions


,he :essage %oards port/et provides for the day to day admin) istration of the message threads. 1ou may -ish to separate this func) tion out by a ro/e, and then de/eg) ate that ro/e to one or more of your users. ,hat -ou/d free you up to concentrate on other areas of your -eb site. ,o do this, you can create a ro/e ca//ed :essage %oard Admin) istrator. ,his ro/e can be scoped by the porta/, an organization, or a community. $f you have a porta/ scoped ro/e, members of this ro/e -i// be ab/e to administer any :es) sage %oards port/et in the porta/. $f it is a community or organization scoped ro/e, members of this ro/e -i// be ab/e to administer a :essage %oards port/et in on/y the com) munity or organization in -hich they have the ro/e. Go to the Contro/ @ane/ and create this ro/e. ?nce it is created, c/ic. Actions Define Permissions. C/ic. the Portlet Permissions button. %ro-se the /ist unti/ you find the :essage %oards port/et and then c/ic. on it. 1ou -i// then see a screen -hich a//o-s you to config) ure the various permissions on the port/et. Grant the permissions you -ish message board administrators to have and then c/ic. )ave. 1ou can then add users to this ro/e and they -i// inherit the permissions. :essage %oard administrators can perform a// of the functions -e have a/ready presented, inc/uding creating and de/eting categories and posting threads. $n addition to these, a number of other functions are avai/ab/e.

Illustration B2! Message "oards %ermissions'

:essage %oards

A8#

Liferay Co//aboration Suite

/1>.NG T3R A0S


:any times a user -i// post a thread in the -rong category. Administrators may in this case -ant to move a thread to the proper category. ,his is very easy to do. 9irst c/ic. on the thread. $f you have administrative access, there is a /in. at the top of the thread /abe/ed Move 4hread. C/ic. this /in.. 1ou -i// be presented -ith a simp/e form -hich a//o-s you to se/ect a category to -hich to move the thread and a chec. bo4 -hich a//o-s you to post a message e4p/aining -hy the thread -as moved. ,his mes) sage -i// be posted as a rep/y to the thread you are moving. <hen finished, c/ic. the Move 4hread button and the thread -i// be moved.

0 L T.NG T3R A0S


0sers -ith administrative access to the message boards can de/ete threads. Sometimes users begin discussing topics that are inappropriate or -hich revea/ in) formation -hich shou/d not be revea/ed. $n this case, you can simp/y de/ete the thread from the message boards. ,his is easy to do. 9irst, vie- the /ist of threads. &e4t to every thread is an Actions button. C/ic. Actions Delete to de/ete the thread. ,his does not prevent users from re)posting the information, so you may need to be vigi/ant in de/eting threads or consider the ne4t option.

(ANN.NG -S RS
0nfortunate/y, sometimes certain users can become abusive. $f you -ind up -ith a user /i.e this, you can certain/y ma.e attempts to -arn him or her that the behavior he or she is disp/aying is unacceptab/e. $f this does not -or., you can ban the user from posting on the message boards. Again, this is very easy to do. 9ind any post -hich -as -ritten by the abusive user. 0nderneath the user's name 7 profi/e picture is a /in. ca//ed "an this User. C/ic. this /in. to ban the user from the message boards. $f after ta.ing this action the user apo/ogizes and agrees to stop his or her abus) ive behavior, you can choose to reinstate the user. ,o do this, c/ic. the "anned Users tab at the top of the :essage %oards port/et. ,his -i// sho- a /ist of a// banned users. 9ind the user in the /ist and c/ic. the Unban this User /in..

SPL.TT.NG T3R A0S


Sometimes a thread -i// go on for a -hi/e and the discussion comp/ete/y changes into something e/se. $n this case, you can sp/it the thread -here the discussion di) verges and create a -ho/e ne- thread for the ne- topic. Administrative users -i// see a )%lit 4hread /in. on each post. ,o sp/it the thread, c/ic. the /in.. 1ou -i// be brought to a form -hich a//o-s you to add an e4p/anation post to the sp/it thread. C/ic. 05 to sp/it the thread.
0.T.NG

P1STS

Administrative users can edit not on/y their o-n posts, but a/so everyone e/se's. Sometimes users -i// post /in.s to copyrighted materia/ or unsuitab/e pictures. 1ou AC" :essage %oards

Liferay Co//aboration Suite can edit these posts, -hich a//o-s you to redact information that shou/d not be posted or to censor profanity that is not a//o-ed on your message boards.

R/.SS.1NS

@ermissions can be set not on/y on threads, but a/so on individua/ posts. 1ou can choose to /imit a particu/ar conversation or a post to on/y a se/ect group of peop/e. ,o do this, c/ic. the Permissions /in. on the post and then se/ect among the Delete$ Permis& sions$ )ubscribe$ U%date$ and <iew permissions for the particu/ar ro/e to -hich you -ant to grant particu/ar access. ,his function can be used to ma.e it so some privi/eged users can post on a cer) tain thread, but others are a//o-ed to vie- it, or any combination of the above per) missions.

Wi'is
Liferay's <i.i port/et, /i.e the :essage %oards port/et, is a fu//)featured -i.i ap) p/ication -hich has a// of the features you -ou/d e4pect of a state of the art -i.i. Again, though, it has the benefit of being ab/e to ta.e advantage of a// of the features of the Liferay p/atform. As such, it is comp/ete/y integrated -ith Liferay's user man) agement, tagging, and security p/atform. So -hat is a -i.iJ @ut simp/y, a -i.i is an app/ication -hich a//o-s users to co/) /aborate on information. ,his, of course, has many app/ications3the most famous of -hich is <i.ipedia, -hich is a fu// encyc/opedia deve/oped co//aborative/y by users from a// over the -or/d, using a -i.i. Another e4amp/e -ou/d be Liferay's -i.i, -hich is used for co//aborative documentation for the Standard >dition of the product. A -i.i app/ication a//o-s users to create and edit documents and /in. them to each other. ,o accomp/ish this, a specia/ form of mar.up is used -hich is sometimes ca//ed -i.ite4t. 0nfortunate/y, the pro/iferation of many different -i.i app/ications resu/ted in s/ight/y different synta4 for -i.ite4t in the various products, as each ne-i.i tried to focus on ne- features that other -i.is did not have. 9or that reason, a proIect ca//ed <i.iCreo/e -as started. ,his proIect resu/ted in the re/ease of <i.i) Creo/e A." in !""', -hich is an attempt to define a standard -i.i mar.up that a// -i.is can support. Rather than define another -i.ite4t synta4, Liferay's <i.i port/et supports <i.i) Creo/e as its synta4. ,his synta4 is a best)of)breed -i.i synta4 and shou/d be fami/iar for users of other -i.is. ,he port/et provides a handy cheat sheet for the synta4 on the page editing form, -ith a /in. to the fu// documentation if you -ish to use some of <i.iCreo/e's advanced features.

Gettin) Started with the Li%era& Wi'i


,he <i.i port/et -or.s Iust /i.e the other port/ets deve/oped by Liferay. Add the port/et to a page using the Add A%%lication menu and then c/ic. Configuration in the port/et menu in the <i.i port/et's tit/e bar. 1ou shou/d see some options -hich -i// no- /i.e/y be fami/iar to you.

<i.is

ACA

Liferay Co//aboration Suite As -ith the :essage %oards port/et, you can configure messages -hich come from the <i.i port/et. ,he 1mail (rom tab /ets you configure a name and an emai/ ad) dress -hich -i// be popu/ated in the (rom fie/d of emai/ messages sent by the port/et. ,he Page Added 1mail tab /ets you customize the message that is sent to subscribers -hen a ne- <i.i page has been added. ,he Page U%dated 1mail tab /ets you customize the message that is sent to subscribers -hen a <i.i page has been edited. ,he Dis%lay )ettings tab /ets you configure ho- -i.is and -i.i pages are sho-n to users. 1ou can choose -hich -i.is are visib/e by moving them to a Bisib/e or ;idden /ist. 1ou can a/so enab/e comments and comment ratings on -i.i pages. ,his a//o-s users to interact -ith each other concerning edits to the content, enab/ing them to co//aborate on changes. ,he 9)) tab a//o-s you to set up the RSS feed for the <i.i. 1ou can set the ma4) imum number of items to disp/ay and -hether you -ant to disp/ay the fu// content, an abstract, or Iust a tit/e in the feed. ?nce you have set the options the -ay you -ant them, c/ic. )ave and then c/ic. 9eturn to (ull Page.

/ana)in) Wi'is
,he <i.i port/et can contain many -i.is. %y defau/t, it contains on/y one, ca//ed Main. At the top /eft of the port/et -indo- is a sma// icon of a -rench. ,his is the Man& age @i5is button. C/ic. on it. 1ou -i// then be brought to a screen that a//o-s you to add, modify, and de/ete -i.is. 1ou -i// see that the :ain -i.i has a/ready been added for you. At the top of this screen is a Permissions button. C/ic.ing this a//o-s you to define -hat ro/es have access to create -i.is. $f you have created a specific ro/e for creating -i.is, you can c/ic. the bo4 in the Add 6ode co/umn and then c/ic. )ubmit$ and that ro/e -i// have access to create ne- -i.is in this port/et. C/ic.ing the Add @i5i button brings you to a screen -hich a//o-s you to give the -i.i a name and a description. 1ou can a/so set up some defau/t permissions. <hen you create a ne- -i.i, it -i// appear in a /ist at the top of the main page of the port/et. &e4t to each -i.i in the /ist of -i.i nodes is an Actions button. ,his button con) tains severa/ options2 #dit) Lets you edit the name and description of the -i.i. &er+i$$ion$) Lets you define -hat ro/es can add attachments to -i.i pages, add pages to the -i.i, de/ete pages, import pages to the -i.i, set permissions on the -i.i, subscribe to the -i.i, update e4isting pages, and vie- the -i.i. I+port &age$) 1ou can import your data from other -i.is. ,his a//o-s you to mi) grate off of another -i.i -hich you may be using and use the Liferay -i.i instead. 1ou may -ish to do this if you are migrating your site from a set of disparate app/ica) tions 5i.e., a separate forum, a separate -i.i, a separate content management system6 to Liferay, -hich provides a// of these features. Current/y, :edia<i.i is the on/y -i.i that is supported, but others are /i.e/y to be supported in the future. AC! <i.is

Liferay Co//aboration Suite Sub$cribe) A user can subscribe to a -i.i node and any time a page is added or updated, Liferay -i// send an emai/ to the user informing him or her -hat happened. *elete) =e/etes the -i.i node. ,o go bac. to your -i.i, c/ic. on its name in the /ist of -i.is.

Addin) and ditin) Wi'i Pa)es


%y defau/t, there is one page added to your -i.i, ca//ed (rontPage. ,o get started adding data to your -i.i, c/ic. the 1dit /in. at the top right of the port/et. 1ou -i// be brought to a b/an. editing page.

Illustration B;! 1diting the default %age in the wi5i %ortlet 1ou can no- begin to add content to the page. &otice that there is a very con) venient Kcheat sheetL -hich can he/p -ith the -i.i synta4. 1ou can use this synta4 to format your -i.i pages. Consider for e4amp/e the fo//o-ing -i.i document2
Relcome to Nur RikiQ /his is our new wiki, which should allow us to collaborate on documentation. 0eel free to add pages showing people how to do stuff. Selow are links to some sections that have already been added. UUIntroduction VV UUOetting StartedVV UU&onfigurationVV UU)evelopmentVV UUSupportVV

<i.is

AC8

Liferay Co//aboration Suite

UU&ommunityVV

,his -ou/d produce the fo//o-ing -i.i page2

Illustration B?! @i5i text added to front %age ,his adds a simp/e heading, a paragraph of te4t, and severa/ /in.s to the page. &otice that the /in.s are red, instead of the norma/ b/ue co/or in the defau/t Liferay theme. ,his indicates that the page behind that /in. does not yet e4ist, and therefore needs to be created. $f you c/ic. one of those /in.s, you -i// be brought immediate/y to the editing screen you -ere on previous/y -hen you edited the front page, e4cept this time you -i// be creating the page behind the /in. you Iust c/ic.ed. Liferay -i// disp/ay a notice at the top of the page stating that the page does not e4ist yet, and that you are creating it right no-. As you can see, it is very easy to create -i.i pages. A// you have to do is create a /in. from an e4isting page. &ote that at the top of the screen you can se/ect from the Creo/e -i.i format and the ;,:L editor that comes -ith Liferay. <e genera//y recommend that you stic. -ith the Creo/e format, as it a//o-s for a much c/eaner separation of content and code. $f you -ant a// of your users to use the Creo/e format, you can disab/e the ;,:L format using the %ortal&ext'%ro%erties fi/e. See the ne4t chapter for further information on ho- to configure this. At the bottom of the page editing screen, you can se/ect Categories for the artic/e. Categories are a hierarchica/ /ist of headings under -hich you can create -i.i pages. ,his a//o-s you to organize your content in a more forma/ fashion. 1ou can create categories using the Contro/ @ane/, in the 4ags and Categories section.

Pa)e 0etails
<hen vie-ing a page, you can vie- its detai/s by c/ic.ing the Details /in. -hich appears in the top right of the page. ,his a//o-s you to vie- many properties of the page. ,here are severa/ tabs -hich organize a// of the detai/s into convenient categor) ies.

0 TA.LS
,he =etai/s tab sho-s various statistics about the page, and a/so contains a feactions that you can perform on the page. 8itle) =isp/ays the tit/e of the page.

ACC

<i.is

Liferay Co//aboration Suite ?or+at) =isp/ays the format for the page3either Creo/e or ;,:L. Late$t ;er$ion) =isp/ays the /atest version of the page. ,he -i.i port/et automat) ica//y .eeps trac. of page versions -henever a page has been edited. Created - ) =isp/ays the user -ho created the page. La$t Changed - ) =isp/ays the user -ho /ast modified the page. Attach+ent$) =isp/ays the number of attachments to the page. :SS Sub$cription) =isp/ays /in.s -hich a//o- you to subscribe to the page as an RSS feed in three formats2 RSS A.", RSS !.", and Atom A.". #+ail Sub$cription) Contains /in.s a//o-ing you to subscribe to the entire -i.i or Iust to this page. Ad!anced Action$) Contains /in.s a//o-ing you to modify the permissions on the page, ma.e a copy of the page, move 5rename6 the page, or de/ete the page.

3.ST1R5
,his tab sho-s a /ist of a// of the versions of the -i.i page since it -as created. 1ou can revert a page bac. to a previous state and you can a/so compare the differ) ences bet-een versions by se/ecting the versions and then c/ic.ing the Com%are <er& sions button.

.N!1/.NG < 1-TG1.NG L.N2S


,he ne4t t-o tabs are for incoming and outgoing /in.s. ,hese are -i.i /in.s to and from the page. 1ou can use this tab to e4amine ho- this page /in.s to other pages and ho- other pages /in. bac. to this page.

ATTA!3/ NTS
,he /ast tab is for attachments. 1ou can attach any fi/e to the -i.i. ,his is most/y used to attach images to -i.i artic/es -hich can then be referenced in the te4t. Refer) encing them using the proper <i.iCreo/e synta4 renders the image in/ine, -hich is a nice -ay to inc/ude i//ustrations in your -i.i documents.

Navi)atin) in the Wi'i Portlet


At the top of the port/et is a /ist of /in.s -hich a//o- you to navigate around the -i.i. &e4t to the Manage @i5is button is a /ist of -i.is that are current/y created in the port/et. Simp/y c/ic. on the -i.i's name to begin bro-sing that -i.i. After this is a set of navigation /in.s2 ?ront&age) ,a.es you to the main page of the main -i.i. :ecent Change$) ,a.es you to a page -hich sho-s a// of the recent/y updated pages. All &age$) ,a.es you to a f/at, a/phabetica/ /ist of a// pages current/y stored in the

<i.is

AC*

Liferay Co//aboration Suite -i.i. 7rphan &age$) ,his /in. ta.es you to a /ist of pages that have no /in.s to them. ,his can happen if you ta.e a /in. out of a -i.i page in an edit -ithout rea/izing it's the on/y /in. to a certain page. ,his area a//o-s you to revie- -i.i pages that are orphaned in this -ay so that you can re)/in. to them or de/ete them from the -i.i if they are no /onger re/evant. Search) >nter a term here and c/ic. the )earch button to search for items in the -i.i. $f the search term is not found, a /in. -i// be disp/ayed -hich a//o-s you to cre) ate a ne- -i.i page on the topic for -hich you searched.

Summar&
<e have together e4p/ored a// of the port/ets in Liferay's co//aboration suite. 1ou have seen ho- you can configure a// of the port/ets in a simi/ar fashion using a unified user interface. After this, -e -ent over a// of the port/ets in succession. ,he %/ogs and %/ogs Aggregation port/ets can be used to manage shared b/ogs or b/ogs be/onging to a group of peop/e at once. ,hese port/ets have a// the features you -ou/d -ant in a b/og, inc/uding rich te4t editing, /in.s to ne-s aggregators, tags, RSS feeds, and more. ,he Ca/endar port/et /i.e-ise can be used to manage a shared ca/endar or a group ca/endar. $t inc/udes features for events, event notification, repeatab/e events, and import and e4port to and from the standard iCa/endar format. $ntegrating mai/ -ith your porta/ is easy -ith the :ai/ port/et. 1ou can add as many $:A@ or Gmai/ mai/ accounts as you -ish, and this port/et can .eep them a// or) ganized in one p/ace, together -ith the rest of the things Liferay is aggregating for you. =iscussion becomes easy -ith Liferay's :essage %oards port/et. ,his port/et can be used to manage heavi/y traffic.ed discussion forums -ith ease. $t inherits a// of the security features of the Liferay p/atform and inc/udes administrative functions for thread priorities, moving threads, nested discussion categories, banning users, and more. Liferay's <i.i port/et is a state of the art -i.i app/ication that users can ma.e use of to co//aborate on -eb pages. Again, it inherits the strengths of the Liferay p/atform in the form of security, interface, and search. 1ou can use the -i.i port/et to manage severa/ -i.i nodes, or use many -i.i port/ets to manage one node each. Liferay's co//aboration p/atform is a fu// suite of integrated app/ications that em) po-er users to -or. together. 1ou can use them to great effect to enhance your -eb site and to bui/d a vibrant, active community.

AC+

Summary

5. ADVANCED LIFERAY CONFIGURATION

Liferay is configured by a combination of settings -hich are stored in the data) base 5configured by the use of the Contro/ @ane/6 and settings -hich are stored in properties 5te4t6 fi/es. ,hese fi/es can be modified to change Liferay's behavior in cer) tain -ays. ,here are a /arge number of configuration options that can be set, and so this chapter -i// have a -ide)ranging set of topics. <e -i// first go over the main con) figuration fi/e, -hich is stored in the Liferay ;ome directory, and is ca//ed %ortal&ext'& %ro%erties' ,here are a/so some other settings that you may -ant to further customize. ,hey inc/ude changing certain out)of)bo4 defau/ts, security configuration, adding features to Liferay through p/ugin management, and accessing Liferay's -eb services. <e -i// e4amine specifica//y these topics2

Advanced Liferay Configuration! ,his inc/udes the customization of the %ortal& ext'%ro%erties fi/e. Plugin Management! 1ou -i// /earn ho- to insta// @/ugins 5port/ets and themes6 from Liferay's ?fficia/ Repository and Liferay's Community Reposit) ory, as -e// as ho- to create your o-n p/ugin repository. Liferay )0A! Accessing Liferay services remote/y, from outside the porta/, -i// be discussed, as -e// as ho- to configure the security settings for these services.

The portal-ext.properties *ile


Liferay's properties fi/es differ from the configuration fi/es of most other products in that changing the defau/t configuration fi/e is discouraged. $n fact, the fi/e that contains a// of the defau/ts is stored inside of a .Iar fi/e, ma.ing it more difficu/t to customize. <hy is it set up this -ayJ %ecause Liferay uses the concept of overriding the defau/ts in a separate fi/e, rather than going in and customizing the defau/t con) figuration fi/e. 1ou put Iust the settings you -ant to customize in your o-n configura)

Advanced Liferay Configuration tion fi/e, and then the configuration fi/e for your porta/ is unc/uttered and contains on/y the settings you need. ,his ma.es it far easier to determine -hether a particu/ar setting has been customized, and it ma.es the settings more portab/e across different insta//ations of Liferay. ,he defau/t configuration fi/e is ca//ed %ortal'%ro%erties, and it resides inside of the %ortal&im%l'*ar fi/e. ,his .Iar fi/e is /ocated in Liferay @orta/'s @1"&I6(+lib fo/der. ,he fi/e -hich is used to override the configuration is %ortal&ext'%ro%erties. ,his fi/e can be cre) ated in your Liferay ;ome fo/der 5p/ease see Chapter !2 $nitia/ Setup for the /ocation of this fo/der for your app/ication server6. %y defau/t, the fi/e does not e4ist at a//, un/ess you are running an o/der version of Liferay. <hat fo//o-s is a brief description of the options that can be p/aced there, thus overriding the defau/ts from the %ortal'%ro%er& ties fi/e. ,hese are presented in a /ogica/ order, not an a/phabetica/ one, as many prop) erties re/ate to other properties in the system.

PR1P RT. S 1> RR.0


,his property specifies -here to get the overridden properties. %y defau/t, it is %ortal&ext'%ro%erties' 0pdates shou/d not be made on the origina/ fi/e 5 %ortal'%ro%erties6 but on the overridden version of this fi/e. 9urthermore, each porta/ instance can have its o-n overridden property fi/e fo//o-ing the convention porta/)companyid.proper) ties. 9or e4amp/e, one read order may be2 porta/.properties, then porta/)e4t.proper) ties, and then porta/)test.properties. 1xam%les!
include-and-override portal-e<t.properties include-and-override @Gliferay.homeH/portal-e<t.properties

1ou can add additiona/ property fi/es that over-rite the defau/t va/ues by using the external&%ro%erties system property. A common use case is to .eep /egacy property va/ues -hen upgrading to ne-er versions of Liferay. 9or e4amp/e2
java ... -)e<ternal-properties portal-legacy-6.3.properties include-and-override @Ge<ternal-propertiesH

L.* RA5 31/


Specify the Liferay home directory.
liferay.home @Gresource.repositories.rootH

,his property is avai/ab/e for bac.-ards compatibi/ity. @/ease set the property liferay'home instead.
resource.repositories.root @Gdefault.liferay.homeH

P1RTAL !1NT 4T
,his specifies the path of the porta/ serv/et conte4t. ,his is needed because AC( Advanced Liferay Configuration

Advanced Liferay Configuration Iava4.serv/et.Serv/etConte4t does not have access to the conte4t path unti/ Java >> *. Set this property if you dep/oy the porta/ to another path besides root. 1xam%les!
portal.ct< / portal.ct< /portal

R S1-R! R

P1S.T1R. S

R11T

Specifies the defau/t root path for various repository and resource paths. 0nder this path severa/ directories -i// be created for the hot dep/oy feature, JCR, etc. 1xam%les!
resource.repositories.root @Guser.homeH/liferay resource.repositories.root /home/liferay

T !3N1L1G5 !1/PAT.(.L.T5 2.T


Set the fo//o-ing to true to enab/e programmatic configuration to /et the @ort/et ,CE obtain a 0RL for each test. ,his shou/d never be set to true un/ess you are run) ning the ,CE tests.
tck.url false

S!3 /A
Set this to true to automatica//y create tab/es and popu/ate -ith defau/t data if the database is empty.
schema.run.enabled true

Set this to to true to popu/ate -ith the minima/ amount of data. Set this to fa/se to popu/ate -ith a /arger amount of samp/e data.
schema.run.minimal true

-PGRA0
$nput a /ist of comma de/imited c/ass names that imp/ement com./iferay.porta/.upgrade.0pgrade@rocess. ,hese c/asses -i// run on startup to up) grade o/der data to match -ith the /atest version.
upgrade.processes \ com.liferay.portal.upgrade.,pgrade"rocessL=L2L4,\ com.liferay.portal.upgrade.,pgrade"rocessL=L2L3,\ com.liferay.portal.upgrade.,pgrade"rocessL=L2L5,\ com.liferay.portal.upgrade.,pgrade"rocessL=L2L2,\ com.liferay.portal.upgrade.,pgrade"rocessL=L2L=,\ com.liferay.portal.upgrade.,pgrade"rocessL=L2L6,\ com.liferay.portal.upgrade.,pgrade"rocessL=L=L4,\

Advanced Liferay Configuration

AC#

Advanced Liferay Configuration


com.liferay.portal.upgrade.,pgrade"rocessL6L4L4,\ com.liferay.portal.upgrade.,pgrade"rocessL6L3L4,\ com.liferay.portal.upgrade.,pgrade"rocessL6L3L5,\ com.liferay.portal.upgrade.,pgrade"rocessL6L5L4,\ com.liferay.portal.upgrade.,pgrade"rocessL6L5L3,\ com.liferay.portal.upgrade.,pgrade"rocessL6L5L5

> R.*5
$nput a /ist of comma de/imited c/ass names that imp/ement com./iferay.) porta/.integrity.Berify@rocess. ,hese c/asses -i// run on startup to verify and fi4 any integrity prob/ems found in the database.
verify.processes com.liferay.portal.verify.Kerify"rocessSuite

Specify the freHuency for verifying the integrity of the database. Constants in Berify@rocess2 %ublic static final int AL@AA) Q & W %ublic static final int 61<19 Q JW %ublic static final int 06C1 Q W
verify.fre(uency 3

A-T1 0 PL15
$nput a /ist of comma de/imited c/ass names that imp/ement com'liferay'%ortal'5er& nel'de%loy'auto'AutoDe%loyListener. ,hese c/asses are used to process the auto dep/oy) ment of <ARs.
auto.deploy.listeners \ com.liferay.portal.deploy.auto.Mook8uto)eploy!istener,\ com.liferay.portal.deploy.auto.!ayout/emplate8uto)eploy!istener,\ com.liferay.portal.deploy.auto."ortlet8uto)eploy!istener,\ com.liferay.portal.deploy.auto./heme8uto)eploy!istener,\ com.liferay.portal.deploy.auto.Reb8uto)eploy!istener,\ com.liferay.portal.deploy.auto.e<ploded.tomcat.!ayout/emplate.<ploded/omcat!istener,\ com.liferay.portal.deploy.auto.e<ploded.tomcat."ortlet.<ploded/omcat!istener,\ com.liferay.portal.deploy.auto.e<ploded.tomcat./heme.<ploded/omcat!istener

Set the fo//o-ing to true to enab/e auto dep/oy of /ayout temp/ates, port/ets, and themes.
auto.deploy.enabled true

Set the directory to scan for /ayout temp/ates, port/ets, and themes to auto de) p/oy.
auto.deploy.deploy.dir @Gliferay.homeH/deploy

Set the directory -here auto dep/oyed <ARs are copied to. ,he app/ication serv) A*" Advanced Liferay Configuration

Advanced Liferay Configuration er or serv/et container must .no- to /isten on that directory. =ifferent containers have different hot dep/oy paths. 9or e4amp/e, ,omcat /istens on -Ccatalina'baseD+weba%%s -hereas J%oss /istens on -C*boss'server'home'dirD+de& %loy. Set a b/an. directory to automatica//y use the app/ication server specific direct) ory. 1xam%les!
auto.deploy.dest.dir auto.deploy.default.dest.dir ../webapps auto.deploy.geronimo.dest.dir @Gorg.apache.geronimo.base.dirH/deploy auto.deploy.geronimo-jetty.dest.dir @Gorg.apache.geronimo.base.dirH/deploy auto.deploy.geronimo-tomcat.dest.dir @Gorg.apache.geronimo.base.dirH/deploy auto.deploy.glassfish.dest.dir @Gcom.sun.aas.instanceFootH/autodeploy auto.deploy.glassfish-tomcat.dest.dir @Gcom.sun.aas.instanceFootH/autodeploy auto.deploy.jboss-tomcat.dest.dir @Gjboss.server.home.dirH/deploy auto.deploy.jetty.dest.dir @Gjetty.homeH/webapps auto.deploy.jonas-jetty.dest.dir @Gjonas.baseH/webapps/autoload auto.deploy.jonas-tomcat.dest.dir @Gjonas.baseH/webapps/autoload auto.deploy.resin.dest.dir @Gresin.homeH/webapps auto.deploy.tomcat.dest.dir @Gcatalina.baseH/webapps auto.deploy.weblogic.dest.dir @Genv.)N$8I'LMN$.H/autodeploy

Set the interva/ in mi//iseconds on ho- often to scan the directory for changes.
auto.deploy.interval 34444

Set the number of attempts to dep/oy a fi/e before b/ac./isting it.


auto.deploy.blacklist.threshold 34

Set the fo//o-ing to true if dep/oyed <ARs are unpac.ed. Set this to fa/se if your app/ication server has concurrency issues -ith dep/oying /arge <ARs.
auto.deploy.unpack.war true

Set the fo//o-ing to true if you -ant the dep/oyer to rename port/et.4m/ to port) /et)custom.4m/. ,his is on/y needed -hen dep/oying the porta/ on <ebSphere +.A.4 -ith a version before +.A.".' because <ebSphere's port/et container -i// try to pro) cess a port/et at the same time that Liferay is trying to process a port/et. &ote that according to $%:, on versions after +.A.".#, you need to add a conte4t parameter to the -eb.4m/ descriptor in your port/et app/ication ca//ed com'ibm'web& s%here'%ortletcontainer'PortletDe%loyment1nabled and set it to false. ,his parameter causes <ebSphere's bui/t)in port/et container to ignore your port/et app/ication -hen it is dep/oyed, enab/ing Liferay to pic. it up.
auto.deploy.custom.portlet.<ml false

Set this to A if you are using J%oss' @refi4=ep/oymentSorter. ,his -i// append a A in front of your <AR name. 9or e4amp/e, if you are dep/oying a port/et ca//ed test) port/et.-ar, it -i// dep/oy it to Atest)port/et.-ar. J%oss no- .no-s to /oad this port/et after the other <ARs have /oadedU ho-ever, it -i// remove the A from the conte4t path.

Advanced Liferay Configuration

A*A

Advanced Liferay Configuration :odify +server+default+conf+*boss&service'xml. See org'*boss'de%loyment'scanner'PrefixDe%loyment)orter.


auto.deploy.jboss.prefi< 3

Set the path to ,omcat's configuration directory. ,his property is used to auto dep/oy e4p/oded <ARs. ,omcat conte4t D:L fi/es found in the auto dep/oy directory -i// be copied to ,omcat's configuration directory. ,he conte4t D:L fi/e must have a doc%ase attribute that points to a va/id <AR directory.
auto.deploy.tomcat.conf.dir ../conf/&atalina/localhost

Set the path to ,omcat's g/oba/ c/ass /oader. ,his property is on/y used by ,omcat in a standa/one environment.
auto.deploy.tomcat.lib.dir ../common/lib/e<t

Set the 0RLs of Libraries that might be needed to do-n/oad during the auto de) p/oy process
library.download.url.(uercus.jar http*//lportal.svn.sourceforge.net/viewvc/C checkoutC/lportal/portal/trunk/lib/development/(uercus.jar library.download.url.resinutil.jar http*//lportal.svn.sourceforge.net/viewvc/CcheckoutC/lportal/portal /trunk/lib/development/resin-util.jar library.download.url.script-34.jar http*// lportal.svn.sourceforge.net/viewvc/CcheckoutC/lportal/portal/trunk/lib/development/script-34.jar

Set the G/assfish settings to enab/e JSR (( app/ication dep/oyment.


auto.deploy.glassfish-tomcat.jee.deployment.enabled false auto.deploy.glassfish-tomcat.jee.dm.id deployer*Sun*8ppServer**localhost*=1=1 auto.deploy.glassfish-tomcat.jee.dm.user admin auto.deploy.glassfish-tomcat.jee.dm.passwd adminadmin auto.deploy.glassfish-tomcat.jee.df.classname com.sun.enterprise.deployapi.Sun)eployment0actory

31T 0 PL15
$nput a /ist of comma de/imited c/ass names that imp/ement com'liferay'%ortal'5er& nel'de%loy'hot'HotDe%loyListener. ,hese c/asses are used to process the dep/oyment and undep/oyment of <ARs at runtime. &ote2 @/ugin@ac.age;ot=ep/oyListener must a/-ays be first.
hot.deploy.listeners \ com.liferay.portal.deploy.hot."lugin"ackageMot)eploy!istener,\ com.liferay.portal.deploy.hot.MookMot)eploy!istener,\ com.liferay.portal.deploy.hot.!ayout/emplateMot)eploy!istener,\ com.liferay.portal.deploy.hot."ortletMot)eploy!istener,\ com.liferay.portal.deploy.hot./hemeMot)eploy!istener,\ com.liferay.portal.deploy.hot./heme!oaderMot)eploy!istener,\ com.liferay.portal.deploy.hot.$essagingMot)eploy!istener

A*!

Advanced Liferay Configuration

Advanced Liferay Configuration

31T -N0 PL15


Set the fo//o-ing to true to enab/e undep/oying p/ugins.
hot.undeploy.enabled true

Set the undep/oy interva/ in mi//iseconds on ho- /ong to -ait for the undep/oy process to finish.
hot.undeploy.interval 4

Set the fo//o-ing to true to undep/oy a p/ugin before dep/oying a ne- version. ,his property -i// on/y be used if the property hot'unde%loy'enabled is set to true.
hot.undeploy.on.redeploy false

PL-G.N
$nput a /ist of comma de/imited supported p/ugin types.
plugin.types portlet,theme,layout-template,hook,web

$nput a /ist of Liferay p/ugin repositories separated by Rn characters.


plugin.repositories.trusted http*//plugins.liferay.com/official plugin.repositories.untrusted http*//plugins.liferay.com/community

Set this property to fa/se to avoid receiving on screen notifications -hen there is a ne- version of an insta//ed p/ugin.
plugin.notifications.enabled true

$nput a /ist of p/ugin pac.ages ids separated by Rn characters. Administrators -on't be notified -hen a ne- version of these p/ugins are avai/ab/e. ,he ids are of the form group$d7artifact$d. 1ou can a/so end the id -ith an asteris. to match any id that start -ith the previous character.
plugin.notifications.packages.ignored liferay/sample-jsp-portlet

P1RTL T
Set this property for the port/et container imp/ementation to use. ,he defau/t imp/ementation is the interna/ imp/ementation and provides for the best bac.-ards compatibi/ity. ,he Sun imp/ementation provides more features and -i// be the recom) mended imp/ementation in the future.
portlet.container.impl internal #portlet.container.impl sun

Set this property to define the defau/t virtua/ path for a// hot dep/oyed port/ets. See /iferay)port/et)appM*MAM".dtd and the virtua/)path e/ement for more information.
portlet.virtual.path

Set this property to true to va/idate port/et.4m/ against the port/et schema.
portlet.<ml.validate true

Advanced Liferay Configuration

A*8

Advanced Liferay Configuration

P1RTL T !11R0.NAT.1N
Set this property to specify ho- events are distributed. $f the va/ue is ALL/P094& L14), then events -i// be distributed to a// port/ets that are then dep/oyed. $f the va/ue is ALL/P094L14)/06/PA.1, then events -i// be distributed to a// port/ets that are present on a porta/ page.
portlet.event.distribution 8!!L"NF/!./SLN'L"8O.

Set this property to specify the ma4imum number of events that can be gener) ated from port/ets to prevent infinite /oops.
portlet.event.ma<.generation 2

Set this property to specify ho- pub/ic render parameters are distributed. $f the va/ue is ALL/P094L14), then pub/ic render parameters -i// be distributed to a// port) /ets that are the dep/oyed. $f the va/ue is ALL/P094L14)/06/PA.1, then pub/ic render parameters -i// be distributed to a// port/ets that are present on a porta/ page.
portlet.public.render.parameter.distribution 8!!L"NF/!./SLN'L"8O.

T3 /
Set this property to true to /oad the theme's merged CSS fi/es for faster /oading for production. Set this property to fa/se for easier debugging for deve/opment. 1ou can a/so dis) ab/e fast /oading by setting the 0RL parameter css/fast/load to J.
theme.css.fast.load true

Set this property to true to /oad the theme's merged image fi/es for faster /oading for production. Set this property to fa/se for easier debugging for deve/opment. 1ou can a/so dis) ab/e fast /oading by setting the 0RL parameter images/fast/load to J.
theme.images.fast.load true

Set the theme's shorcut icon.


theme.shortcut.icon liferay.ico

Set this property to set the defau/t virtua/ path for a// hot dep/oyed themes. See /iferay)/oo.)and)fee/M*MAM".dtd and the virtua/)path e/ement for more information.
theme.virtual.path

Set this -ith an abso/ute path to specify -here imported theme fi/es from a LAR -i// be stored. ,his path -i// override the fi/e)storage path specified in /iferay)theme) /oader.4m/.
theme.loader.storage.path

,hemes can be imported via LAR fi/es. Set this to true if imported themes shou/d use a ne- theme id on every import. ,his -i// ensure that a copy of the o/d theme is preserved in the theme /oader storage path. ;o-ever, this a/so means that a /ot of themes that are no /onger used remain in the fi/e system. $t is recommended that you A*C Advanced Liferay Configuration

Advanced Liferay Configuration set this to fa/se.


theme.loader.new.theme.id.on.import false

Set this to true to decorate port/ets by defau/t.


theme.portlet.decorate.default true

Set this to true to e4posing sharing icons for port/ets by defau/t.


theme.portlet.sharing.default false

R S1-R! A!T.1NS
$nput a /ist of comma de/imited resource action configurations that -i// be read from the c/ass path.
resource.actions.configs resource-actions/default.<ml

/10 L 3.NTS
$nput a /ist of comma de/imited mode/ hints configurations.
model.hints.configs \ $./8-I'0/portal-model-hints.<ml,\ $./8-I'0/workflow-model-hints.<ml,\ $./8-I'0/e<t-model-hints.<ml,\ $./8-I'0/portlet-model-hints.<ml

R>.!

(-.L0 R

$nput a /ist of common de/imited method prefi4es designated for read)on/y transactions. Service %ui/der -i// use these prefi4es to annotate methods that are to run in read)on/y transactions.
service.builder.persistence.read.only.prefi<es \ contains,\ count,\ find,\ get service.builder.service.read.only.prefi<es \ get,\ search

SPR.NG
$nput a /ist of comma de/imited Spring configurations. ,hese -i// be /oaded after the bean definitions specified in the contextConfigLocation parameter in web'xml.
spring.configs \ $./8-I'0/base-spring.<ml,\

Advanced Liferay Configuration

A**

Advanced Liferay Configuration


\ $./8-I'0/hibernate-spring.<ml,\ $./8-I'0/infrastructure-spring.<ml,\ $./8-I'0/management-spring.<ml,\ \ $./8-I'0/util-spring.<ml,\ \ $./8-I'0/editor-spring.<ml,\ $./8-I'0/jcr-spring.<ml,\ $./8-I'0/messaging-spring.<ml,\ $./8-I'0/scheduler-spring.<ml,\ $./8-I'0/search-spring.<ml,\ \ $./8-I'0/counter-spring.<ml,\ $./8-I'0/document-library-spring.<ml,\ $./8-I'0/lock-spring.<ml,\ $./8-I'0/mail-spring.<ml,\ $./8-I'0/portal-spring.<ml,\ $./8-I'0/portlet-container-spring.<ml,\ $./8-I'0/wsrp-spring.<ml,\ \ $./8-I'0/mirage-spring.<ml,\ \ $./8-I'0/e<t-spring.<ml

Set the bean name for the Liferay data source.


spring.hibernate.data.source liferay)ataSource

Set the bean name for the Liferay session factory.


spring.hibernate.session.factory -liferaySession0actory

3.( RNAT
:any of the fo//o-ing properties shou/d on/y be customized if you have ad) vanced .no-/edge of ;ibernate. ,hey map to various ;ibernate configuration options -hich themse/ves have detai/ed documentation. @/ease see http277---.hibernate.org for more information. $nput a /ist of comma de/imited ;ibernate configurations.
hibernate.configs \ $./8-I'0/counter-hbm.<ml,\ $./8-I'0/mail-hbm.<ml,\ $./8-I'0/portal-hbm.<ml,\ $./8-I'0/e<t-hbm.<ml

Liferay -i// automatica//y detect the ;ibernate dia/ect in com'liferay'%ortal's%ring'& PortalHibernateConfiguration. Set this property to manua//y override the automatica//y detected dia/ect.
#hibernate.dialect

A*+

Advanced Liferay Configuration

Advanced Liferay Configuration Set the ;ibernate connection re/ease mode. 1ou shou/d not modify this un/ess you .no- -hat you're doing. ,he defau/t setting -or.s best for Spring managed transactions. See the method bui/dSession9actory in c/ass org's%ringframewor5'orm'hi& bernate2'Local)ession(actory"ean and search for the phrase \onMc/ose\ to understand ho- this -or.s.
hibernate.connection.releaseLmode onLclose

Set the ;ibernate cache provider. >hcache is recommended in a c/ustered envir) onment. See the property net'sf'ehcache'configuration9esource6ame for detai/ed config) uration. 1xam%les!
hibernate.cache.providerLclass hibernate.cache.providerLclass hibernate.cache.providerLclass #hibernate.cache.providerLclass \ \ \ \ com.liferay.portal.dao.orm.hibernate..h&ache"rovider net.sf.hibernate.cache.Mashtable&ache"rovider com.liferay.portal.dao.orm.hibernate.NS&ache"rovider com.liferay.portal.dao.orm.hibernate./erracotta&ache"rovider

,his property is used if ;ibernate is configured to use >hcache's cache provider.


net.sf.ehcache.configurationFesource'ame /ehcache/hibernate.<ml

0se the fo//o-ing ehcache configuration in a c/ustered environment.


net.sf.ehcache.configurationFesource'ame /ehcache/hibernate-clustered.<ml

0ncomment the fo//o-ing in a ,erracotta environment.


#net.sf.ehcache.configurationFesource'ame /ehcache/hibernate-terracotta.<ml

Set other ;ibernate cache settings.


hibernate.cache.useL(ueryLcache true hibernate.cache.useLsecondLlevelLcache true hibernate.cache.useLminimalLputs true hibernate.cache.useLstructuredLentries false

0se these properties to disab/e ;ibernate caching. ,his may be a performance hitU you may on/y -ant to use these properties for diagnostic purposes.
hibernate.cache.providerLclass org.hibernate.cache.'o&ache"rovider hibernate.cache.useL(ueryLcache false hibernate.cache.useLsecondLlevelLcache false

Set the J=%C batch size to improve performance. $f you're using ?rac/e #i, ho-ever, you must set the batch size to " as a -or.around for a hanging bug in the ?rac/e driver. See L>@)A!8C for more information. 1xam%les!
hibernate.jdbc.batchLsi>e 54 hibernate.jdbc.batchLsi>e 4

Advanced Liferay Configuration

A*'

Advanced Liferay Configuration Set other misce//aneous ;ibernate properties.


hibernate.jdbc.useLscrollableLresultset true hibernate.bytecode.useLreflectionLoptimi>er true hibernate.showLs(l false

0se the c/assic Huery factory unti/ <ebLogic and ;ibernate 8 can get a/ong. See http277---.hibernate.org7!*".htm/]A!8 for more information.
hibernate.(uery.factoryLclass org.hibernate.h(l.classic.&lassic%uery/ranslator0actory

Set this property to true to enab/e ;ibernate cache monitoring. See L@S)!"*+ for more information.
hibernate.generateLstatistics false

J0(!
Set the J&=$ name to /oo.up the J=%C data source. $f none is set, then the porta/ -i// attempt to create the J=%C data source based on the properties prefi4ed -ith *db& c'default.
#jdbc.default.jndi.name jdbc/!iferay"ool

Set the properties used to create the J=%C data source. ,hese properties -i// on/y be read if the property *dbc'default'*ndi'name is not set. ,he defau/t settings are configured for an in)memory database ca//ed ;ypersonic that is not recommended for production use. @/ease change the properties to use an) other database. Add dynamic)data)source)spring.4m/ to the property s%ring'configs to configure the porta/ to use one database c/uster for read ca//s and another database c/uster for -rite ca//s. ,he convention is to create a set of properties prefi4ed -ith *dbc'read' to hand/e read ca//s and another set of properties prefi4ed -ith *dbc'write' to hand/e -rite ca//s. ,hese data sources can a/so be created via J&=$ by setting the properties *dbc'read'*ndi'name and *dbc'write'*ndi'name.

0(8
jdbc.default.driver&lass'ame com.ibm.db5.jcc.)S5)river jdbc.default.url jdbc*db5*lportal jdbc.default.username db5admin jdbc.default.password lportal

0 R(5
jdbc.default.driver&lass'ame org.apache.derby.jdbc..mbedded)river jdbc.default.url jdbc*derby*lportal jdbc.default.username jdbc.default.password

A*(

Advanced Liferay Configuration

Advanced Liferay Configuration

35P

RS1N.!

jdbc.default.driver&lass'ame org.hs(ldb.jdbc)river jdbc.default.url jdbc*hs(ldb*@Gliferay.homeH/data/hs(l/lportal jdbc.default.username sa jdbc.default.password

:ySFL
jdbc.default.driver&lass'ame com.mys(l.jdbc.)river jdbc.default.url jdbc*mys(l*//localhost/lportal+use,nicode true-character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.default.username jdbc.default.password

1RA!L
jdbc.default.driver&lass'ame oracle.jdbc.driver.Nracle)river jdbc.default.url jdbc*oracle*thin*Ilocalhost*3653*<e jdbc.default.username lportal jdbc.default.password lportal

P:SP5
jdbc.default.driver&lass'ame com.p?spy.engine.spy."?Spy)river jdbc.default.url jdbc*mys(l*//localhost/lportal+use,nicode true-character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.default.username jdbc.default.password

P1STGR SCL
jdbc.default.driver&lass'ame org.postgres(l.)river jdbc.default.url jdbc*postgres(l*//localhost*6=25/lportal jdbc.default.username sa jdbc.default.password

SCL S R> R
jdbc.default.driver&lass'ame net.sourceforge.jtds.jdbc.)river jdbc.default.url jdbc*jtds*s(lserver*//localhost/lportal jdbc.default.username sa jdbc.default.password

S5(AS
jdbc.default.driver&lass'ame net.sourceforge.jtds.jdbc.)river jdbc.default.url jdbc*jtds*sybase*//localhost*6444/lportal jdbc.default.username sa jdbc.default.password

Advanced Liferay Configuration

A*#

Advanced Liferay Configuration Liferay uses C8@? by defau/t for connection poo/ing. ,he data source factory can be configured to use J&=$ or another poo/ing imp/ementation by modifying infra) structure)spring.4m/. See http277---.mchange.com7proIects7c8p"7inde4.htm/ con) figuration for a /ist of additiona/ fie/ds used by C8@? for configuring the database con) nection.
jdbc.default.ma<"oolSi>e 64 jdbc.default.min"oolSi>e 6

!-ST1/ SCL
$nput a /ist of comma de/imited custom SFL configurations. Liferay Administrat) ors shou/d never need to customize thisU this is more of an option for deve/opers -ho are customizing Liferay's behavior.
custom.s(l.configs custom-s(l/default.<ml

Some databases do not recognize a &0LL $S &0LL chec.. Set the custom's7l'func& tion'isnull and custom's7l'function'isnotnull properties for your specific database. ,here is no need to manua//y set these properties because com'liferay'%ortal's& %ring'PortalHibernateConfiguration a/ready sets it. ,hese properties are avai/ab/e, ho-ever, so that you can see ho- you can override it for a database that @orta/) ;ibernateConfiguration does not yet .no- ho- to auto configure.

0(8
custom.s(l.function.isnull &8S/A+ 8S K8F&M8FA25?T5BB IS ',!! custom.s(l.function.isnotnull &8S/A+ 8S K8F&M8FA25?T5BB IS 'N/ ',!!

0ATA(AS
Specify any database vendor specific settings.

/5SCL
database.mys(l.engine Inno)S

3!A!3

Set the c/asspath to the /ocation of the >hcache config fi/e for interna/ caches. >dit the fi/e specified in the property ehcache'multi&vm'config'location to enab/e c/ustered cache.
ehcache.single.vm.config.location /ehcache/liferay-single-vm.<ml ehcache.multi.vm.config.location /ehcache/liferay-multi-vm.<ml

0se the fo//o-ing in a c/ustered environment.


ehcache.multi.vm.config.location /ehcache/liferay-multi-vm-clustered.<ml

A+"

Advanced Liferay Configuration

Advanced Liferay Configuration

JA>AS!R.PT
Set a /ist of JavaScript fi/es that -i// be /oaded programmatica//y in +html+com& mon+themes+to%/*s'*s%. ,here are t-o /ists of fi/es specified in the properties *avascri%t'barebone'files and *avascri%t'everything'files. As the name suggests, the barebone /ist is the minimum /ist of JavaScript fi/es re) Huired for most cases. ,he everything /ist inc/udes everything e/se not /isted in the barebone /ist. ,he t-o /ists of fi/es e4ist for performance reasons because unauthenticated users usua//y do not uti/ize a// the JavaScript that is avai/ab/e. See the property *avas& cri%t'barebone'enabled for more information on the /ogic of -hen the barebone /ist is used and -hen the everything /ist is used and ho- to customize that /ogic. ,he /ist of fi/es are a/so merged and pac.ed for further performance improve) ments. See the property *avascri%t'fast'load for more detai/s. Specify the /ist of barebone fi/es. ,he ordering of the JavaScript fi/es is important. Specifica//y, a// JFuery scripts shou/d go first. ,he Liferay scripts are grouped in such a -ay that the first grouping denotes uti/ity scripts that are used by the second and third groups. ,he second grouping de) notes uti/ity c/asses that re/y on the first group, but does not re/y on the second or third group. ,he third grouping denotes modu/es that re/y on the first and second group.
javascript.barebone.files \ \ # # E%uery scripts # \ j(uery/j(uery.js,\ j(uery/cookie.js,\ j(uery/hoverLintent.js,\ j(uery/j5browse.js,\ j(uery/live(uery.js,\ \ # # j%uery ,I 3.6 # \ j(uery/ui.core.js,\ j(uery/ui.datepicker.js,\ j(uery/ui.dialog.js,\ j(uery/ui.draggable.js,\ j(uery/ui.slider.js,\

Advanced Liferay Configuration

A+A

Advanced Liferay Configuration


\ # # j%uery ,I 3.? # \ j(uery/ui.colorLpicker.js,\ \ # # $iscellaneous scripts # \ misc/class.js,\ misc/swfobject.js,\ \ # # !iferay base utility scripts # \ liferay/language.js,\ liferay/liferay.js,\ liferay/util.js,\ \ # # !iferay utility scripts # \ liferay/events.js,\ liferay/popup.js,\ liferay/portal.js,\ liferay/portlet.js,\ liferay/portletLsharing.js,\ liferay/portletLurl.js,\ \ # # !iferay modules # \ liferay/colorLpicker.js,\ liferay/dock.js,\ liferay/menu.js

Specify the /ist of everything fi/es 5everything e/se not a/ready in the /ist of bare) bone fi/es6.
javascript.everything.files \ \ # # E%uery scripts

A+!

Advanced Liferay Configuration

Advanced Liferay Configuration


# \ j(uery/form.js,\ j(uery/jeditable.js,\ j(uery/json.js,\ j(uery/livesearch.js,\ j(uery/media.js,\ j(uery/position.js,\ j(uery/scroll/o.js,\ j(uery/selection.js,\ j(uery/treeview.js,\ \ # # j%uery ,I 3.6 # \ j(uery/ui.accordion.js,\ j(uery/ui.droppable.js,\ j(uery/ui.resi>able.js,\ j(uery/ui.sortable.js,\ j(uery/ui.tabs.js,\ #j(uery/ui.selectable.js,\ \ # # j%uery ,I 3.? # \ j(uery/ui.autocomplete.js,\ j(uery/ui.tree.js,\ \ # # j%uery ,I 3.6 .ffects library # \ #j(uery/effects.core.js,\ #j(uery/effects.blind.js,\ #j(uery/effects.bounce.js,\ #j(uery/effects.clip.js,\ #j(uery/effects.drop.js,\ #j(uery/effects.e<plode.js,\ #j(uery/effects.fold.js,\ #j(uery/effects.highlight.js,\ #j(uery/effects.pulsate.js,\ #j(uery/effects.scale.js,\ #j(uery/effects.shake.js,\ #j(uery/effects.slide.js,\ #j(uery/effects.transfer.js,\ \

Advanced Liferay Configuration

A+8

Advanced Liferay Configuration


# # !iferay base utility scripts # \ liferay/layout.js,\ liferay/observable.js,\ \ # # !iferay modules # \ liferay/autoLfields.js,\ liferay/dynamicLselect.js,\ liferay/layoutLconfiguration.js,\ liferay/layoutLe<porter.js,\ liferay/notice.js,\ liferay/navigation.js,\ liferay/panel.js,\ liferay/panelLfloating.js,\ liferay/searchLcontainer.js,\ liferay/session.js,\ liferay/tagsLcategoriesLselector.js,\ liferay/tagsLentriesLselector.js,\ liferay/undoLmanager.js,\ liferay/upload.js

Set this property to fa/se to a/-ays /oad JavaScript fi/es /isted in the property *avascri%t'everything'files. Set this to true to sometimes /oad *avascri%t'barebone'files and sometimes /oad *avascri%t'everything'files. ,he defau/t /ogic is coded in com'liferay'%ortal'events')ervicePreAction in such a -ay that unauthenticated users get the /ist of barebone JavaScript fi/es -hereas authentic) ated users get both the /ist of barebone JavaScript fi/es and the /ist of everything JavaScript fi/es.
javascript.barebone.enabled true

Set this property to true to /oad the pac.ed version of fi/es /isted in the proper) ties *avascri%t'barebone'files or *avascri%t'everything'files. Set this property to fa/se for easier debugging for deve/opment. 1ou can a/so dis) ab/e fast /oading by setting the 0RL parameter *s/fast/load to J.
javascript.fast.load true

Set the fo//o-ing to true to enab/e the disp/ay of JavaScript /ogging.


javascript.log.enabled false

SCL 0ATA
Set the defau/t SFL $=s for common obIects.

A+C

Advanced Liferay Configuration

Advanced Liferay Configuration


s(l.data.com.liferay.portal.model.&ountry.country.id 3P s(l.data.com.liferay.portal.model.Fegion.region.id 6 s(l.data.com.liferay.portal.model.!ist/ype.account.address 34444 s(l.data.com.liferay.portal.model.!ist/ype.account.email.address 3444= s(l.data.com.liferay.portal.model.!ist/ype.contact.email.address 33442 s(l.data.com.liferay.portal.model.!ist/ype.organi>ation.status 3543T

!1/PAN5
,his sets the defau/t -eb id. ?mni admin users must be/ong to the company -ith this -eb id.
company.default.web.id liferay.com

,his sets the defau/t home 0RL of the porta/.


company.default.home.url /web/guest

,he porta/ can authenticate users based on their emai/ address, screen name, or user id.
company.security.auth.type email8ddress company.security.auth.type screen'ame company.security.auth.type userId

Set this to true to ensure users /ogin -ith https.


company.security.auth.re(uires.https false

Set the fo//o-ing to true to a//o- users to se/ect the remember me feature to auto) matica//y /ogin to the porta/.
company.security.auto.login true

Set the fo//o-ing to the ma4imum age 5in number of seconds6 of the bro-ser coo.ie that enab/es the remember me feature. A va/ue of 8A*8+""" signifies a /ifespan of one year. A va/ue of )A signifies a /ifespan of a bro-ser session. Rather than setting this to ", set the property com%any'security'auto'login to fa/se to disab/e the remember me feature.
company.security.auto.login.ma<.age 2362?444

Set the fo//o-ing to true to a//o- users to as. the porta/ to send them their pass) -ord.
company.security.send.password true

Set the fo//o-ing to true to a//o- strangers to create accounts and register them) se/ves on the porta/.
company.security.strangers true

>nter a friend/y 0RL of a page that -i// be used to create ne- accounts -henever the user c/ic.s the \create account\ /in. in the /ogin port/et. ,his a//o-s providing custom port/ets to create accounts. %y defau/t, the porta/'s create account -i// be used.
#company.security.strangers.url /createLaccount

Advanced Liferay Configuration

A+*

Advanced Liferay Configuration Set the fo//o-ing to true if strangers can create accounts -ith emai/ addresses that match the company mai/ suffi4. ,his property is not used un/ess com%any'secur& ity'strangers is a/so set to true.
company.security.strangers.with.m< true

Set the fo//o-ing to true if strangers -ho create accounts need to be verified via emai/.
company.security.strangers.verify false

Set the fo//o-ing to true to a//o- community administrators to use their o-n /ogo instead of the enterprise /ogo.
company.security.community.logo true

$nput a /ist of sections that -i// be inc/uded as part of the company settings form.
company.settings.form.configuration general,authentication,default-user-associations,reserved-credentials,mail-host-names,email-notifications company.settings.form.identification addresses,phone-numbers,additionalemail-addresses,websites company.settings.form.miscellaneous display-settings

-S RS
Set the fo//o-ing to fa/se if users cannot be de/eted.
users.delete true

Set the fo//o-ing to true to a/-ays autogenerate user screen names even if the user gives a specific user screen name.
users.screen.name.always.autogenerate false

$nput a c/ass name that e4tends com'liferay'%ortal'security'auth')creen6ame.enerat& or. ,his c/ass -i// be ca//ed to generate user screen names.
users.screen.name.generator com.liferay.portal.security.auth.Screen'ameOenerator

$nput a c/ass name that e4tends com'liferay'%ortal'security'auth')creen6ame<alidat& or. ,his c/ass -i// be ca//ed to va/idate user ids. 1xam%les!
users.screen.name.validator com.liferay.portal.security.auth.Screen'ameKalidator users.screen.name.validator com.liferay.portal.security.auth.!iberalScreen'ameKalidator

Set this to fa/se if you -ant to be ab/e to create users -ithout an emai/ address. &ote that not reHuiring an emai/ address disab/es some features that depend on an emai/ address.
users.email.address.re(uired true

Set the ma4imum fi/e size for user portraits. A va/ue of " for the ma4imum fi/e size can be used to indicate un/imited fi/e size. ;o-ever, the ma4imum fi/e size a/) /o-ed is set in property com'liferay'%ortal'u%load'U%load)ervlet9e7uestIm%l'max'siLe A++ Advanced Liferay Configuration

Advanced Liferay Configuration found in system.properties.


users.image.ma<.si>e 24T544

Set this to true to record /ast /ogin information for a user.


users.update.last.login true

$nput a /ist of sections that -i// be inc/uded as part of the user form -hen adding a user.
users.form.add.main details,organi>ations users.form.add.identification users.form.add.miscellaneous

$nput a /ist of sections that -i// be inc/uded as part of the user form -hen updat) ing a user.
users.form.update.main details,password,organi>ations,communities,usergroups,roles,categori>ation users.form.update.identification addresses,phone-numbers,additional-emailaddresses,websites,instant-messenger,social-network,sms,open-id users.form.update.miscellaneous announcements,display-settings,comments,custom-attributes

Set this to true to enab/e reminder Hueries that are used to he/p reset a user's pass-ord.
users.reminder.(ueries.enabled true users.reminder.(ueries.custom.(uestion.enabled true

$nput a /ist of Huestions used for reminder Hueries.


users.reminder.(ueries.(uestions what-is-your-primary-fre(uent-flyernumber,what-is-your-library-card-number,what-was-your-first-phonenumber,what-was-your-first-teacherWs-name,what-is-your-fatherWs-middle-name

GR1-PS AN0 R1L S


$nput a /ist of comma de/imited system group names that -i// e4ist in addition to the standard system groups. <hen the server starts, the porta/ chec.s to ensure a// system groups e4ist. Any missing system group -i// be created by the porta/.
system.groups

$nput a /ist of comma de/imited system ro/e names that -i// e4ist in addition to the standard system ro/es. <hen the server starts, the porta/ chec.s to ensure a// sys) tem ro/es e4ist. Any missing system ro/e -i// be created by the porta/. ,he standard system ro/es are2 Administrator, Guest, @o-er 0ser, and 0ser. ,hese ro/es cannot be removed or renamed.
system.roles

Set the description of the Administrator system ro/e.


system.role.8dministrator.description 8dministrators are super users who can do anything.

Set the description of the Guest system ro/e. Advanced Liferay Configuration A+'

Advanced Liferay Configuration


system.role.Ouest.description ,nauthenticated users always have this role.

Set the description of the ?-ner system ro/e.


system.role.Nwner.description /his is an implied role with respect to the objects users create.

Set the description of the @o-er 0ser system ro/e.


system.role."ower.,ser.description "ower ,sers have their own public and private pages.

Set the description of the 0ser system ro/e.


system.role.,ser.description 8uthenticated users should be assigned this role.

$nput a /ist of comma de/imited system community ro/e names that -i// e4ist in addition to the standard system community ro/es. <hen the server starts, the porta/ chec.s to ensure a// system community ro/es e4ist. Any missing system community ro/e -i// be created by the porta/. ,he standard system community ro/es are2 Community Administrator, Com) munity :ember, and Community ?-ner. ,hese ro/es cannot be removed or renamed.
system.community.roles

Set the description of the Community Administrator system community ro/e.


system.community.role.&ommunity.8dministrator.description &ommunity 8dministrators are super users of their community but cannot make other users into &ommunity 8dministrators.

Set the description of the Community :ember system community ro/e.


system.community.role.&ommunity.$ember.description 8ll users who belong to a community have this role within that community.

Set the description of the Community ?-ner system community ro/e.


system.community.role.&ommunity.Nwner.description &ommunity Nwners are super users of their community and can assign community roles to users.

$nput a /ist of comma de/imited system organization ro/e names that -i// e4ist in addition to the standard system organization ro/es. <hen the server starts, the porta/ chec.s to ensure a// system organization ro/es e4ist. Any missing system organization ro/e -i// be created by the porta/. ,he standard system organization ro/es are2 ?rganization Administrator, ?rgan) ization :ember, and ?rganization ?-ner. ,hese ro/es cannot be removed or re) named.
system.organi>ation.roles

Set the description of the ?rganization Administrator system organization ro/e.


System.organi>ation.role.Nrgani>ation.8dministrator.description Nrgani>ation 8dministrators are super users of their organi>ation but cannot make other users into Nrgani>ation 8dministrators.

Set the description of the ?rganization :ember system organization ro/e. A+( Advanced Liferay Configuration

Advanced Liferay Configuration


system.organi>ation.role.Nrgani>ation.$ember.description 8ll users who belong to a organi>ation have this role within that organi>ation.

Set the description of the ?rganization ?-ner system organization ro/e.


system.organi>ation.role.Nrgani>ation.Nwner.description Nrgani>ation Nwners are super users of their organi>ation and can assign organi>ation roles to users.

?mni admin users can administer the porta/'s core functiona/ity2 gc, shutdo-n, etc. ?mni admin users must be/ong to the defau/t company. :u/tip/e porta/ instances might be dep/oyed on one app/ication server, and not a// of the administrators shou/d have access to this core functiona/ity. $nput the ids of users -ho are omniadmin users. Leave this fie/d b/an. if users -ho be/ong to the right company and have the Ad) ministrator ro/e are a//o-ed to administer the porta/'s core functiona/ity.
omniadmin.users

Set the fo//o-ing to true if a// users are reHuired to agree to the terms of use.
terms.of.use.re(uired true

Specify the group id and the artic/e id of the <eb Content artic/e that -i// be dis) p/ayed as the terms of use. ,he defau/t te4t -i// be used if no <eb Content artic/e is specified.
terms.of.use.journal.article.group.id terms.of.use.journal.article.id

Specify subtypes of ro/es if you -ant to be ab/e to search for ro/es using your cus) tom criteria.
roles.community.subtypes roles.organi>ation.subtypes roles.regular.subtypes

1RGAN.DAT.1NS
Specify the names of your organization5s6. 9or e4amp/e, you cou/d use ,eams, C/ubs, @arishes, or anything -hich describes your hierarchica/ structure.
organi>ations.types regular-organi>ation,location

Specify -hich organizations can be at the top of the hierarchy.


organi>ations.rootableUregular-organi>ationV true

Specify -hich organizations can be chi/dren.


organi>ations.children.typesUregular-organi>ationV regular-organi>ation,location

Set this to true if organizations can have an associated country.


organi>ations.country.enabledUregular-organi>ationV false

Set this to true if organizations must have an associated country.

Advanced Liferay Configuration

A+#

Advanced Liferay Configuration


organi>ations.country.re(uiredUregular-organi>ationV false

%y defau/t, Locations cannot be at the top of the hierarchy, because they cannot have chi/dren. 1ou must specify the fo//o-ing properties for each organization type you create. 1xam%le!
organi>ations.rootableUlocationV false #organi>ations.children.typesUlocationV organi>ations.country.enabledUlocationV true organi>ations.country.re(uiredUlocationV true

$nput a /ist of sections that -i// be inc/uded as part of the organization form -hen adding an organization.
organi>ations.form.add.main details organi>ations.form.add.identification organi>ations.form.add.miscellaneous

$nput a /ist of sections that -i// be inc/uded as part of the organization form -hen updating an organization.
organi>ations.form.update.main details organi>ations.form.update.identification addresses,phone-numbers,additionalemail-addresses,websites,services organi>ations.form.update.miscellaneous comments,reminder-(ueries,custom-attributes

Set this property to true if you -ant any administrator that creates an organiza) tion to be automatica//y assigned to that organization.
organi>ations.assignment.auto false

Set this property to fa/se if you -ant any administrator of an organization to be ab/e to assign any user to that organization. %y defau/t, he -i// on/y be ab/e to assign the users of the organizations and suborganizations that he can manage.
organi>ations.assignment.strict true

Set this property to true if you -ant users to on/y be members of the organiza) tions to -hich they are assigned e4p/icit/y. %y defau/t they -i// a/so become imp/icit members of the ancestors of those organizations. for e4amp/e if a user be/ongs to Liferay Spain he -i// imp/icit/y be a member of the ancestors Liferay >urope and Liferay G/oba/ and -i// be ab/e to access their private pages.
organi>ations.membership.strict false

LANG-AG S AN0 T./ D1N S


Specify the avai/ab/e /oca/es. :essages corresponding to a specific /anguage are specified in properties fi/es -ith fi/e names matching that of content+Language/H'%ro%& erties. ,hese va/ues can a/so be overridden in properties fi/es -ith fi/e names match) ing that of content+Language&ext/H'%ro%erties. 0se a comma to separate each entry. A// /oca/es must use 0,9)( encoding.

A'"

Advanced Liferay Configuration

Advanced Liferay Configuration See the fo//o-ing /in.s to specify /anguage and country codes2 http277ftp.ics.uci.edu7pub7ietf7http7re/ated7iso+8#.t4t http277userpage.chemie.fu)ber/in.de7diverse7doc7$S?M8A++.htm/
locales arLS8,caL8),caL.S,>hL&',>hL/R,csL&X,nlL'!,enL,S,fiL0I,frL0F,deL).,el LOF,huLM,,itLI/,jaLE",koLYF,nbL'N,faLIF,plL"!,ptLSF,ptL"/,ruLF,,esL.S,svLS., trL/F,viLK'

Set the fo//o-ing to true if unauthenticated users get their preferred /anguage from the Accept)Language header. Set the fo//o-ing to fa/se if unauthenticated users get their preferred /anguage from their company.
locale.default.re(uest false

Specify the avai/ab/e time zones. ,he specified ids must match those from the c/ass *ava'util'4imeXone.
time.>ones \ "acific/$idway,\ "acific/Monolulu,\ 8merica/8nchorage,\ 8merica/!osL8ngeles,\ 8merica/)enver,\ 8merica/&hicago,\ 8merica/'ewLZork,\ 8merica/"uertoLFico,\ 8merica/StLEohns,\ 8merica/SaoL"aulo,\ 8merica/'oronha,\ 8tlantic/8>ores,\ ,/&,\ .urope/!isbon,\ .urope/"aris,\ .urope/Istanbul,\ 8sia/Eerusalem,\ 8sia/Saghdad,\ 8sia//ehran,\ 8sia/)ubai,\ 8sia/Yabul,\ 8sia/Yarachi,\ 8sia/&alcutta,\ 8sia/Yatmandu,\ 8sia/)haka,\ 8sia/Fangoon,\ 8sia/Saigon,\ 8sia/Shanghai,\ 8sia//okyo,\ 8sia/Seoul,\ 8ustralia/)arwin,\ 8ustralia/Sydney,\ "acific/Ouadalcanal,\

Advanced Liferay Configuration

A'A

Advanced Liferay Configuration


"acific/8uckland,\ "acific/.nderbury,\ "acific/Yiritimati

L112 AN0 *

Set the fo//o-ing to fa/se if the system does not a//o- users to modify the /oo. and fee/.
look.and.feel.modifiable true

Set the defau/t /ayout temp/ate id.


default.layout.template.id 5LcolumnsLii

Set the defau/t theme id for regu/ar themes.


default.regular.theme.id classic

Set the defau/t co/or scheme id for regu/ar themes.


default.regular.color.scheme.id 43

Set the defau/t theme id for -ap themes.


default.wap.theme.id mobile

Set the defau/t co/or scheme id for -ap themes.


default.wap.color.scheme.id 43

Set the fo//o-ing to true if you -ant a change in the theme se/ection of the pub/ic or private group to automatica//y be app/ied to the other 5i.e. if pub/ic and private group themes shou/d a/-ays be the same6.
theme.sync.on.group false

R C- ST
@ort/ets that have been configured to use private reHuest attributes in liferay& %ortlet'xml may sti// -ant to share some reHuest attributes. ,his property a//o-s you to configure -hich reHuest attributes -i// be shared. Set a comma de/imited /ist of attribute names that -i// be shared -hen the at) tribute name starts -ith one of the specified attribute names. 9or e4amp/e, if you set the va/ue to hello/$world/, then a// attribute names that start -ith hello/ or world/ -i// be shared.
re(uest.shared.attributes !I0.F8ZLSM8F.)L

SS.1N

Specify the number of minutes before a session e4pires. ,his va/ue is a/-ays overridden by the va/ue set in web'xml.
session.timeout 24

A'!

Advanced Liferay Configuration

Advanced Liferay Configuration Specify the number of minutes before a -arning is sent to the user informing the user of the session e4piration. Specify " to disab/e any -arnings.
session.timeout.warning 3

Set the auto)e4tend mode to true to avoid having to as. the user -hether to e4) tend the session or not. $nstead it -i// be automatica//y e4tended. ,he purpose of this mode is to .eep the session open as /ong as the user bro-ser is open and -ith a porta/ page /oaded. $t is recommended to use this setting a/ong -ith a sma//er session'timeout, such as * minutes for better performance.
session.timeout.auto.e<tend false

Set this to true if the user is redirected to the defau/t page -hen the session e4) pires.
session.timeout.redirect.on.e<pire false

@ort/ets that have been configured to use private session attributes in liferay& %ortlet'xml may sti// -ant to share some session attributes. ,his property a//o-s you to configure -hich session attributes -i// be shared. Set a comma de/imited /ist of attrib) ute names that -i// be shared -hen the attribute name starts -ith one of the specified attribute names. 9or e4amp/e, if you set the va/ue to hello/$world/, then a// attribute names that start -ith hello/ or world/ -i// be shared. &ote that this property is used to specify the sharing of session attributes from the porta/ to the port/et. ,his is not used to specify session sharing bet-een port/et <ARs or from the port/et to the porta/.
session.shared.attributes org.apache.struts.action.!N&8!.,&N$"8'ZL,,S.FL,!I0 .F8ZLSM8F.)L

Set this to fa/se to disab/e a// persistent coo.ies. 9eatures /i.e automatica//y /og) ging in -i// not -or..
session.enable.persistent.cookies true

,he /ogin process sets severa/ coo.ies if persistent coo.ies are enab/ed. Set this property to set the domain of those coo.ies.
session.cookie.domain

Set the fo//o-ing to true to inva/idate the session -hen a user /ogs into the porta/. ,his he/ps prevents phishing. Set this to fa/se if you need the guest user and the authenticated user to have the same session.
session.enable.phishing.protection true

Set the fo//o-ing to true to test -hether users have coo.ie support before a//o-) ing them to sign in. ,his test -i// a/-ays fai/ if tc5'url is set to true because that prop) erty disab/es session coo.ies.
session.test.cookie.support true

Set the fo//o-ing to true to disab/e sessions. =oing this -i// use coo.ies to re) member the user across reHuests. ,his is usefu/ if you -ant to sca/e very /arge sites -here the user may be sent to a different server for each reHuest. ,he dra-bac. to this approach is that you must not re/y on the A@$ for sessions provided by the serv/et

Advanced Liferay Configuration

A'8

Advanced Liferay Configuration and port/et specs. ,his feature is on/y avai/ab/e for ,omcat and reHuires that you set ,omcat's :an) ager c/ass to com'liferay'su%%ort'tomcat'session')essionLessManager"ase.
session.disabled false

$nput a /ist of comma de/imited c/ass names that e4tend com'liferay'%ortal'strut& s')essionAction. ,hese c/asses -i// run at the specified event.
# # Servlet session create event # servlet.session.create.events com.liferay.portal.events.Session&reate8ction # # Servlet session destroy event # servlet.session.destroy.events com.liferay.portal.events.Session)estroy8ction

Set the fo//o-ing to true to trac. user c/ic.s in memory for the duration of a user) 's session. Setting this to true a//o-s you to vie- a// /ive sessions in the Admin port/et.
session.tracker.memory.enabled true

Set the fo//o-ing to true to trac. user c/ic.s in the database after a user's session is inva/idated. Setting this to true a//o-s you to generate usage reports from the data) base. 0se this cautious/y because this -i// store a /ot of usage data.
session.tracker.persistence.enabled false

Set the fo//o-ing to true to convert the trac.ed paths to friend/y 0RLs.
session.tracker.friendly.paths.enabled false

>nter a /ist of comma de/imited paths that shou/d not be trac.ed.


session.tracker.ignore.paths \ /portal/renderLportlet,\ \ /documentLlibrary/getLfile

JAAS
Set the fo//o-ing to fa/se to disab/e JAAS security chec.s. =isab/ing JAAS speeds up /ogin. JAAS must be disab/ed if administrators are to be ab/e to impersonate other users.
portal.jaas.enable false

%y defau/t, com'liferay'%ortal'security'*aas'PortalLoginModule /oads the correct JAAS /ogin modu/e based on -hat app/ication server or serv/et container the porta/ is de) p/oyed on. Set a JAAS imp/ementation c/ass to override this behavior.
portal.jaas.impl

A'C

Advanced Liferay Configuration

Advanced Liferay Configuration ,he JAAS process may pass in an encrypted pass-ord and the authentication -i// on/y succeed if there is an e4act match. Set this property to fa/se to re/a4 that behavi) or so the user can input an unencrypted pass-ord.
portal.jaas.strict.password false

Set the fo//o-ing to true to enab/e administrators to impersonate other users.


portal.impersonation.enable true

L0AP
Set the va/ues used to connect to a L=A@ store.
ldap.factory.initial com.sun.jndi.ldap.!dap&t<0actory ldap.base.provider.url ldap*//localhost*3421P ldap.base.dn dc e<ample,dc com ldap.security.principal uid admin,ou system ldap.security.credentials secret ldap.referral follow

Settings for com'liferay'%ortal'security'auth'LDAPAuth can be configured from the Admin port/et. $t provides out of the bo4 support for Apache =irectory Server, :i) crosoft Active =irectory Server, &ove// e=irectory, and ?penL=A@. ,he defau/t set) tings are for Apache =irectory Server. ,he L=A@Auth c/ass must be specified in the property auth'%i%eline'%re to be e4) ecuted. >ncryption is imp/emented by com'liferay'util'1ncry%tor'%rovider'class in system'& %ro%erties.
ldap.auth.enabled false ldap.auth.re(uired false

Set either bind or pass-ord)compare for the L=A@ authentication method. %ind is preferred by most vendors so that you don't have to -orry about encryption strategies.
ldap.auth.method bind ldap.auth.method password-compare

Set the pass-ord encryption to used to compare pass-ords if the property lda%'auth'method is set to pass-ord)compare.
ldap.auth.password.encryption.algorithm ldap.auth.password.encryption.algorithm.types $)6,SM8

Active =irectory stores information about the user account as a series of bit fie/ds in the 0serAccountContro/ attribute. $f you -ant to prevent disab/ed accounts from /ogging into the porta/ you need to use a search fi/ter simi/iar to the fo//o-ing2
A-Aobjectclass personBAuserprincipalname IemailLaddressIBAQA,ser8ccount&ontrol*3.5.1=4.33266?.3.=.142* 5BBB

Advanced Liferay Configuration

A'*

Advanced Liferay Configuration See the fo//o-ing /in.s2 http277support.microsoft.com7.b78"*ACC7 http277support.microsoft.com7J.bid^!+#A(A


ldap.auth.search.filter Amail IemailLaddressIB

1ou can -rite your o-n c/ass that e4tends com'liferay'%ortal'security'lda%'Attrib& utes4ransformer to transform the L=A@ attributes before a user or group is imported to the L=A@ store.
ldap.attrs.transformer.impl com.liferay.portal.security.ldap.8ttributes/ransformer

1ou can -rite your o-n c/ass that e4tends com'liferay'%ortal'security'lda%'LDAPUser to customize the behavior for e4porting porta/ users to the L=A@ store.
ldap.user.impl com.liferay.portal.security.ldap.!)8",ser

<hen a user is e4ported to L=A@ and the user does not e4ist, the user -i// be cre) ated -ith the fo//o-ing defau/t obIect c/asses.
ldap.user.default.object.classes top,person,inetNrg"erson,organi>ational"erson

<hen importing and e4porting users, the porta/ -i// use this mapping to connect L=A@ user attributes and porta/ user variab/es.
ldap.user.mappings screen'ame cn\npassword user"assword\nemail8ddress mail\n first'ame given'ame\nlast'ame sn\njob/itle title\ngroup group$embership

<hen importing groups, the porta/ -i// use this mapping to connect L=A@ group attributes and porta/ user group variab/es.
ldap.group.mappings group'ame cn\ndescription description\nuser uni(ue$ember

Settings for importing users and groups from L=A@ to the porta/.
ldap.import.enabled false ldap.import.on.startup false ldap.import.interval 34 ldap.import.user.search.filter Aobject&lass inetNrg"ersonB ldap.import.group.search.filter Aobject&lass groupNf,ni(ue'amesB

Set either user or group for import method. $f set to user, porta/ -i// import a// users and the groups associated -ith those users. $f set to group, the porta/ import a// groups and the users associated those groups. ,his va/ue shou/d be set based on ho- your L=A@ server stores group member) ship information.
ldap.import.method user ldap.import.method group

Settings for e4porting users from the porta/ to L=A@. ,his a//o-s a user to modify his first name, /ast name, etc. in the porta/ and have that change get pushed to the L=A@ server. ,his -i// on/y be active if the property lda%'auth'enabled is a/so set to true. &e- users and groups -i// be created at the specified =&.

A'+

Advanced Liferay Configuration

Advanced Liferay Configuration


ldap.e<port.enabled true ldap.users.dn ou users,dc e<ample,dc com ldap.groups.dn ou groups,dc e<ample,dc com

Set this to true to use the L=A@'s pass-ord po/icy instead of the porta/ pass-ord po/icy.
ldap.password.policy.enabled false

Set these va/ues to be a portion of the error message returned by the appropriate directory server to a//o- the porta/ to recognize messages from the L=A@ server. ,he defau/t va/ues -i// -or. for 9edora =S.
ldap.error.password.age age ldap.error.password.e<pired e<pired ldap.error.password.history history ldap.error.password.not.changeable not allowed to change ldap.error.password.synta< synta< ldap.error.password.trivial trivial ldap.error.user.lockout retry limit

!AS
Set this to true to enab/e CAS sing/e sign on. &,L: -i// -or. on/y if L=A@ au) thentication is a/so enab/ed and the authentication is made by screen name. $f set to true, then the property auto'login'hoo5s must contain a reference to the c/ass com'liferay'%ortal'security'auth'CA)AutoLogin and the fi/ter com'liferay'%ortal'servlet'filter& s'sso'cas'CA)(ilter must be referenced in -eb.4m/.
cas.auth.enabled false

A user may be authenticated from CAS and not yet e4ist in the porta/. Set this to true to automatica//y import users from L=A@ if they do not e4ist in the porta/.
cas.import.from.ldap false

Set the defau/t va/ues for the reHuired CAS 0RLs. Set either cas'server'name or cas'service'url. Setting cas'server'name a//o-s deep /in.ing. See L>@)CC!8.
cas.login.url https*//localhost*1==2/cas-web/login cas.logout.url https*//localhost*1==2/cas-web/logout cas.server.name localhost*1414 cas.service.url #cas.service.url http*//localhost*1414/c/portal/login cas.service.url http*//localhost*1414/c/portal/login cas.validate.url https*//localhost*1==2/cas-web/pro<yKalidate

Advanced Liferay Configuration

A''

Advanced Liferay Configuration

NTL/
Set this to true to enab/e &,L: sing/e sign on. &,L: -i// -or. on/y if L=A@ au) thentication is a/so enab/ed and the authentication is made by screen name. $f set to true, then the property \auto./ogin.hoo.s\ must contain a reference to the c/ass com'liferay'%ortal'security'auth'6tlmAutoLogin and the fi/ter com'liferay'%ortal'servlet'fil& ters'sso'ntlm'6tlm(ilter must be referenced in -eb.4m/.
ntlm.auth.enabled false ntlm.auth.domain.controller 35T.4.4.3 ntlm.auth.domain .;8$"!.

1P N.0
Set this to true to enab/e ?pen$d authentication. $f set to true, then the property auto'login'hoo5s must contain a reference to the c/ass com'liferay'%ortal'security'au& th'0%enIdAutoLogin.
open.id.auth.enabled true

1P NSS1
,hese properties contro/ Liferay's integration -ith ?penSS?. Set this to true to enab/e ?penSS? authentication.
open.sso.auth.enabled false

Set the /og in 0RL and /og out 0RL. ,he first 0RL is the /in. to your ?penSS? server 5-hich can be the same server as the one running Liferay6U the second 0RL is the /in. to your Liferay @orta/.
open.sso.login.url http*//openssohost.e<ample.com*1414/opensso/,I/!ogin+ goto http*//portalhost.e<ample.com*1414/c/portal/login open.sso.logout.url http*//openssohost.e<ample.com*1414/opensso/,I/!ogout+ goto http*//portalhost.e<ample.com*1414/web/guest/home

Set the 0RL to the ?penSS? service.


open.sso.service.url http*//openssohost.e<ample.com*1414/opensso

Set the ;,,@ attribute name for the user's screen name.
open.sso.screen.name.attr uid

Set the ;,,@ attribute name for the user's emai/ address.
open.sso.email.address.attr mail

Set the ;,,@ attribute name for the user's Common &ame.
open.sso.first.name.attr cn

Set the ;,,@ attribute name for the user's Surname.


open.sso.last.name.attr sn

A'(

Advanced Liferay Configuration

Advanced Liferay Configuration

S.T /.N0 R
Set this to true to enab/e CA Site:inder sing/e sign on. $f set to true, then the property \auto./ogin.hoo.s\ must contain a reference to the c/ass com'liferay'%ortal'se& curity'auth')iteMinderAutoLogin and the logout'events'%ost must have a reference to com'liferay'%ortal'events')iteMinderLogoutAction for /ogout to -or..
siteminder.auth.enabled false

A user may be authenticated from Site:inder and not yet e4ist in the porta/. Set this to true to automatica//y import users from L=A@ if they do not e4ist in the porta/.
siteminder.import.from.ldap false

Set this to the name of the user header that Site:inder passes to the porta/.
siteminder.user.header S$L,S.F

A-T3 NT.!AT.1N P.P L.N


$nput a /ist of comma de/imited c/ass names that imp/ement com'liferay'%ortal'se& curity'auth'Authenticator. ,hese c/asses -i// run before or after the porta/ authentica) tion begins. ,he Authenticator c/ass defines the constant va/ues that shou/d be used as return codes from the c/asses imp/ementing the interface. $f] authentication is successfu/, return S0CC>SSU if the user e4ists but the pass-ords do not match, return 9A$L0R>U and if the user does not e4ist on the system, return =&>. Constants in Authenticator2
public static final int S,&&.SS public static final int 08I!,F. public static final int )'. 47 37 -37

$n case you have severa/ c/asses in the authentication pipe/ine, a// of them have to return S0CC>SS if you -ant the user to be ab/e to /ogin. $f one of the authenticators returns 9A$L0R> or =&>, the /ogin fai/s. 0nder certain circumstances, you might -ant to .eep the information in the porta/ database in sync -ith an e4terna/ database or an L=A@ server. ,his can easi/y be achieved by imp/ementing a c/ass via L=A@Auth that updates the information stored in the porta/ user database -henever a user signs in. >ach porta/ instance can be configured at run time to either authenticate based on user ids or emai/ addresses. See the Admin port/et for more information. Avai/ab/e authenticators are2 com'liferay'%ortal'security'auth'LDAPAuth See the L=A@ properties to configure the behavior of the L=A@Auth c/ass.
auth.pipeline.pre com.liferay.portal.security.auth.!)8"8uth auth.pipeline.post

Set this to true to enab/e pass-ord chec.ing by the interna/ porta/ authentica) Advanced Liferay Configuration A'#

Advanced Liferay Configuration tion. $f set to fa/se, you're essentia//y de/egating pass-ord chec.ing is de/egated to the authenticators configured in auth'%i%eline'%re and auth'%i%eline'%ost settings.
auth.pipeline.enable.liferay.check true

$nput a /ist of comma de/imited c/ass names that imp/ement com'liferay'%ortal'se& curity'auth'Auth(ailure. ,hese c/asses -i// run -hen a user has a fai/ed /ogin or -hen a user has reached the ma4imum number of fai/ed /ogins.
auth.failure com.liferay.portal.security.auth.!ogin0ailure auth.ma<.failures com.liferay.portal.security.auth.!ogin$a<0ailures auth.ma<.failures.limit 6

Set the fo//o-ing to true if users are for-arded to the /ast visited path upon suc) cessfu/ /ogin. $f set to fa/se, users -i// be for-arded to their defau/t /ayout page.
auth.forward.by.last.path true

,he /ogin page reads a redirect by a parameter named redirect. $f this property is set to true, then users -i// be redirected to the given redirect path upon successfu/ /o) gin. $f the user does not have permission to vie- that page, then the ru/e set by the property auth'forward'by'last'%ath -i// app/y. 1ou can set the redirect manua//y from another app/ication, by appending the redirect parameter in a ur/ that /oo.s /i.e this2 +c+%ortal+loginPredirectQU#(grou%U#(em& %loyeesU#(calendar. ,his ur/ -i// redirect the user to the path +grou%+em%loyees+calen& dar upon successfu/ /ogin.
auth.forward.by.redirect true

>nter a /ist of comma de/imited paths that can be considered part of the /ast vis) ited path.
auth.forward.last.paths /documentLlibrary/getLfile

>nter a 0RL that -i// be used to /ogin porta/ users -henever needed. %y defau/t, the porta/'s /ogin page is used.
#auth.login.url /web/guest/home

>nter a friend/y 0RL of a page that -i// be used to /ogin porta/ users -henever the user is navigating a community and authentication is needed. %y defau/t, the porta/'s /ogin page or the 0RL set in the property auth'login'url is used.
auth.login.community.url /login

>nter the name of the /ogin port/et used in a page identified by the 0RL of the previous property 5if one has been set6. ,his -i// a//o- the port/et to have access to the redirect parameter and thus for-ard the user to the page -here he -as trying to access -hen necessary. 1ou shou/d /eave the defau/t va/ue un/ess you have your o-n custom /ogin port/et.
auth.login.portlet.name 61

>nter a /ist of comma de/imited paths that do not reHuire authentication.


auth.public.paths \ /blogs/findLentry,\

A("

Advanced Liferay Configuration

Advanced Liferay Configuration


/blogs/rss,\ /blogs/trackback,\ \ /bookmarks/openLentry,\ \ /documentLlibrary/getLfile,\ \ /journal/getLarticle,\ /journal/getLarticles,\ /journal/getLlatestLarticleLcontent,\ /journal/getLstructure,\ /journal/getLtemplate,\ /journal/viewLarticleLcontent,\ /journalLarticles/viewLarticleLcontent,\ \ /layoutLmanagement/sitemap,\ \ /messageLboards/findLcategory,\ /messageLboards/findLmessage,\ /messageLboards/findLthread,\ /messageLboards/getLmessageLattachment,\ /messageLboards/rss,\ \ /myLplaces/view,\ \ /polls/viewLchart,\ \ /portal/emoticons,\ /portal/e<pireLsession,\ /portal/e<tendLsession,\ /portal/e<tendLsessionLconfirm,\ /portal/jsonLservice,\ /portal/logout,\ /portal/openLidLre(uest,\ /portal/openLidLresponse,\ /portal/sessionLclick,\ /portal/sessionLtreeLjsLclick,\ /portal/status,\ \ /search/openLsearch,\ /search/openLsearchLdescription.<ml,\ \ /shopping/notify,\ \ /tags/rss,\ \ /wiki/getLpageLattachment,\ /wiki/rss

Advanced Liferay Configuration

A(A

Advanced Liferay Configuration

A-T1 L1G.N
$nput a /ist of comma de/imited c/ass names that imp/ement com'liferay'%ortal'se& curity'auth'AutoLogin. ,hese c/asses -i// run in consecutive order for a// unauthentic) ated users unti/ one of them return a va/id user id and pass-ord combination. $f no va/id combination is returned, then the reHuest continues to process norma//y. $f a va/id combination is returned, then the porta/ -i// automatica//y /ogin that user -ith the returned user id and pass-ord combination. 9or e4amp/e, com'liferay'%ortal'security'auth'9ememberMeAutoLogin reads from a coo.ie to automatica//y /og in a user -ho previous/y /ogged in -hi/e chec.ing the 9e& member Me bo4. ,his interface a//o-s dep/oyers to easi/y configure the porta/ to -or. -ith other SS? servers. See com'liferay'%ortal'security'auth'CA)AutoLogin for an e4amp/e of ho- to configure the porta/ -ith 1a/e's SS? server.
auto.login.hooks com.liferay.portal.security.auth.&8S8uto!ogin,com.liferay.portal.security.auth.'tlm8uto!ogin,com.liferay.portal.security.auth.NpenId8uto!ogin,com.liferay.portal.security.auth.NpenSSN8uto!ogin,com.liferay.portal.security.auth.Femember$e8uto!ogin,com.liferay.portal.security.auth.Site$inder8uto!ogin

Set the hosts that -i// be ignored for auto /ogin.


auto.login.ignore.hosts

Set the paths that -i// be ignored for auto /ogin.


auto.login.ignore.paths

SS1 W.T3 /A! ?/ SSAG A-T3 NT.!AT.1N !10 @


,o use SS? -ith :AC, post to an 0RL /i.e2 htt%!++localhost!GJGJ+c+%ortal+loginPcmdQalready&registeredMloginQTuserIdYemailAd& dressRM%asswordQTMACR @ass the :AC in the pass-ord fie/d. :a.e sure the :AC gets 0RL encoded be) cause it might contain characters not a//o-ed in a 0RL. SS? -ith :AC a/so reHuires that you set the fo//o-ing property in system.prop) erties2
com.liferay.util.servlet.Session"arameters false

See the fo//o-ing /in.s2 http277issues./iferay.com7bro-se7L>@)A!(( http277en.-i.ipedia.org7-i.i7:essageMauthenticationMcode Set the fo//o-ing to true to enab/e SS? -ith :AC.
auth.mac.allow false

Set the a/gorithm to use for :AC encryption.


auth.mac.algorithm $)6

A(!

Advanced Liferay Configuration

Advanced Liferay Configuration Set the shared .ey used to generate the :AC.
auth.mac.shared.key

PASSW1R0S
Set the fo//o-ing encryption a/gorithm to encrypt pass-ords. ,he defau/t a/) gorithm is S;A 5S;A)A6. $f set to &?&>, pass-ords are stored in the database as p/ain te4t. ,he S;A)*A! a/gorithm is current/y unsupported. 1xam%les!
passwords.encryption.algorithm &FZ"/ passwords.encryption.algorithm $)5 passwords.encryption.algorithm $)6 passwords.encryption.algorithm 'N'. passwords.encryption.algorithm SM8 passwords.encryption.algorithm SM8-56? passwords.encryption.algorithm SM8-21= passwords.encryption.algorithm SSM8

=igested pass-ords are encoded via base+C or he4 encoding. ,he defau/t is base+C.
passwords.digest.encoding base?= #passwords.digest.encoding he<

$nput a c/ass name that e4tends com'liferay'%ortal'security'%wd'"asic4ool5it. ,his c/ass -i// be ca//ed to generate and va/idate pass-ords. 1xam%les!
passwords.toolkit com.liferay.portal.security.pwd."assword"olicy/oolkit passwords.toolkit com.liferay.portal.security.pwd.Feg.<p/oolkit

$f you choose to use com'liferay'%ortal'security'%wd'PasswordPolicy4ool5it as your pass-ord too/.it, you can choose either static or dynamic pass-ord generation. Static is set through the property %asswords'%assword%olicytool5it'static and dynamic uses the c/ass com'liferay'util'Pwd.enerator to generate the pass-ord. $f you are using L=A@ pass-ord synta4 chec.ing, you -i// a/so have to use the static generator so that you can guarantee that pass-ords obey its ru/es. 1xam%les!
passwords.passwordpolicytoolkit.generator static passwords.passwordpolicytoolkit.generator dynamic passwords.passwordpolicytoolkit.static iheartliferay

$f you choose to use com'liferay'%ortal'security'%wd'9eg1x%4ool5it as your pass-ord too/.it, set the regu/ar e4pression pattern that -i// be used to generate and va/idate pass-ords. &ote that R is rep/aced -ith RR to -or. in Java. ,he first pattern ensures that pass-ords must have at /east C va/id characters consisting of digits or /etters. Advanced Liferay Configuration A(8

Advanced Liferay Configuration ,he second pattern ensures that pass-ords must have at /east ( va/id characters consisting of digits or /etters. 1xam%les!
passwords.rege<ptoolkit.pattern A+ .G=HBA+*Ua->8-X4-PVCB passwords.rege<ptoolkit.pattern A+ .G1HBA+*Ua->8-X4-PVCB

Set the /ength and .ey for generating pass-ords. 1xam%les!


passwords.rege<ptoolkit.charset 4352=6?T1P passwords.rege<ptoolkit.charset 4352=6?T1P8S&).0OMIEY!$'N"%FS/,KR;ZXabcdefghijklmnop(rstuvw<y>

1xam%les!
passwords.rege<ptoolkit.length = passwords.rege<ptoolkit.length 1

Set the name of the defau/t pass-ord po/icy.


passwords.default.policy.name )efault "assword "olicy

R/.SS.1NS

Set the defau/t permission chec.er c/ass used by com'liferay'%ortal'security'%ermis& sion'PermissionChec5er(actory to chec. permissions for actions on obIects. ,his c/ass can be overridden -ith a custom c/ass that e4tends com'liferay'%ortal'security'%ermis& sion'PermissionChec5erIm%l.
permissions.checker com.liferay.portal.security.permission."ermission&heckerImpl

Set the a/gorithm used to chec. permissions for a user. ,his is usefu/ so that you can optimize the search for different databases. See com'liferay'%ortal'service'im%l'Per& missionLocal)erviceIm%l. ,he defau/t is method t-o. ,he first a/gorithm uses severa/ if statements to Huery the database for these five things in order. $f it finds any one of them, it returns true! $s the user connected to one of the permissions via group or organization ro/esJ $s the user associated -ith groups or organizations that are direct/y connected to one of the permissionsJ $s the user connected to one of the permissions via user ro/esJ $s the user connected to one of the permissions via user group ro/esJ $s the user direct/y connected to one of the permissionsJ

permissions.user.check.algorithm 3

,he second a/gorithm 5the defau/t6 does a database Ioin and chec.s the permis) sions in one step, by ca//ing count"y.rou%s9oles, count"y.rou%sPermissions, count"yUser& s9oles, count"yUser.rou%9ole, and count"yUsersPermissions in one method.
permissions.user.check.algorithm 5

,he third a/gorithm chec.s the permissions by chec.ing for three things. $t com) A(C Advanced Liferay Configuration

Advanced Liferay Configuration bines the ro/e chec. into one step. $f it finds any of the fo//o-ing items, it returns true! $s the user associated -ith groups or organizations that are direct/y connec) ted to one of the permissionsJ $s the user associated -ith a ro/e that is direct/y connected to one of the per) missionsJ $s the user direct/y connected to one of the permissionsJ

permissions.user.check.algorithm 2

,he fourth a/gorithm does a database Ioin and chec.s the permissions that a/) gorithm three chec.s in one step, by ca//ing count"y.rou%sPermissions, count"y9ole& sPermissions, and count"yUsersPermissions in one method.
permissions.user.check.algorithm =

Set the defau/t permissions /ist fi/ter c/ass. ,his c/ass must imp/ement com'liferay'& %ortal'5ernel'security'%ermission'PermissionsList(ilter. ,his is used if you -ant to fi/ter the /ist of permissions before it is actua//y persisted. 9or e4amp/e, if you -ant to ma.e sure that a// users -ho create obIects never have the 0@=A,> action, then you can fi/) ter that /ist and remove any permissions that have the 0@=A,> action before it is per) sisted.
permissions.list.filter com.liferay.portal.security.permission."ermissions!ist0ilterImpl

!APT!3A
Set the ma4imum number of captcha chec.s per port/et session. Set this va/ue to " to a/-ays chec.. Set this va/ue to a number /ess than " to never chec.. 0nauthentic) ated users -i// a/-ays be chec.ed on every reHuest if captcha chec.s is enab/ed.
captcha.ma<.challenges 3

Set -hether or not to use captcha chec.s for the fo//o-ing actions.
captcha.check.portal.createLaccount true captcha.check.portal.sendLpassword true captcha.check.portlet.messageLboards.editLcategory false captcha.check.portlet.messageLboards.editLmessage false

START-P

> NTS

$nput a /ist of comma de/imited c/ass names that e4tend com'liferay'%ortal'strut& s')im%leAction. ,hese c/asses -i// run at the specified event. ,he fo//o-ing is a g/oba/ startup event that runs once -hen the porta/ initia/izes.
global.startup.events com.liferay.portal.events.OlobalStartup8ction

,he fo//o-ing is an app/ication startup event that runs once for every -eb site instance of the porta/ that initia/izes.
application.startup.events com.liferay.portal.events.8ppStartup8ction

Advanced Liferay Configuration

A(*

Advanced Liferay Configuration


#application.startup.events com.liferay.portal.events.8ppStartup8ction,com.l iferay.portal.events.Sample8ppStartup8ction

S3-T01WN

> NTS

$nput a /ist of comma de/imited c/ass names that e4tend com'liferay'%ortal'strut& s')im%leAction. ,hese c/asses -i// run at the specified event. G/oba/ shutdo-n event that runs once -hen the porta/ shuts do-n.
global.shutdown.events com.liferay.portal.events.OlobalShutdown8ction

App/ication shutdo-n event that runs once for every -eb site instance of the porta/ that shuts do-n.
application.shutdown.events com.liferay.portal.events.8ppShutdown8ction

@rogrammatica//y .i// the Java process on shutdo-n. ,his is a -or.around for a bug in ,omcat and Linu4 -here the process hangs on forever. See http277issues./iferay.com7bro-se7L>@)!"C( for more information.
shutdown.programmatically.e<it false

P1RTAL

> NTS

$nput a /ist of comma de/imited c/ass names that e4tend com'liferay'%ortal'strut& s'Action. ,hese c/asses -i// run before or after the specified event. Ser!let $er!ice e!ent) the pre)service events have an associated error page and -i// for-ard to that page if an e4ception is thro-n during e4cecution of the events. ,he pre)service events process before Struts processes the reHuest. 1xam%les!
servlet.service.events.pre com.liferay.portal.events.Service"re8ction servlet.service.events.pre com.liferay.portal.events.!og$emory,sage8ction,co m.liferay.portal.events.!og/hread&ount8ction,com.liferay.portal.events.Service"re8ction servlet.service.events.pre com.liferay.portal.events.!ogSessionId8ction,com. liferay.portal.events.Service"re8ction servlet.service.events.pre com.liferay.portal.events.Service"re8ction,com.li feray.portal.events.Fandom!ayout8ction servlet.service.events.pre com.liferay.portal.events.Service"re8ction,com.li feray.portal.events.Fandom!ook8nd0eel8ction

0se the fo//o-ing to define the error page.


servlet.service.events.pre.error.page /common/error.jsp

,he post)service events process after Struts processes the reHuest.


servlet.service.events.post com.liferay.portal.events.Service"ost8ction

A(+

Advanced Liferay Configuration

Advanced Liferay Configuration

L1G.N

> NT

=efine events that can occur pre)/ogin and post)/ogin.


login.events.pre com.liferay.portal.events.!ogin"re8ction login.events.post com.liferay.portal.events.!ogin"ost8ction,com.liferay.portal.events.)efault!anding"age8ction

L1G1-T

> NT

Simi/ar/y, events can be defined for the /og out event.


logout.events.pre com.liferay.portal.events.!ogout"re8ction

1xam%le %ost events!


logout.events.post com.liferay.portal.events.!ogout"ost8ction logout.events.post com.liferay.portal.events.!ogout"ost8ction,com.liferay.portal.events.)efault!ogout"age8ction,com.liferay.portal.events.Site$inder!ogout8ction #logout.events.post com.liferay.portal.events.!ogout"ost8ction,com.liferay.portal.events.Oarbage&ollector8ction

0 *A-LT LAN0.NG PAG


Set the defau/t /anding page path for /ogged in users re/ative to the server path. ,his is the page users are automatica//y redirected to after /ogging in. 9or e4amp/e, if you -ant the defau/t /anding page to be http277/oca/host2("("7-eb7guest7/ogin, set this to 7-eb7guest7/ogin. ,o activate this feature, set auth.for-ard.by./ast.path to true. ,o customize the behavior, see com'liferay'%ortal'events'DefaultLandingPageAction in the login'events'%ost property above.
#default.landing.page.path /web/guest/login

0 *A-LT L1G1-T PAG


Set the defau/t /ogout page path for users re/ative to the server path. ,his is the page users are automatica//y redirected to after /ogging out. 9or e4amp/e, if you -ant the defau/t /ogout page to be http277/oca/host2("("7-eb7guest7/ogout, set this to +web+guest+logout. ,o activate this feature, set auth'forward'by'last'%ath to true. ,o cus) tomize the behavior, see com'liferay'%ortal'events'DefaultLogoutPageAction in the logout'events'%ost property above.
#default.logout.page.path /web/guest/logout

0 *A-LT G- ST P-(L.! LA51-TS


,he Guest group must have at /east one pub/ic page. ,he settings for the initia/ pub/ic page are specified in the fo//o-ing properties. $f you need to add more than one page, set the property default'guest'%ublic'lay& out'lar to specify a LAR fi/e instead. Advanced Liferay Configuration A('

Advanced Liferay Configuration 9or even more comp/e4 behavior, override the addDefault.uestPublicLayouts method in com'liferay'%ortal'service'im%l'.rou%Local)erviceIm%l. Set the name of the pub/ic /ayout.
default.guest.public.layout.name Relcome

Set the /ayout temp/ate id of the pub/ic /ayout.


default.guest.public.layout.template.id 5LcolumnsLii

Set the port/et ids for the co/umns specified in the /ayout temp/ate.
default.guest.public.layout.column-3 61 default.guest.public.layout.column-5 =T default.guest.public.layout.column-2 default.guest.public.layout.column-=

Set the friend/y ur/ of the pub/ic /ayout.


default.guest.public.layout.friendly.url /home

Set the regu/ar theme id for the pub/ic /ayout.


#default.guest.public.layout.regular.theme.id classic

Set the regu/ar co/or scheme id for the pub/ic /ayout.


#default.guest.public.layout.regular.color.scheme.id 43

Set the -ap theme id for the pub/ic /ayout.


#default.guest.public.layout.wap.theme.id mobile

Set the -ap co/or scheme for the pub/ic /ayout.


#default.guest.public.layout.wap.color.scheme.id 43

Specify a LAR fi/e that can be used to create the guest pub/ic /ayouts. $f this prop) erty is set, the previous /ayout properties -i// be ignored.
#default.guest.public.layouts.lar @Gliferay.homeH/deploy/defaultLguestLpublic.lar

0 *A-LT -S R PR.>AT LA51-TS


$f the properties layout'user'%rivate'layouts'enabled and layout'user'%rivate'layout& s'auto'create are both set to true, then users -i// have private /ayouts and they -i// be automatica//y created. ,he settings be/o- are used for the creation of for the initia/ private pages. $f you need to add more than one page, set the property default'user'%rivate'lay& out'lar to specify a LAR fi/e instead. 9or even more comp/e4 behavior, override the addDefaultUserPrivateLayouts method in com'liferay'%ortal'events')ervicePreAction. Set the name of the private /ayout.
default.user.private.layout.name Relcome

A((

Advanced Liferay Configuration

Advanced Liferay Configuration Set the /ayout temp/ate id of the private /ayout.
default.user.private.layout.template.id 5LcolumnsLii

Set the port/et ids for the co/umns specified in the /ayout temp/ate.
default.user.private.layout.column-3 T3LI'S/8'&.LNZ4d,15,52,?3 default.user.private.layout.column-5 33,5P,1,3P default.user.private.layout.column-2 default.user.private.layout.column-=

Set the friend/y ur/ of the private /ayout.


default.user.private.layout.friendly.url /home

Set the regu/ar theme id for the private /ayout.


#default.user.private.layout.regular.theme.id classic

Set the regu/ar co/or scheme id for the private /ayout.


#default.user.private.layout.regular.color.scheme.id 43

Set the -ap theme id for the private /ayout.


#default.user.private.layout.wap.theme.id mobile

Set the -ap co/or scheme for the private /ayout.


#default.user.private.layout.wap.color.scheme.id 43

Specify a LAR fi/e that can be used to create the user private /ayouts. $f this prop) erty is set, the previous /ayout properties -i// be ignored.
#default.user.private.layouts.lar \ @Gliferay.homeH/deploy/defaultLuserLprivate.lar

0 *A-LT -S R P-(L.! LA51-TS


$f the properties layout'user'%ublic'layouts'enabled and layout'user'%ublic'layout& s'auto'create are both set to true, then users -i// have pub/ic /ayouts and they -i// be automatica//y created. ,he settings be/o- are used for the creation of for the initia/ pub/ic pages. $f you need to add more than one page, set the property default'user'%ublic'lay& out'lar to specify a LAR fi/e instead. 9or even more comp/e4 behavior, override the addDefaultUserPublicLayouts meth) od in com'liferay'%ortal'events')ervicePreAction. Set the name of the pub/ic /ayout.
default.user.public.layout.name Relcome

Set the /ayout temp/ate id of the pub/ic /ayout.


default.user.public.layout.template.id 5LcolumnsLii

Set the port/et ids for the co/umns specified in the /ayout temp/ate.
default.user.public.layout.column-3 15,52

Advanced Liferay Configuration

A(#

Advanced Liferay Configuration


default.user.public.layout.column-5 1,3P default.user.public.layout.column-2 default.user.public.layout.column-=

Set the friend/y ur/ of the pub/ic /ayout.


default.user.public.layout.friendly.url /home

Set the regu/ar theme id for the pub/ic /ayout.


#default.user.public.layout.regular.theme.id classic

Set the regu/ar co/or scheme id for the pub/ic /ayout.


#default.user.public.layout.regular.color.scheme.id 43

Set the -ap theme id for the pub/ic /ayout.


#default.user.public.layout.wap.theme.id mobile

Set the -ap co/or scheme for the pub/ic /ayout.


#default.user.public.layout.wap.color.scheme.id 43

Specify a LAR fi/e that can be used to create the user pub/ic /ayouts. $f this prop) erty is set, the previous /ayout properties -i// be ignored.
#default.user.public.layouts.lar @Gliferay.homeH/deploy/defaultLuserLpublic.lar

0 *A-LT A0/.N
Set the defau/t admin pass-ord.
default.admin.password test

Set the defau/t admin screen name prefi4.


default.admin.screen.name test

Set the defau/t admin emai/ address prefi4.


default.admin.email.address.prefi< test

Set the defau/t admin first name.


default.admin.first.name /est

Set the defau/t admin midd/e name.


default.admin.middle.name

Set the defau/t admin /ast name.


default.admin.last.name /est

LA51-TS
Set the /ist of /ayout types. ,he disp/ay te4t of each of the /ayout types is set in content+Language'%ro%erties and prefi4ed -ith layout'ty%es. 1ou can create ne- /ayout types and specify custom settings for each /ayout type. >nd users input dynamic va/) A#" Advanced Liferay Configuration

Advanced Liferay Configuration ues as designed in the edit page. >nd users see the /ayout as designed in the viepage. ,he generated 0RL can reference properties set in the edit page. @arentab/e /ay) outs can contain chi/d /ayouts. 1ou can a/so specify a comma de/imited /ist of config) uration actions that -i// be ca//ed for your /ayout -hen it is updated or de/eted.
layout.types portlet,panel,embedded,article,url,linkLtoLlayout

Set -hether or not private /ayouts are enab/ed. Set -hether or not private /ay) outs are modifiab/e. Set -hether or not private /ayouts shou/d be auto created if a user has no private /ayouts. $f private /ayouts are not enab/ed, the other t-o proper) ties are assumed to be fa/se.
layout.user.private.layouts.enabled true layout.user.private.layouts.modifiable true layout.user.private.layouts.auto.create true

Set -hether or not pub/ic /ayouts are enab/ed. Set -hether or not pub/ic /ayouts are modifiab/e. Set -hether or not pub/ic /ayouts shou/d be auto created if a user has no pub/ic /ayouts. $f pub/ic /ayouts are not enab/ed, the other t-o properties are as) sumed to be fa/se.
layout.user.public.layouts.enabled true layout.user.public.layouts.modifiable true layout.user.public.layouts.auto.create true

0 *A-LT S TT.NGS LA51-TS


,hese settings a//o- you to define severa/ attributes on /ayouts. 1ou can a/so spe) cify -hich JS@s are responsib/e for editing and vie-ing /ayouts. 1ou -i// /i.e/y never need to change these settings.
layout.edit.page /portal/layout/edit/portlet.jsp layout.view.page /portal/layout/view/portlet.jsp layout.url @Gliferay*main"athH/portal/layout+pLlLid @Gliferay*plidH layout.url.friendliable true layout.parentable true layout.sitemapable true layout.first.pageable true layout.configuration.action.update layout.configuration.action.delete

Settings for port/et /ayouts are inherited from the defau/t settings.
layout.edit.pageUportletV /portal/layout/edit/portlet.jsp layout.view.pageUportletV /portal/layout/view/portlet.jsp layout.urlUportletV @Gliferay*main"athH/portal/layout+pLlLid @Gliferay*plidH layout.url.friendliableUportletV true layout.parentableUportletV true layout.configuration.action.updateUportletV layout.configuration.action.deleteUportletV

Settings for pane/ /ayouts.


layout.edit.pageUpanelV /portal/layout/edit/panel.jsp

Advanced Liferay Configuration

A#A

Advanced Liferay Configuration


layout.view.pageUpanelV /portal/layout/view/panel.jsp layout.urlUpanelV @Gliferay*main"athH/portal/layout+pLlLid @Gliferay*plidH layout.url.friendliableUpanelV true layout.parentableUpanelV true layout.first.pageableUpanelV true

Settings for contro/Mpane/ /ayouts.


layout.edit.pageUcontrolLpanelV /portal/layout/edit/controlLpanel.jsp layout.view.pageUcontrolLpanelV /portal/layout/view/controlLpanel.jsp layout.urlUcontrolLpanelV @Gliferay*main"athH/portal/layout+pLlLid @ Gliferay*plidH layout.url.friendliableUcontrolLpanelV true layout.parentableUcontrolLpanelV true layout.first.pageableUcontrolLpanelV true

Settings for embedded /ayouts.


layout.edit.pageUembeddedV /portal/layout/edit/embedded.jsp layout.view.pageUembeddedV /portal/layout/view/embedded.jsp layout.urlUembeddedV @Gliferay*main"athH/portal/layout+pLlLid @ Gliferay*plidH layout.url.friendliableUembeddedV true layout.parentableUembeddedV false layout.sitemapableUembeddedV true layout.first.pageableUembeddedV true layout.configuration.action.updateUembeddedV layout.configuration.action.deleteUembeddedV

Settings for artic/e /ayouts.


layout.edit.pageUarticleV /portal/layout/edit/article.jsp layout.view.pageUarticleV /portal/layout/view/article.jsp layout.url.friendliableUarticleV true layout.urlUarticleV @Gliferay*main"athH/portal/layout+pLlLid @Gliferay*plidH layout.parentableUarticleV false layout.sitemapableUarticleV true layout.first.pageableUarticleV true layout.configuration.action.updateUarticleV com.liferay.portal.model.!ayout/ype8rticle&onfiguration,pdate8ction layout.configuration.action.deleteUarticleV com.liferay.portal.model.!ayout/ype8rticle&onfiguration)elete8ction

Settings for 0RL /ayouts.


layout.edit.pageUurlV /portal/layout/edit/url.jsp layout.view.pageUurlV layout.urlUurlV @GurlH layout.url.friendliableUurlV true layout.parentableUurlV false layout.sitemapableUurlV false layout.first.pageableUurlV false layout.configuration.action.updateUurlV layout.configuration.action.deleteUurlV

A#!

Advanced Liferay Configuration

Advanced Liferay Configuration Settings for page /ayouts.


layout.edit.pageUlinkLtoLlayoutV /portal/layout/edit/linkLtoLlayout.jsp layout.view.pageUlinkLtoLlayoutV layout.urlUlinkLtoLlayoutV @Gliferay*main"athH/portal/layout+pLlLid @Glink/o"lidH layout.url.friendliableUlinkLtoLlayoutV true layout.parentableUlinkLtoLlayoutV true layout.sitemapableUlinkLtoLlayoutV false layout.first.pageableUlinkLtoLlayoutV false layout.configuration.action.updateUlinkLtoLlayoutV layout.configuration.action.deleteUlinkLtoLlayoutV

Specify static port/ets that cannot be moved and -i// a/-ays appear on every /ay) out. Static port/ets -i// ta.e precedence over port/ets that may have been dynamica//y configured for the /ayout. 9or e4amp/e, if you -ant the ;e//o <or/d port/et to a/-ays appear at the start of the iteration of the first co/umn for user /ayouts, set the property layout'static'%ortlet& s'start'column& =user> to ;F. $f you -ant the ;e//o <or/d port/et to a/-ays appear at the end of the second co/umn for user /ayouts, set the property layout'static'%ortlets'end'& column&#=user> to ;F. 1ou can input a /ist of comma de/imited port/et ids to specify more than one port/et. $f the port/et is instanceab/e, add the suffi4 /I6)4A6C1/abcd to the port/et id, -here abcd is any random a/phanumeric string. ,he static port/ets are fetched based on the properties contro//ed by custom fi/) ters using >asyConf. %y defau/t, the avai/ab/e fi/ters are user, community, and organ) ization.
layout.static.portlets.start.column-3UuserV 2,? layout.static.portlets.end.column-3UuserV 3= layout.static.portlets.start.column-5UuserV T3LI'S/8'&.Labcd,T layout.static.portlets.end.column-5UuserV 2=,T4 layout.static.portlets.start.column-2UuserV layout.static.portlets.end.column-2UuserV

$t is a/so possib/e to set static port/ets based on the /ayout's friend/y 0RL.
layout.static.portlets.start.column-3UuserVU/homeV 2,? layout.static.portlets.end.column-5UcommunityVU/homeV 3=

Set the static port/ets for community /ayouts.


layout.static.portlets.start.column-3UcommunityV layout.static.portlets.end.column-3UcommunityV layout.static.portlets.start.column-5UcommunityV layout.static.portlets.end.column-5UcommunityV layout.static.portlets.start.column-2UcommunityV layout.static.portlets.end.column-2UcommunityV

Set the static port/ets for organization /ayouts.


layout.static.portlets.start.column-3Uorgani>ationV layout.static.portlets.end.column-3Uorgani>ationV layout.static.portlets.start.column-5Uorgani>ationV

Advanced Liferay Configuration

A#8

Advanced Liferay Configuration


layout.static.portlets.end.column-5Uorgani>ationV layout.static.portlets.start.column-2Uorgani>ationV layout.static.portlets.end.column-2Uorgani>ationV

Set the static port/ets that -i// appear for every /ayout. See +html+%ortal+layout+view+%ortlet'*s% in the Liferay source code for the /ogic of -hen these port/ets -i// be sho-n. 9or e4amp/e, these port/ets -i// on/y sho- for /ayouts that can contain port/ets and are not in a pop up state.
layout.static.portlets.all 3LR8FLchatportlet

Set the private group, private user, and pub/ic serv/et mapping for com'liferay'& %ortal'servlet'(riendlyU9L)ervlet. ,his va/ue must match the serv/et mapping set in -eb.4m/. 9or e4amp/e, if the private group pages are mapped to +grou% and the group's friend/y 0RL is set to +guest and the /ayout's friend/y 0RL is set to +com%any+com& munity, then the friend/y 0RL for the page -i// be htt%!++www'liferay'& com+grou%+guest+com%any+community. @rivate group pages map to a community's private pages and are on/y avai/ab/e to authenticated users -ith the proper permis) sions. 9or e4amp/e, if the pub/ic pages are mapped to +web and the group or user's friend/y 0RL is set to +guest and the /ayout's friend/y 0RL is set to +com%any+com& munity, then the friend/y 0RL for the page -i// be htt%!++www'liferay'com+web+guest+com%any+community. @ub/ic pages are avai/ab/e to unauthenticated users. ,he friend/y 0RLs for users, groups, and /ayouts can be set during runtime.
layout.friendly.url.private.group.servlet.mapping /group layout.friendly.url.private.user.servlet.mapping /user layout.friendly.url.public.servlet.mapping /web

Redirect to this resource if the user reHuested a friend/y 0RL that does not e4ist. Leave it b/an. to disp/ay nothing. 3ote) 9or bac.-ard compatibi/ity, this overrides the property layout'show'ht& t%'status for the C"C status code.
layout.friendly.url.page.not.found /html/portal/=4=.html

Set the reserved .ey-ords that cannot be used in a friend/y 0RL.


layout.friendly.url.keywords c,group,web,image,wsrp,page,public,private,rss, tags

Set the fo//o-ing to true if /ayouts shou/d remember 5across reHuests6 that a -in) do- state -as set to ma4imized.
layout.remember.re(uest.window.state.ma<imi>ed false

Set the fo//o-ing to true if guest users shou/d see the ma4imize -indo- icon.
layout.guest.show.ma<.icon false

Set the fo//o-ing to true if guest users shou/d see the minimize -indo- icon.
layout.guest.show.min.icon false

A#C

Advanced Liferay Configuration

Advanced Liferay Configuration Set the fo//o-ing to true if users are sho-n that they do not have access to a port/et. ,he port/et init parameter show&%ortlet&access&denied -i// override this setting.
layout.show.portlet.access.denied true

Set the fo//o-ing to true if users are sho-n that a port/et is inactive. ,he port/et init parameter show&%ortlet&inactive -i// override this setting.
layout.show.portlet.inactive true

Set the fo//o-ing to true if the porta/ shou/d sho- ;,,@ status codes /i.e C"C if the reHuested page is not found.
layout.show.http.status true

Set the defau/t /ayout temp/ate id used -hen creating /ayouts.


layout.default.template.id 5LcolumnsLii

Set the fo//o-ing to fa/se to disab/e para//e/ rendering. 1ou can a/so disab/e it on a per reHuest basis by setting the attribute .ey com'liferay'%ortal'util'@eb:eys'P094& L14/PA9ALL1L/916D19 to the "oolean'(AL)1 in a pre service event or by setting the 0RL parameter %/%/%arallel to J.
layout.parallel.render.enable true

Set the name of a c/ass that imp/ements com'liferay'%ortal'util'LayoutClone. ,his c/ass is used to remember ma4imized and minimized states on shared pages. ,he de) fau/t imp/ementation persists the state in the bro-ser session.
layout.clone.impl com.liferay.portal.util.Session!ayout&lone

Set the fo//o-ing to true to cache the content of /ayout temp/ates. ,his is recom) mended because it improves performance for production servers. Setting it to fa/se is usefu/ during deve/opment if you need to ma.e a /ot of changes.
layout.template.cache.enabled true

Set the defau/t va/ue for the %/l/reset parameter. $f set to true, then render para) meters are c/eared -hen different pages are hit. ,his is not the behavior promoted by the port/et specification, but is the one that most end users seem to prefer.
layout.default.pLlLreset true

P1RTL T -RL
Set the fo//o-ing to true if ca//ing set@arameter on a port/et 0RL appends the parameter va/ue versus rep/acing it. ,here is some disagreement in the interpretation of the JSR A+( spec among port/et deve/opers over this specific behavior. Liferay @orta/ successfu//y passes the port/et ,CE tests -hether this va/ue is set to true or fa/se. See http277issues./iferay.com7bro-se7L>@)C!+ for more information.
portlet.url.append.parameters false

Set the fo//o-ing to true to a//o- port/et 0RLs to generate -ith an anchor tag.
portlet.url.anchor.enable false

Advanced Liferay Configuration

A#*

Advanced Liferay Configuration JSR !(+ specifies that port/et 0RLs are escaped by defau/t. Set this to fa/se to provide for better bac.-ards compatibi/ity. $f this is set to true, but a specific port/et app/ication reHuires that its port/et 0RLs not be escaped by defau/t, then modify port/et.4m/ and set the container runtime option *avax'%ortlet'esca%eEml to fa/se.
portlet.url.escape.<ml false

PR * R N! S
Set the fo//o-ing to true to va/idate port/et preferences on startup.
preference.validate.on.startup false

STR-TS
$nput the custom Struts reHuest processor that -i// be used by Struts based port) /ets. ,he custom c/ass must e4tend com'liferay'%ortal'struts'Portlet9e7uestProcessor and have the same constructor.
struts.portlet.re(uest.processor com.liferay.portal.struts."ortletFe(uest"rocessor

./AG S
Set the /ocation of the defau/t spacer image that is used for missing images. ,his image must be avai/ab/e in the c/ass path.
image.default.spacer com/liferay/portal/dependencies/spacer.gif

Set the /ocation of the defau/t company /ogo image that is used for missing com) pany /ogo images. ,his image must be avai/ab/e in the c/ass path.
image.default.company.logo com/liferay/portal/dependencies/companyLlogo.png

Set the /ocation of the defau/t organization /ogo image that is used for missing organization /ogo images. ,his image must be avai/ab/e in the c/ass path.
image.default.organi>ation.logo com/liferay/portal/dependencies/organi>ationLlogo.png

Set the /ocations of the defau/t user portrait images that are used for missing user portrait images. ,his image must be avai/ab/e in the c/ass path.
image.default.user.female.portrait com/liferay/portal/dependencies/userLfemaleLportrait.png image.default.user.male.portrait com/liferay/portal/dependencies/userLmaleLp ortrait.png

Set the name of a c/ass that imp/ements com./iferay.porta/.image.;oo.. ,he porta/ -i// use this persist images. Avai/ab/e hoo.s are2 com./iferay.porta/.image.=atabase;oo.

A#+

Advanced Liferay Configuration

Advanced Liferay Configuration com./iferay.porta/.image.=L;oo. com./iferay.porta/.image.9i/eSystem;oo.

image.hook.impl com.liferay.portal.image.)atabaseMook #image.hook.impl com.liferay.portal.image.)!Mook #image.hook.impl com.liferay.portal.image.0ileSystemMook

*.L S5ST /3112


image.hook.file.system.root.dir @Gliferay.homeH/data/images

0.T1RS

1ou can configure individua/ JS@ pages to use a specific imp/ementation of the avai/ab/e <1S$<1G editors2 /iferay, fc.editor, simp/e, tinymce, or tinymcesimp/e.
editor.wysiwyg.default fckeditor editor.wysiwyg.portal-web.docroot.html.portlet.blogs.editLentry.jsp fckeditor editor.wysiwyg.portal-web.docroot.html.portlet.calendar.editLconfiguration.jsp fckeditor editor.wysiwyg.portal-web.docroot.html.portlet.enterpriseLadmin.view.jsp fckeditor editor.wysiwyg.portal-web.docroot.html.portlet.invitation.editLconfiguration.jsp fckeditor editor.wysiwyg.portal-web.docroot.html.portlet.journal.editLarticleLcontent.jsp fckeditor editor.wysiwyg.portal-web.docroot.html.portlet.journal.editLarticleLcontentL<sdLel.jsp fckeditor editor.wysiwyg.portal-web.docroot.html.portlet.journal.editLconfiguration.jsp fckeditor editor.wysiwyg.portal-web.docroot.html.portlet.login.configuration.jsp fckeditor editor.wysiwyg.portal-web.docroot.html.portlet.mail.edit.jsp fckeditor editor.wysiwyg.portal-web.docroot.html.portlet.mail.editLmessage.jsp fckeditor editor.wysiwyg.portal-web.docroot.html.portlet.messageLboards.editLconfiguration.jsp fckeditor editor.wysiwyg.portal-web.docroot.html.portlet.shopping.editLconfiguration.jsp fckeditor editor.wysiwyg.portal-web.docroot.html.portlet.wiki.editLhtml.jsp fckeditor

*. L0S
Set the fo//o-ing fie/ds to fa/se so users cannot see them. Some company po/icies reHuire gender and birthday information to a/-ays be hidden.
field.enable.com.liferay.portal.model.&ontact.male true field.enable.com.liferay.portal.model.&ontact.birthday true field.enable.com.liferay.portal.model.Nrgani>ation.status false

Advanced Liferay Configuration

A#'

Advanced Liferay Configuration

/./ T5P S
$nput a /ist of comma de/imited mime types that are not avai/ab/e by defau/t from *avax'activation'Mimety%es(ile4y%eMa%.
mime.types \ application/msword doc,\ application/pdf pdf,\ application/vnd.ms-e<cel <ls,\ application/vnd.ms-powerpoint ppt,\ application/<-ms-wmp wmv,\ application/<-shockwave-flash swf flv

$nput a /ist of comma de/imited e4tensions for -hich the content disposition header has to be set to inline.
mime.types.content.disposition.inline flv,pdf,swf,wmv

A/AD1N
>nter an Amazon access .ey $= and an Amazon associate tag. ,his is made avai/) ab/e on/y for persona/ use. @/ease see the Amazons /icense at http277---.amazon.com for more information.
#ama>on.access.key.id #ama>on.associate.tag

(R1WS R LA-N!3 R
>nter a 0RL to automatica//y /aunch a bro-ser to that 0RL -hen the porta/ has fu//y initia/ized. >nter a b/an. 0RL to disab/e this feature.
browser.launcher.url http*//localhost*1414

!1NTR1L PAN L
Set the name of the /ayout.
control.panel.layout.name &ontrol "anel

Set the friend/y 0RL of the /ayout.


control.panel.layout.friendly.url /manage

Set the theme of the /ayout.


control.panel.layout.regular.theme.id controlpanel

Set the ma4imum number of communities that -i// be sho-n in the navigation menus. A /arge va/ue might cause performance prob/ems if the number of communit) ies that the user can administer is very /arge.
control.panel.navigation.ma<.communities 64

Set the ma4imum number of organizations that -i// be sho-n in the navigation

A#(

Advanced Liferay Configuration

Advanced Liferay Configuration menus. A /arge va/ue might cause performance prob/ems if the number of organiza) tions that the user can administer is very /arge.
control.panel.navigation.ma<.organi>ations 64

.NSTANT / SS NG R
Set the A$: /ogin and pass-ord -hich the system -i// use to communicate -ith users.
aim.login aim.password

=ue to a bug in J?scarLib ".8bA, you must set the fu// path to the $CF Iar. See the fo//o-ing posts2 http277sourceforge.net7forum7message.phpJmsgMid^A#'!+#' http277sourceforge.net7forum7message.phpJmsgMid^A##"C('
ic(.jar &*/Eava/orion-5.4.T/lib/ic(.jar

Set the $CF /ogin and pass-ord -hich the system -i// use to communicate -ith users.
ic(.login ic(.password

Set the :S& /ogin and pass-ord -hich the system -i// use to communicate -ith users.
msn.login msn.password

Set the 1: /ogin and pass-ord -hich the system -i// use to communicate -ith users.
ym.login ym.password

L-! N S AR!3
Set the fo//o-ing to true if you -ant to avoid any -rites to the inde4. ,his is use) fu/ in some c/ustering environments -here there is a shared inde4 and on/y one node of the c/uster updates it.
inde<.read.only false

Set the fo//o-ing to true if you -ant to inde4 your entire /ibrary of fi/es on star) tup.
inde<.on.startup false

Set this to true to add a de/ay before inde4ing on startup. A de/ay may be neces) sary if a /ot of p/ugins need to be /oaded and reinde4ed. ,his property is on/y va/id if index'on'startu% is set to true.

Advanced Liferay Configuration

A##

Advanced Liferay Configuration


inde<.on.startup.delay ?4

Set the fo//o-ing to true if you -ant the inde4ing on startup to be e4ecuted on a separate thread to speed up e4ecution.
inde<.with.thread true

=esignate -hether Lucene stores inde4es in a database via J=%C, fi/e system, or in RA:. 1xam%les!
lucene.store.type jdbc lucene.store.type file lucene.store.type ram

Lucene's storage of inde4es via J=%C has a bug -here temp fi/es are not removed. ,his can eat up dis. space over time. Set the fo//o-ing property to true to automatic) a//y c/ean up the temporary fi/es once a day. See L>@)!A(".
lucene.store.jdbc.auto.clean.up true

Set the J=%C dia/ect that Lucene uses to store inde4es in the database. ,his is on/y referenced if Lucene stores inde4es in the database. Liferay -i// attempt to /oad the proper dia/ect based on the 0RL of the J=%C connection. 9or e4amp/e, the prop) erty lucene'store'*dbc'dialect'mys7l is read for the J=%C connection 0RL *dbc!mys7l!++loc& alhost+l%ortal.
lucene.store.jdbc.dialect.db5 org.apache.lucene.store.jdbc.dialect.)S5)ialect lucene.store.jdbc.dialect.derby org.apache.lucene.store.jdbc.dialect.)erby)ialect lucene.store.jdbc.dialect.hs(ldb org.apache.lucene.store.jdbc.dialect.MS%!)ialect lucene.store.jdbc.dialect.jtds org.apache.lucene.store.jdbc.dialect.S%!Server)ialect lucene.store.jdbc.dialect.microsoft org.apache.lucene.store.jdbc.dialect.S%!Server)ialect lucene.store.jdbc.dialect.mys(l org.apache.lucene.store.jdbc.dialect.$yS%!)ialect #lucene.store.jdbc.dialect.mys(l org.apache.lucene.store.jdbc.dialect.$yS%!Inno)S)ialect #lucene.store.jdbc.dialect.mys(l org.apache.lucene.store.jdbc.dialect.$yS%!$yIS8$)ialect lucene.store.jdbc.dialect.oracle org.apache.lucene.store.jdbc.dialect.Nracle)ialect lucene.store.jdbc.dialect.postgres(l org.apache.lucene.store.jdbc.dialect."ostgreS%!)ialect

Set the directory -here Lucene inde4es are stored. ,his is on/y referenced if Lu) cene stores inde4es in the fi/e system.
lucene.dir @Gliferay.homeH/lucene/

$nput a c/ass name that e4tends com'liferay'%ortal'search'lucene'Lucene(ile1xtractor. ,his c/ass is ca//ed by Lucene to e4tract te4t from comp/e4 fi/es so that they can be proper/y inde4ed.

!""

Advanced Liferay Configuration

Advanced Liferay Configuration


lucene.file.e<tractor com.liferay.portal.search.lucene.!ucene0ile.<tractor

,he fi/e e4tractor can sometimes return te4t that is not va/id for Lucene. ,his property e4pects a regu/ar e4pression. Any character that does not match the regu/ar e4pression -i// be rep/aced -ith a b/an. space. Set an empty regu/ar e4pression to disab/e this feature. 1xam%les!
lucene.file.e<tractor.rege<p.strip lucene.file.e<tractor.rege<p.strip U\\d\\wV

Set the defau/t ana/yzer used for inde4ing and retrieva/. 1xam%les!
lucene.analy>er org.apache.lucene.analysis.br.Sra>ilian8naly>er lucene.analy>er org.apache.lucene.analysis.cn.&hinese8naly>er lucene.analy>er org.apache.lucene.analysis.cjk.&EY8naly>er lucene.analy>er org.apache.lucene.analysis.c>.&>ech8naly>er lucene.analy>er org.apache.lucene.analysis.nl.)utch8naly>er lucene.analy>er org.apache.lucene.analysis.fr.0rench8naly>er lucene.analy>er org.apache.lucene.analysis.de.Oerman8naly>er lucene.analy>er org.apache.lucene.analysis.Yeyword8naly>er lucene.analy>er org.apache.lucene.inde<.memory."attern8naly>er lucene.analy>er org.apache.lucene.analysis."er0ield8naly>erRrapper lucene.analy>er org.apache.lucene.analysis.ru.Fussian8naly>er lucene.analy>er org.apache.lucene.analysis.Simple8naly>er lucene.analy>er org.apache.lucene.analysis.snowball.Snowball8naly>er lucene.analy>er org.apache.lucene.analysis.standard.Standard8naly>er lucene.analy>er org.apache.lucene.analysis.Stop8naly>er lucene.analy>er org.apache.lucene.analysis.Rhitespace8naly>er

Set Lucene's merge factor. ;igher numbers mean inde4ing goes faster but uses more memory. ,he defau/t va/ue from Lucene is A". ,his shou/d never be set to a number /o-er than !.
lucene.merge.factor 34

Set ho- often to run Lucene's optimize method. ?ptimization speeds up search) ing but s/o-s do-n -riting. Set this property to " to a/-ays optimize. Set this prop) erty to an integer greater than " to optimize every D -rites.
lucene.optimi>e.interval 3

S1-R! *1RG
source.forge.mirrors \ http*//downloads.sourceforge.net,\ http*//internap.dl.sourceforge.net,\ # Fedirect # San Eose, &8

http*//superb-east.dl.sourceforge.net,\ # $c!ean, Kirginia http*//superb-west.dl.sourceforge.net,\ # Seattle, Rashington http*//easynews.dl.sourceforge.net,\ http*//kent.dl.sourceforge.net,\ # "hoeni<, 8X # Yent, ,Y

Advanced Liferay Configuration

!"A

Advanced Liferay Configuration


http*//ufpr.dl.sourceforge.net,\ http*//belnet.dl.sourceforge.net,\ http*//switch.dl.sourceforge.net,\ http*//mesh.dl.sourceforge.net,\ http*//ovh.dl.sourceforge.net,\ http*//dfn.dl.sourceforge.net,\ http*//heanet.dl.sourceforge.net,\ http*//garr.dl.sourceforge.net,\ http*//surfnet.dl.sourceforge.net http*//jaist.dl.sourceforge.net,\ http*//nchc.dl.sourceforge.net,\ http*//optusnet.dl.sourceforge.net # &uritiba, Sra>il # Srussels, Selgium # !ausanne, Swit>erland # )uesseldorf, Oermany # "aris, 0rance # Serlin, Oermany # )ublin, Ireland # Sologna, Italy # 8msterdam, /he 'etherlands # Ishikawa, Eapan # /ainan, /aiwan # Sydney, 8ustralia

>AL- 1(J !T
1ou can add a /istener for a specific c/ass by setting the property value'ob*ect'l& istener -ith a /ist of comma de/imited c/ass names that imp/ement com'liferay'%ortal'& model'ModelListener. ,hese c/asses are poo/ed and reused and must be thread safe.
value.object.listener.com.liferay.portal.model.&ontact com.liferay.portal.model.&ontact!istener value.object.listener.com.liferay.portal.model.!ayout com.liferay.portal.model.!ayout!istener value.object.listener.com.liferay.portal.model.!ayoutSet com.liferay .portal.model.!ayoutSet!istener value.object.listener.com.liferay.portal.model."ortlet"references com.lifera y.portal.model."ortlet"references!istener value.object.listener.com.liferay.portal.model.,ser com.liferay.portal.model.,ser!istener value.object.listener.com.liferay.portlet.journal.model.Eournal8rticle com.l iferay.portlet.journal.model.Eournal8rticle!istener value.object.listener.com.liferay.portlet.journal.model.Eournal/emplate com. liferay.portlet.journal.model.Eournal/emplate!istener

Ba/ue obIects are cached by defau/t. 1ou can disab/e caching for a// obIects or per obIect. 9or mapping tab/es, the .ey is the mapping tab/e itse/f.
value.object.finder.cache.enabled true value.object.finder.cache.enabled.com.liferay.portal.model.!ayout true value.object.finder.cache.enabled.com.liferay.portal.model.,ser true value.object.finder.cache.enabled.,sersLFoles true

!1//-N.!AT.1N L.N2
Set the JGroups properties used by the porta/ to communicate -ith other in) stances of the porta/. ,his is on/y needed if the porta/ is running in a c/ustered envir) onment. ,he JGroups settings provide a mechanism for the porta/ to broadcast mes) sages to the other instances of the porta/. ,he specified mu/ti)cast address shou/d be uniHue for interna/ porta/ messaging on/y. 1ou -i// sti// need to set the ;ibernate and >hcache settings for database c/ustering.

!"!

Advanced Liferay Configuration

Advanced Liferay Configuration


comm.link.properties ,)"AbindLaddr 35T.4.4.37mcastLaddr 523.35.53.3457mcastL port =66??7ipLttl 257mcastLsendLbufLsi>e 3644447mcastLrecvLbufLsi>e 14444B*" I'OAtimeout 54447numLinitialLmembers 2B*$.FO.5AminLinterval 64447ma<Linterval 34444B*0)LSN&Y*K.FI0ZLS,S".&/Atimeout 3644B*pbcast.'8Y8&YAgcLlag 647retransmitLtimeout 244,?44,3544,5=44,=1447ma<L<mitLsi>e 13P5B*,'I&8S/Atimeout 244,?44,3544,5=44B*pbcast.S/8S!.AdesiredLavgLgossip 54444B*0F8OAfragLsi>e 14 P?7downLthread false7upLthread falseB*pbcast.O$SAjoinLtimeout 64447joinLretr yLtimeout 54447shun false7printLlocalLaddr trueB

!1NT NT 0 L.> R5 N

TW1R2

Set the hostname that -i// be used to serve static content via a C=&. ,his prop) erty can be overridden dynamica//y at runtime by setting the ;,,@ parameter cdn/host.
cdn.host

!1-NT R
Set the number of increments bet-een database updates to the Counter tab/e. Set this va/ue to a higher number for better performance.
counter.increment 344

Set the interva/ in minutes for the Connection;earbeatJob. ,his -i// determine ho- often the database is po//ed for /ong running connections and -i// prevent the database from disconnecting the soc.et premature/y.
counter.connection.heartbeat.job.interval ?4

L1!2
Set the /oc. e4piration time for each c/ass. 1xam%le! Day
lock.e<piration.time.com.liferay.portlet.documentlibrary.model.)!0ile.ntry 1 ?=44444

1xam%le! #J Minutes
lock.e<piration.time.com.liferay.portlet.wiki.model.Riki"age 3544444

J(.
Connect to either :u/e or Service:i4 as your >S%. 1xam%les!
jbi.workflow.url http*//localhost*1414/mule-web/workflow jbi.workflow.url http*//localhost*1414/servicemi<-web/workflow

J!R
Liferay inc/udes Jac.rabbit 5http277Iac.rabbit.apache.org6 by defau/t as its JSR) Advanced Liferay Configuration !"8

Advanced Liferay Configuration A'" Java Content Repository.


jcr.initiali>e.on.startup false jcr.workspace.name liferay jcr.node.documentlibrary documentlibrary jcr.jackrabbit.repository.root @Gliferay.homeH/jackrabbit jcr.jackrabbit.config.file.path @Gjcr.jackrabbit.repository.rootH/repository.<ml jcr.jackrabbit.repository.home @Gjcr.jackrabbit.repository.rootH/home jcr.jackrabbit.credentials.username none jcr.jackrabbit.credentials.password none

L.> -S RS
Set this to true to enab/e trac.ing via Live 0sers.
live.users.enabled false

L1!2
Set the /oc. e4piration time for each c/ass. day!
lock.e<piration.time.com.liferay.portlet.documentlibrary.model.)!0older 1?=4 4444 lock.e<piration.time.com.liferay.portlet.documentlibrary.model.)!0ile.ntry 1 ?=44444

#J minutes!
lock.e<piration.time.com.liferay.portlet.wiki.model.Riki"age 3544444

/A.L
Set the J&=$ name to /oo.up the Java :ai/ session. $f none is set, then the porta/ -i// attempt to create the Java :ai/ session based on the properties prefi4ed -ith mail'session.
#mail.session.jndi.name mail/$ailSession

Set the properties used to create the Java :ai/ session. ,he property prefi4 \mai/.session.\ -i// be removed before it is used to create the session obIect. ,hese properties -i// on/y be read if the property mail'session'*ndi'name is not set.
mail.session.mail.imap.host localhost mail.session.mail.pop2.host localhost #mail.session.mail.smtp.auth true mail.session.mail.smtp.host localhost #mail.session.mail.smtp.socket0actory.class java<.net.ssl.SS!Socket0actory #mail.session.mail.smtp.socket0actory.fallback false #mail.session.mail.smtp.socket0actory.port =?6

!"C

Advanced Liferay Configuration

Advanced Liferay Configuration


#mail.session.mail.smtp.starttls.enable true #mail.session.mail.smtp.password #mail.session.mail.smtp.port =?6 #mail.session.mail.smtp.user mail.session.mail.store.protocol localhost mail.session.mail.transport.protocol smtp

Set this to fa/se if administrator shou/d not be a//o-ed to change the mai/ domain via the Admin port/et.
mail.m<.update true

$nput a /ist of comma de/imited emai/ addresses that -i// receive a %CC of every emai/ sent through the mai/ server.
mail.audit.trail

Set the name of a c/ass that imp/ements com'liferay'mail'util'Hoo5. ,he mai/ server -i// use this c/ass to ensure that the mai/ and porta/ servers are synchronized on user information. ,he porta/ -i// not .no- ho- to add, update, or de/ete users from the mai/ server e4cept through this hoo.. Avai/ab/e hoo.s are2 com./iferay.mai/.uti/.Cyrus;oo. com./iferay.mai/.uti/.=ummy;oo. com./iferay.mai/.uti/.9use:ai/;oo. com./iferay.mai/.uti/.Sendmai/;oo. com./iferay.mai/.uti/.She//;oo.

mail.hook.impl com.liferay.mail.util.)ummyMook

!5R-S3112
Set the commands for adding, updating, and de/eting a user -here _A_ is the user id. Rep/ace the pass-ord -ith the pass-ord for the cyrus user.
mail.hook.cyrus.add.user cyrusadmin password create J3J #mail.hook.cyrus.add.user cyrusLadduser password J3J mail.hook.cyrus.delete.user cyrusadmin password delete J3J #mail.hook.cyrus.delete.user cyrusLuserdel password J3J mail.hook.cyrus.home /home/cyrus

*-S /A.L3112
See http277---.fusemai/.com7support7api.htm/ for more information. 1ou must a/so update the mail'account'finder property.
mail.hook.fusemail.url https*//www.fusemail.com/api/re(uest.html mail.hook.fusemail.username mail.hook.fusemail.password

Advanced Liferay Configuration

!"*

Advanced Liferay Configuration


mail.hook.fusemail.account.type groupLsubaccount mail.hook.fusemail.group.parent

S N0/A.L3112
Set the commands for adding, updating, and de/eting a user -here _A_ is the user id and _!_ is the pass-ord. Set the home and virtua/ user tab/e information.
mail.hook.sendmail.add.user adduser J3J -s /bin/false mail.hook.sendmail.change.password autopasswd J3J J5J mail.hook.sendmail.delete.user userdel -r J3J mail.hook.sendmail.home /home mail.hook.sendmail.virtusertable /etc/mail/virtusertable mail.hook.sendmail.virtusertable.refresh bash -c Dmakemap hash /etc/mail/virtusertable 9 /etc/mail/virtusertableD

S3 LL3112
Set the /ocation of the she// script that -i// interface -ith any mai/ server.
mail.hook.shell.script /usr/sbin/mailadmin.ksh

1P N1**.!
>nab/ing ?pen?ffice integration a//o-s the =ocument Library port/et to provide document conversion functiona/ity. ,o start ?pen?ffice as a service, run the com) mand2
soffice -headless -accept Dsocket,host 35T.4.4.3,port 13447urp7D -nofirststartwi>ard

,his is tested -ith ?pen?ffice !.8.4.


openoffice.server.enabled false openoffice.server.host 35T.4.4.3 openoffice.server.port 1344

P1P
Set this to true to enab/e po//ing of emai/ notifications from a @?@ server. ,he user credentia/s are the same used for S:,@ authentication and is specified in the mail+Mail)ession configuration for each app/ication server.
pop.server.notifications.enabled false

Set the interva/ on -hich the @?@&otificationsJob -i// run. ,he va/ue is set in one minute increments.
pop.server.notifications.interval 3

Set this property to create a specia/ :D subdomain to receive a// porta/ re/ated emai/ 5e.g. events./iferay.com6. ,his means configuring a defau/t inbo4 for the domain and receiving a// emai/s into that inbo4.

!"+

Advanced Liferay Configuration

Advanced Liferay Configuration ,his approach may not be a//o-ed for some organizations. $f you cannot use the subdomain approach, unset this va/ue and Liferay -i// use the rep/y,o address spe) cified in the port/et preferences.
pop.server.subdomain events

C-ARTD
,hese properties define the connection to the bui/t)in Fuartz Iob schedu/ing en) gine.
org.(uart>.dataSource.ds.connection"rovider.class com.liferay.portal.scheduler.(uart>.%uart>&onnection"roviderImpl org.(uart>.jobStore.class org.(uart>.impl.jdbcjobstore.EobStore/; org.(uart>.jobStore.dataSource ds org.(uart>.jobStore.driver)elegate&lass com.liferay.portal.scheduler.(uart>.)ynamic)river)elegate org.(uart>.jobStore.is&lustered false org.(uart>.jobStore.misfire/hreshold ?4444 org.(uart>.jobStore.table"refi< %,8F/XL org.(uart>.jobStore.use"roperties true org.(uart>.scheduler.instanceId 8,/N org.(uart>.scheduler.instance'ame %uart>Scheduler.ngineInstance org.(uart>.thread"ool.class org.(uart>.simpl.Simple/hread"ool org.(uart>.thread"ool.thread&ount 6 org.(uart>.thread"ool.thread"riority 6

S!3 0-L R
Set this to fa/se to disab/e a// schedu/er c/asses defined in liferay&%ortlet'xml and in the property scheduler'classes.
scheduler.enabled true

$nput a /ist of comma de/imited c/ass names that imp/ement com'liferay'%ortal'5er& nel'*ob')cheduler. ,hese c/asses a//o- Iobs to be schedu/ed on startup. ,hese c/asses are not associated to any one port/et.
scheduler.classes

AR!3

!1NTA.N R

Set the avai/ab/e va/ues for the number of entries to disp/ay per page. An empty va/ue, or commenting out the va/ue, -i// disab/e de/ta resizing. ,he defau/t of !" -i// app/y in a// cases. A/-ays inc/ude !", since it is the defau/t page size -hen no de/ta is specified. ,he abso/ute ma4imum a//o-ed de/ta is !"".
search.container.page.delta.values 6,34,54,24,64,T6

Advanced Liferay Configuration

!"'

Advanced Liferay Configuration

S3AR P1.NT
Set the to.ens for supported Sharepoint storage paths.
sharepoint.storage.tokens documentLlibrary

Set the c/ass names for supported Sharepoint storage c/asses.


sharepoint.storage.classUdocumentLlibraryV com.liferay.portlet.documentlibrary.sharepoint.)!SharepointStorageImpl

S1!.AL (112/AR2S
,he %/ogs port/et a//o-s for the posting of entries to various popu/ar socia/ boo.) mar.ing sites. ,he e4amp/e ones are the defau/tsU to configure more, Iust add the site in the format be/o-.
social.bookmark.types blinklist,delicious,digg,furl,newsvine,reddit,technorati social.bookmark.post.urlUblinklistV http*//blinklist.com/inde<.php+ 8ction Slink/addblink.php-url @Gliferay*social-bookmark*urlH-/itle @ Gliferay*social-bookmark*titleH social.bookmark.post.urlUdeliciousV http*//del.icio.us/post+url @ Gliferay*social-bookmark*urlH-title @Gliferay*social-bookmark*titleH social.bookmark.post.urlUdiggV http*//digg.com/submit+phase 5-url @ Gliferay*social-bookmark*urlH social.bookmark.post.urlUfurlV http*//furl.net/storeIt.jsp+u @Gliferay*social-bookmark*urlH-t @Gliferay*social-bookmark*titleH social.bookmark.post.urlUnewsvineV http*//www.newsvine.com/Ltools/seed-save+ u @Gliferay*social-bookmark*urlH-h @Gliferay*social-bookmark*titleH social.bookmark.post.urlUredditV http*//reddit.com/submit+url @Gliferay*social-bookmark*urlH-title @Gliferay*social-bookmark*titleH social.bookmark.post.urlUtechnoratiV http*//technorati.com/cosmos/search.htm l+url @Gliferay*social-bookmark*urlH

> L1!.T5

NG.N

$nput a /ist of comma de/imited c/ass names that e4tend com'liferay'util'velo& city'<elocity9esourceListener. ,hese c/asses -i// run in seHuence to a//o- you to find the app/icab/e ResourceLoader to /oad a Be/ocity temp/ate.
velocity.engine.resource.listeners com.liferay.portal.velocity.ServletKelocityFesource!istener,com.liferay.portal.velocity.Eournal/emplateKelocityFesource!istener,com.liferay.portal.velocity./heme!oaderKelocityFesource!istener,com.liferay.portal.velocity.&lass!oaderKelocityFesource!istener

Set the Be/ocity resource managers. <e e4tend the Be/ocity's defau/t resource managers for better sca/abi/ity. &ote that the modification chec. interva/ is not respected because the resource /oader imp/ementation does not .no- the /ast modified date of a resource. ,his means you -i// need to turn off caching if you -ant to be ab/e to modify B: temp/ates in themes and see the changes right a-ay.
velocity.engine.resource.manager com.liferay.portal.velocity.!iferayFesource$anager

!"(

Advanced Liferay Configuration

Advanced Liferay Configuration


velocity.engine.resource.manager.cache com.liferay.portal.velocity.!iferayFesource&ache velocity.engine.resource.manager.cache.enabled true #velocity.engine.resource.manager.modification.check.interval 4

$nput a /ist of comma de/imited macros that -i// be /oaded. ,hese fi/es must e4ist in the c/ass path.
velocity.engine.velocimacro.library K$LglobalLlibrary.vm,K$Lliferay.vm

Set the Be/ocity /ogging configuration.


velocity.engine.logger org.apache.velocity.runtime.log.Simple!og=E!ogSystem velocity.engine.logger.category org.apache.velocity

>.RT-AL 31STS
Set the hosts that -i// be ignored for virtua/ hosts.
virtual.hosts.ignore.hosts \ 35T.4.4.3,\ localhost

Set the paths that -i// be ignored for virtua/ hosts.


virtual.hosts.ignore.paths \ /c,\ \ /c/portal/changeLpassword,\ /c/portal/e<tendLsession,\ /c/portal/e<tendLsessionLconfirm,\ /c/portal/jsonLservice,\ /c/portal/layout,\ /c/portal/login,\ /c/portal/logout,\ /c/portal/portletLurl,\ /c/portal/renderLportlet,\ /c/portal/reverseLaja<,\ /c/portal/sessionLtreeLjsLclick,\ /c/portal/status,\ /c/portal/updateLlayout,\ /c/portal/updateLtermsLofLuse,\ /c/portal/uploadLprogressLpoller,\ \ /c/layoutLconfiguration/templates,\ /c/layoutLmanagement/updateLpage

3TTP
See system'%ro%erties for more ;,,@ settings.

Advanced Liferay Configuration

!"#

Advanced Liferay Configuration Set the ma4imum number of connections.


#com.liferay.portal.util.MttpImpl.ma<.connections.per.host 5 #com.liferay.portal.util.MttpImpl.ma<.total.connections 54

Set the pro4y authentication type.


#com.liferay.portal.util.MttpImpl.pro<y.auth.type username-password #com.liferay.portal.util.MttpImpl.pro<y.auth.type ntlm

Set user name and pass-ord used for ;,,@ pro4y authentication.
#com.liferay.portal.util.MttpImpl.pro<y.username #com.liferay.portal.util.MttpImpl.pro<y.password

Set additiona/ properties for &,L: authentication.


#com.liferay.portal.util.MttpImpl.pro<y.ntlm.domain #com.liferay.portal.util.MttpImpl.pro<y.ntlm.host

Set the connection timeout -hen fetching ;,,@ content.


com.liferay.portal.util.MttpImpl.timeout 34444

R>L T

*.LT RS

,he cache fi/ter -i// cache content. See ehcache'xml to modify the cache e4pira) tion time to /ive.
com.liferay.portal.servlet.filters.cache.&ache0ilter true

,his doub/e c/ic. fi/ter -i// prevent doub/e c/ic.s at the server side. @revention of doub/e c/ic.s is a/ready in p/ace on the c/ient side. ;o-ever, some sites reHuire a more robust so/ution. ,his is turned off by defau/t since most sites -i// not need it.
com.liferay.portal.servlet.filters.doubleclick.)ouble&lick0ilter false

$f the user can unzip compressed ;,,@ content, the GGip fi/ter -i// zip up the ;,,@ content before sending it to the user. ,his -i// speed up page rendering for users that are on dia/ up.
com.liferay.portal.servlet.filters.g>ip.OXip0ilter true

,he header fi/ter is used to set reHuest headers.


com.liferay.portal.servlet.filters.header.Meader0ilter true

,he minifier fi/ter is used to minify CSS and JavaScript.


com.liferay.portal.servlet.filters.minifier.$inifier0ilter true

,he strip fi/ter -i// remove b/an. /ines from the content. ,his -i// speed up page rendering for users that are on dia/ up.
com.liferay.portal.servlet.filters.strip.Strip0ilter true

,he /ayout cache fi/ter -i// cache pages to speed up page rendering for guest users. See ehcache'xml to modify the cache e4piration time to /ive.
com.liferay.portal.servlet.filters.layoutcache.!ayout&ache0ilter true

!A"

Advanced Liferay Configuration

Advanced Liferay Configuration ,he session id fi/ter ensure that on/y one session is created bet-een http and ht) tps sessions. ,his is usefu/ if you -ant users to /ogin via https but have them vie- the rest of the site via http. ,his is disab/ed by defau/t. =o not enab/e this un/ess you thor) ough/y understand ho- coo.ies, http, and https -or..
com.liferay.portal.servlet.filters.sessionid.SessionId0ilter false

,he Be/ocity fi/ter -i// process `7css7main.css as a Be/ocity temp/ate.


com.liferay.portal.servlet.filters.velocity.Kelocity0ilter false

,he virtua/ host fi/ter maps hosts to pub/ic and private pages. 9or e4amp/e, if the pub/ic virtua/ host is ---.he//o-or/d.com and the friend/y 0RL is 7he//o-or/d, then http277---.he//o-or/d.com is mapped to http277/oca/host2("("7-eb7he//o-or/d.
com.liferay.portal.servlet.filters.virtualhost.KirtualMost0ilter true

-PL1A0 S R>L T R C- ST
Set the ma4imum fi/e size. =efau/t is A"!C ` A"!C ` A"".
com.liferay.portal.upload.,ploadServletFe(uestImpl.ma<.si>e 34=16T?44

Set the temp directory for up/oaded fi/es.


#com.liferay.portal.upload.,ploadServletFe(uestImpl.temp.dir &*//emp

Set the thresho/d size to prevent e4traneous seria/ization of up/oaded data.


com.liferay.portal.upload.!iferay0ileItem.threshold.si>e 5?53==

Set the thresho/d size to prevent out of memory e4ceptions caused by caching e4cessive/y /arge up/oaded data. =efau/t is A"!C ` A"!C ` A".
com.liferay.portal.upload.!iferayInputStream.threshold.si>e 34=16T?4

W ( S R>

Set the ;,,@ and ;,,@s ports -hen running the porta/ in a J!>> server that is sitting behind another -eb server /i.e Apache. Set the va/ues to )A if the porta/ is not running behind another -eb server /i.e Apache.
web.server.http.port -3 web.server.https.port -3

Set the hostname that -i// be used -hen the port/et generates 0RLs. Leaving this b/an. -i// mean the host is derived from the serv/et container.
web.server.host

Set the preferred protoco/.


web.server.protocol https

Set this to true to disp/ay the server name at the bottom of every page. ,his is usefu/ -hen testing c/ustering configurations so that you can .no- -hich node you are accessing.

Advanced Liferay Configuration

!AA

Advanced Liferay Configuration


web.server.display.node false

W (0A>
Set the fo//o-ing to true to enab/e programmatic configuration to /et the <eb) =AB be configured for /itmus testing. ,his shou/d never be set to true un/ess you are running the /itmus tests.
webdav.litmus false

Set a /ist of fi/es for the <eb=AB serv/et to ignore processing.


webdav.ignore .)SLStore,.metadataLinde<LhomesLonly,.metadataLneverLinde<,.Sp otlight-K344,./emporaryItems,./rashes

/A.N S R>L T
Serv/ets can be protected by com'liferay'%ortal'servlet'filters'secure')ecure(ilter. $nput a /ist of comma de/imited $@s that can access this serv/et. $nput a b/an. /ist to a//o- any $@ to access this serv/et. S>RB>RM$@ -i// be rep/aced -ith the $@ of the host server.
main.servlet.hosts.allowed

Set the fo//o-ing to true if this serv/et can on/y be accessed via https.
main.servlet.https.re(uired false

A4.S S R>L T
See :ain Serv/et on ho- to protect this serv/et.
a<is.servlet.hosts.allowed 35T.4.4.3,S.FK.FLI" a<is.servlet.https.re(uired false

JS1N T-NN L S R>L T


See :ain Serv/et on ho- to protect this serv/et.
json.servlet.hosts.allowed json.servlet.https.re(uired false

L.* RA5 T-NN L S R>L T


See :ain Serv/et on ho- to protect this serv/et.
tunnel.servlet.hosts.allowed 35T.4.4.3,S.FK.FLI" tunnel.servlet.https.re(uired false

SPR.NG R /1T.NG S R>L T


See :ain Serv/et on ho- to protect this serv/et. !A! Advanced Liferay Configuration

Advanced Liferay Configuration


spring.remoting.servlet.hosts.allowed 35T.4.4.3,S.FK.FLI" spring.remoting.servlet.https.re(uired false

W (0A> S

R>L T

See :ain Serv/et on ho- to protect this serv/et.


webdav.servlet.hosts.allowed webdav.servlet.https.re(uired false

W.0G T S R>L T
Set the serv/et mapping for the -idget serv/et.
widget.servlet.mapping /widget

A0/.N P1RTL T
1ou can set some administrative defau/ts by using these properties. ,he first time you bring up your porta/, these va/ues -i// then a/ready be set in the Admin port/et. A// va/ues shou/d be separated by Rn characters. Set up defau/t group names.
admin.default.group.names

Set up defau/t ro/e names.


admin.default.role.names "ower ,ser\n,ser

Set up defau/t user group names.


admin.default.user.group.names

,he rest of these properties map to their va/ues in the Admin port/et.
admin.mail.host.names admin.reserved.screen.names admin.reserved.email.addresses admin.email.from.name Eoe Sloggs admin.email.from.address testIliferay.com admin.email.user.added.enabled true admin.email.user.added.subject com/liferay/portlet/admin/dependencies/emailL userLaddedLsubject.tmpl admin.email.user.added.body com/liferay/portlet/admin/dependencies/emailLuse rLaddedLbody.tmpl admin.email.password.sent.enabled true admin.email.password.sent.subject com/liferay/portlet/admin/dependencies/ema ilLpasswordLsentLsubject.tmpl admin.email.password.sent.body com/liferay/portlet/admin/dependencies/emailL passwordLsentLbody.tmpl

Advanced Liferay Configuration

!A8

Advanced Liferay Configuration

ANN1-N! / NTS P1RTL T


Configure emai/ notification settings.
announcements.email.from.name Eoe Sloggs announcements.email.from.address testIliferay.com announcements.email.to.name announcements.email.to.address noreplyIliferay.com announcements.email.subject com/liferay/portlet/announcements/dependencies/e mailLsubject.tmpl announcements.email.body com/liferay/portlet/announcements/dependencies/emai lLbody.tmpl

Set the /ist of announcement types. ,he disp/ay te4t of each of the announce) ment types is set in content7Language.properties.
announcements.entry.types general,news,test

Set the interva/ on -hich the Chec.>ntryJob -i// run. ,he va/ue is set in one minute increments.
announcements.entry.check.interval 36

ASS T P-(L.S3 R P1RTL T


$nput a /ist of comma separated disp/ay sty/es that -i// be avai/ab/e in the config) uration screen of Asset @ub/isher port/et.
asset.publisher.display.styles table,title-list,abstracts,full-content

(L1GS P1RTL T
,he fo//o-ing properties affect the %/ogs port/et.
blogs.email.comments.added.enabled true blogs.email.comments.added.subject com/liferay/portlet/blogs/dependencies/em ailLcommentsLaddedLsubject.tmpl blogs.email.comments.added.body com/liferay/portlet/blogs/dependencies/email LcommentsLaddedLbody.tmpl blogs.page.abstract.length =44 blogs.rss.abstract.length 544 blogs.trackback.e<cerpt.length 64

Set the interva/ on -hich the ,rac.bac.BerifierJob -i// run. ,he va/ue is set in one minute increments.
blogs.trackback.verifier.job.interval 6

!AL N0AR P1RTL T


Set the /ist of event types. ,he disp/ay te4t of each of the event types is set in con& tent+Language'%ro%erties.
calendar.event.types anniversary,appointment,bill-payment,birthday,breakfast,call,chat,class,club-event,concert,dinner,event,graduation,happy-

!AC

Advanced Liferay Configuration

Advanced Liferay Configuration


hour,holiday,interview,lunch,meeting,movie,net-event,other,party,performance,press-release,reunion,sports-event,training,travel,tvshow,vacation,wedding

Set the interva/ on -hich the Chec.>ventJob -i// run. ,he va/ue is set in one minute increments.
calendar.event.check.interval 36

Configure emai/ notification settings.


calendar.email.from.name Eoe Sloggs calendar.email.from.address testIliferay.com calendar.email.event.reminder.enabled true calendar.email.event.reminder.subject com/liferay/portlet/calendar/dependencies/emailLeventLreminderLsubject.tmpl calendar.email.event.reminder.body com/liferay/portlet/calendar/dependencies/emailLeventLreminderLbody.tmpl

!1//-N.T. S P1RTL T
Configure emai/ notification settings.
communities.email.from.name Eoe Sloggs communities.email.from.address testIliferay.com communities.email.membership.reply.subject com/liferay/portlet/communities/d ependencies/emailLmembershipLreplyLsubject.tmpl communities.email.membership.reply.body com/liferay/portlet/communities/dependencies/emailLmembershipLreplyLbody.tmpl communities.email.membership.re(uest.subject com/liferay/portlet/communities /dependencies/emailLmembershipLre(uestLsubject.tmpl communities.email.membership.re(uest.body com/liferay/portlet/communities/de pendencies/emailLmembershipLre(uestLbody.tmpl

01!-/ NT L.(RAR5 P1RTL T


Set the name of a c/ass that imp/ements com'liferay'documentlibrary'util'Hoo5. ,he document /ibrary server -i// use this to persist documents. Avai/ab/e hoo.s are2 1xam%les! com./iferay.document/ibrary.uti/.9i/eSystem;oo. com./iferay.document/ibrary.uti/.JCR;oo. com./iferay.document/ibrary.uti/.S8;oo.

#dl.hook.impl com.liferay.documentlibrary.util.8dvanced0ileSystemMook dl.hook.impl com.liferay.documentlibrary.util.0ileSystemMook #dl.hook.impl com.liferay.documentlibrary.util.E&FMook #dl.hook.impl com.liferay.documentlibrary.util.S2Mook

Advanced Liferay Configuration

!A*

Advanced Liferay Configuration

*.L S5ST /3112


dl.hook.file.system.root.dir @Gliferay.homeH/documentLlibrary

S93112
dl.hook.s2.access.key dl.hook.s2.secret.key dl.hook.s2.bucket.name

Set the ma4imum fi/e size and va/id fi/e e4tensions for documents. A va/ue of " for the ma4imum fi/e size can be used to indicate un/imited fi/e size. ;o-ever, the ma4imum fi/e size a//o-ed is set in the property com'liferay'%ortal'u%load'U%load)er& vlet9e7uestIm%l'max'siLe. 1xam%les!
#dl.file.ma<.si>e 24T544 #dl.file.ma<.si>e 345=444 dl.file.ma<.si>e 24T5444

A fi/e e4tension of ` -i// permit a// fi/e e4tensions. 1ou can map a G$9 for the e4tension by adding the image to the theme's image disp/ay and document /ibrary fo/der. ,he -i/dcard e4tension of ` -i// be ignored. 9or e4amp/e, the defau/t image for the =?C e4tension -ou/d be found in2 +html+themes+/unstyled+images+document/library+doc'gif. 1xam%le (ile 1xtensions!
dl.file.e<tensions .bmp,.css,.doc,.dot,.gif,.g>,.htm,.html,.jpg,.js,.lar,.od b,.odf,.odg,.odp,.ods,.odt,.pdf,.png,.ppt,.rtf,.swf,.s<c,.s<i,.s<w,.tar,.tif f,.tg>,.t<t,.vsd,.<ls,.<ml,.>ip

Set -hich fi/es e4tensions are comparab/e by the diff too/. $f ?pen?ffice integra) tion is enab/ed, then it is a/so possib/e to compare some binary fi/es that are can be converted to te4t.
dl.comparable.file.e<tensions .css,.js,.htm,.html,.t<t,.<ml #dl.comparable.file.e<tensions .css,.doc,.js,.htm,.html,.odt,.rtf,.s<w,.t<t, .<ml

Set fo/der names that -i// be used to synchronize -ith a community's set of private and pub/ic /ayouts. ,his -i// a//o- users to manage /ayouts using the =ocu) ment Library port/et, and u/timate/y, via <eb=AB. ,his feature is e4perimenta/.
dl.layouts.sync.enabled false dl.layouts.sync.private.folder "ages - "rivate dl.layouts.sync.public.folder "ages - "ublic

./AG GALL R5 P1RTL T


Set the ma4imum fi/e size and va/id fi/e e4tensions for images. A va/ue of " for the ma4imum fi/e size can be used to indicate un/imited fi/e size. ;o-ever, the ma4) imum fi/e size a//o-ed is set in the property com'liferay'%ortal'u%load'U%load)ervlet9e&

!A+

Advanced Liferay Configuration

Advanced Liferay Configuration 7uestIm%l'max'siLe.


ig.image.ma<.si>e 345=4444

A fi/e e4tension of ` -i// permit a// fi/e e4tensions.


ig.image.e<tensions .bmp,.gif,.jpeg,.jpg,.png,.tif,.tiff

Set the ma4imum thumbnai/ height and -idth in pi4e/s. Set dimension of the custom images to " to disab/e creating a sca/ed image of that size.
ig.image.thumbnail.ma<.dimension 364 #ig.image.custom3.ma<.dimension 344 #ig.image.custom5.ma<.dimension 4

.N>.TAT.1N P1RTL T
invitation.email.ma<.recipients 54 invitation.email.message.body com/liferay/portlet/invitation/dependencies/em ailLmessageLbody.tmpl invitation.email.message.subject com/liferay/portlet/invitation/dependencies/emailLmessageLsubject.tmpl

J1-RNAL P1RTL T
Set this to true if artic/e ids shou/d a/-ays be autogenerated.
journal.article.force.autogenerate.id true

Set this to true so that on/y the /atest version of an artic/e that is a/so not ap) proved can be saved -ithout incrementing version.
journal.article.force.increment.version false

Set the /ist of artic/e types. ,he disp/ay te4t of each of the artic/e types is set in content7Language.properties.
journal.article.types announcements,blogs,general,news,press-release,test

Set the to.en used -hen inserting simp/e page brea.s in artic/es.
journal.article.token.page.break IpageLbreakI

Set the interva/ on -hich the Chec.Artic/eJob -i// run. ,he va/ue is set in one minute increments.
journal.article.check.interval 36

Set this to true to chec. that a user has the B$>< permission on a Journa/ artic/e -hen its content is rendered.
journal.article.view.permission.check.enabled false

Set this to true if feed ids shou/d a/-ays be autogenerated.


journal.feed.force.autogenerate.id false

Set this to true if structure ids shou/d a/-ays be autogenerated. Advanced Liferay Configuration !A'

Advanced Liferay Configuration


journal.structure.force.autogenerate.id false

Set this to true if temp/ate ids shou/d a/-ays be autogenerated.


journal.template.force.autogenerate.id false

$nput a comma de/imited /ist of variab/es -hich are restricted from the conte4t in Be/ocity based Journa/ temp/ates.
journal.template.velocity.restricted.variables service!ocator

Set the ma4imum fi/e size and va/id fi/e e4tensions for images. A va/ue of " for the ma4imum fi/e size can be used to indicate un/imited fi/e size. ;o-ever, the ma4) imum fi/e size a//o-ed is set in the property com'liferay'%ortal'u%load'U%load)ervlet9e& 7uestIm%l'max'siLe.
journal.image.small.ma<.si>e 63544

A fi/e e4tension of ` -i// permit a// fi/e e4tensions.


journal.image.e<tensions .gif,.jpeg,.jpg,.png

$nput a /ist of comma de/imited c/ass names that e4tend com'liferay'%ortlet'*ourn& al'util'4ransformerListener. ,hese c/asses -i// run in seHuence to a//o- you to modify the D:L and DSL before it's transformed and a//o- you to modify the fina/ output.
journal.transformer.listener \ com.liferay.portlet.journal.util./okens/ransformer!istener,\ #com.liferay.portlet.journal.util."roperties/ransformer!istener,\ com.liferay.portlet.journal.util.&ontent/ransformer!istener,\ com.liferay.portlet.journal.util.!ocale/ransformer!istener,\ com.liferay.portlet.journal.util.Fege</ransformer!istener,\ com.liferay.portlet.journal.util.Kiew&ounter/ransformer!istener

>nter a /ist of regu/ar e4pression patterns and rep/acements that -i// be app/ied to outputted Journa/ content. ,he /ist of properties must end -ith a subseHuent in) teger 5", A, etc.6 and it is assumed that the /ist has reached an end -hen the pattern or rep/acement is not set. See com'liferay'%ortlet'*ournal'util'9egex4ransformerListener for imp/ementation detai/s.
#journal.transformer.rege<.pattern.4 beta.sample.com #journal.transformer.rege<.replacement.4 production.sample.com #journal.transformer.rege<.pattern.3 staging.sample.com #journal.transformer.rege<.replacement.3 production.sample.com

Set -hether to synchronize content searches -hen server starts.


journal.sync.content.search.on.startup false

Configure mai/ notification settings.


journal.email.from.name Eoe Sloggs journal.email.from.address testIliferay.com journal.email.article.approval.denied.enabled false journal.email.article.approval.denied.subject com/liferay/portlet/journal/de pendencies/emailLarticleLapprovalLdeniedLsubject.tmpl journal.email.article.approval.denied.body com/liferay/portlet/journal/dependencies/emailLarticleLapprovalLdeniedLbody.tmpl

!A(

Advanced Liferay Configuration

Advanced Liferay Configuration


journal.email.article.approval.granted.enabled false journal.email.article.approval.granted.subject com/liferay/portlet/journal/d ependencies/emailLarticleLapprovalLgrantedLsubject.tmpl journal.email.article.approval.granted.body com/liferay/portlet/journal/dependencies/emailLarticleLapprovalLgrantedLbody.tmpl journal.email.article.approval.re(uested.enabled false journal.email.article.approval.re(uested.subject com/liferay/portlet/journal /dependencies/emailLarticleLapprovalLre(uestedLsubject.tmpl journal.email.article.approval.re(uested.body com/liferay/portlet/journal/de pendencies/emailLarticleLapprovalLre(uestedLbody.tmpl journal.email.article.review.enabled false journal.email.article.review.subject com/liferay/portlet/journal/dependencies/emailLarticleLreviewLsubject.tmpl journal.email.article.review.body com/liferay/portlet/journal/dependencies/e mailLarticleLreviewLbody.tmpl

tem.

Specify the strategy used -hen Journa/ content is imported using the LAR sys)

journal.lar.creation.strategy com.liferay.portlet.journal.lar.Eournal&reationStrategyImpl

Specify the path to the temp/ate used for providing error messages on Journa/ temp/ates.
journal.error.template.velocity com/liferay/portlet/journal/dependencies/error.vm journal.error.template.<sl com/liferay/portlet/journal/dependencies/error.<sl

J1-RNAL ART.!L S P1RTL T


Set the avai/ab/e va/ues for the number of artic/es to disp/ay per page.
journal.articles.page.delta.values 6,34,56,64,344

J1-RNAL !1NT NT S AR!3 P1RTL T


Set -hether un/isted artic/es are e4c/uded from search resu/ts.
journal.content.search.show.listed true

/ SSAG (1AR0S P1RTL T


Configure mai/ notification settings.
message.boards.email.from.name Eoe Sloggs message.boards.email.from.address testIliferay.com message.boards.email.html.format true message.boards.email.message.added.enabled true message.boards.email.message.added.subject.prefi< com/liferay/portlet/messageboards/dependencies/emailLmessageLaddedLsubjectLprefi<.tmpl message.boards.email.message.added.body com/liferay/portlet/messageboards/de pendencies/emailLmessageLaddedLbody.tmpl message.boards.email.message.added.signature com/liferay/portlet/message-

Advanced Liferay Configuration

!A#

Advanced Liferay Configuration


boards/dependencies/emailLmessageLaddedLsignature.tmpl message.boards.email.message.updated.enabled true message.boards.email.message.updated.subject.prefi< com/liferay/portlet/messageboards/dependencies/emailLmessageLupdatedLsubjectLprefi<.tmpl message.boards.email.message.updated.body com/liferay/portlet/messageboards/ dependencies/emailLmessageLupdatedLbody.tmpl message.boards.email.message.updated.signature com/liferay/portlet/messageboards/dependencies/emailLmessageLupdatedLsignature.tmpl

Set this to true to a//o- anonymous posting.


message.boards.anonymous.posting.enabled true

>nter time in minutes on ho- often this Iob is run. $f a user's ban is set to e4pire at A!2"* @: and the Iob runs at ! @:, the e4pire -i// occur during the ! @: run.
message.boards.e<pire.ban.job.interval 354

>nter time in days to automatica//y e4pire bans on users. Set to " to disab/e auto e4pire. 1xam%les!
message.boards.e<pire.ban.interval 34 message.boards.e<pire.ban.interval 4

>nter rss feed abstract /ength. ,his va/ue /imits -hat goes in the RSS feed from the beginning of the message board post. ,he defau/t is the first !"" characters.
message.boards.rss.abstract.length 544

/5 PLA! S P1RTL T
Set this to true to sho- user pub/ic sites -ith no /ayouts.
my.places.show.user.public.sites.with.no.layouts true

Set this to true to sho- user private sites -ith no /ayouts.


my.places.show.user.private.sites.with.no.layouts true

Set this to true to sho- organization pub/ic sites -ith no /ayouts.


my.places.show.organi>ation.public.sites.with.no.layouts true

Set this to true to sho- organization private sites -ith no /ayouts.


my.places.show.organi>ation.private.sites.with.no.layouts true

Set this to true to sho- community pub/ic sites -ith no /ayouts.


my.places.show.community.public.sites.with.no.layouts true

Set this to true to sho- community private sites -ith no /ayouts.


my.places.show.community.private.sites.with.no.layouts true

Set the ma4imum number of e/ements that -i// be sho-n in the :y @/aces navig) ation menu. 9or e4amp/e, if the ma4imum is set to A", then, at most, A persona/ com) munity, A" organizations, and A" communities -i// be sho-n.

!!"

Advanced Liferay Configuration

Advanced Liferay Configuration


my.places.ma<.elements 34

NA>.GAT.1N P1RTL T
Specify the options that -i// be provided to the user in the edit configuration mode of the port/et.
navigation.display.style.options 3,5,2,=,6,?

=efine each mode -ith C comma de/imited strings that represent the form2 header) ,ype, rootLayout,ype, rootLayoutLeve/, inc/udedLayouts, and nestedChi/dren.
navigation.display.styleU3V breadcrumb,relative,4,auto,true navigation.display.styleU5V root-layout,absolute,5,auto,true navigation.display.styleU2V root-layout,absolute,3,auto,true navigation.display.styleU=V none,absolute,3,auto,true navigation.display.styleU6V none,absolute,3,all,true navigation.display.styleU?V none,absolute,4,auto,true

N ST 0 P1RTL TS P1RTL T
nested.portlets.layout.template.default 5LcolumnsLi

Add a comma separated /ist of /ayout temp/ate ids that shou/d not be a//o-ed in the &ested @ort/ets @ort/et.
nested.portlets.layout.template.unsupported freeform,3Lcolumn

P1RTL T !SS P1RTL T


Set this to true to enab/e the abi/ity to modify port/et CSS at runtime via the Loo. and 9ee/ icon. =isab/ing it can speed up performance.
portlet.css.enabled true

S31PP.NG P1RTL T
Set the fo//o-ing to true if cart Huantities must be a mu/tip/e of the item's min) imum Huantity.
shopping.cart.min.(ty.multiple true

Set the fo//o-ing to true to for-ard to the cart page -hen adding an item from the category page. ,he item must not have dynamic fie/ds. A// items -ith dynamic fie/ds -i// for-ard to the item's detai/s page regard/ess of the fo//o-ing setting.
shopping.category.forward.to.cart false

Set the fo//o-ing to true to sho- specia/ items -hen bro-sing a category.
shopping.category.show.special.items false

Set the fo//o-ing to true to sho- avai/abi/ity -hen vie-ing an item.


shopping.item.show.availability true

Advanced Liferay Configuration

!!A

Advanced Liferay Configuration Set the ma4imum fi/e size and va/id fi/e e4tensions for images. A va/ue of " for the ma4imum fi/e size can be used to indicate un/imited fi/e size. ;o-ever, the ma4) imum fi/e size a//o-ed is set in the property com'liferay'%ortal'u%load'U%load)ervlet9e& 7uestIm%l'max'siLe.
shopping.image.small.ma<.si>e 63544 shopping.image.medium.ma<.si>e 362?44 shopping.image.large.ma<.si>e 24T544

A fi/e e4tension of ` -i// permit a// fi/e e4tensions.


shopping.image.e<tensions .gif,.jpeg,.jpg,.png

Configure emai/ notification settings.


shopping.email.from.name Eoe Sloggs shopping.email.from.address testIliferay.com shopping.email.order.confirmation.enabled true shopping.email.order.confirmation.subject com/liferay/portlet/shopping/dependencies/emailLorderLconfirmationLsubject.tmpl shopping.email.order.confirmation.body com/liferay/portlet/shopping/dependencies/emailLorderLconfirmationLbody.tmpl shopping.email.order.shipping.enabled true shopping.email.order.shipping.subject com/liferay/portlet/shopping/dependencies/emailLorderLshippingLsubject.tmpl shopping.email.order.shipping.body com/liferay/portlet/shopping/dependencies/emailLorderLshippingLbody.tmpl

S1*TWAR !ATAL1G P1RTL T


Set the ma4imum fi/e size and ma4 fi/e dimensions for thumbnnai/s. A va/ue of " for the ma4imum fi/e size can be used to indicate un/imited fi/e size. ;o-ever, the ma4imum fi/e size a//o-ed is set in the property com'liferay'%ortal'u%load'U%load)er& vlet9e7uestIm%l'max'siLe.
sc.image.ma<.si>e 24T544 sc.image.thumbnail.ma<.height 544 sc.image.thumbnail.ma<.width 3?4

TAGS !1/P.L R P1RTL T


Set this to true to enab/e the abi/ity to compi/e tags from the 0RL. =isab/ing it can speed up performance.
tags.compiler.enabled true

TAGS P1RTL T
$nput a c/ass name that imp/ements com'liferay'%ortlet'tags'util'4agsAsset<alidator. ,his c/ass -i// be ca//ed to va/idate assets. ,he =efau/t,agsAssetBa/idator c/ass is Iust an empty c/ass that doesn't actua//y do any va/idation. ,he :inima/,agsAssetBa/idator reHuires a// assets to have at /east one tag entry.

!!!

Advanced Liferay Configuration

Advanced Liferay Configuration 1xam%les!


tags.asset.validator com.liferay.portlet.tags.util.)efault/ags8ssetKalidator #tags.asset.validator com.liferay.portlet.tags.util.$inimal/ags8ssetKalidator

$nput a /ist of comma de/imited defau/t properties for ne- tag entries. >ach item of the /ist shou/d have the fo//o-ing format2 J!5ey!value
tags.properties.default

Set the name of the defau/t tag set -here ne- tags are created by defau/t.
tags.vocabulary.default )efault /ag Set

TAS2S P1RTL T
Specify the defau/t number of approva/ stages.
tasks.default.stages 5

Specify the defau/t ro/e name for each stage of approva/ ordered from /o-est /eve/ of approva/ to highest. ,hese Ro/es must have the A@@R?B>M@R?@?SAL permis) sion.
tasks.default.role.names &ommunity 8dministrator,&ommunity Nwner

TRANSLAT1R P1RTL T
Set the defau/t /anguages to trans/ate a given te4t.
translator.default.languages enLes

W.2. P1RTL T
Set the 0RL of a page that contains more information about the c/assic synta4 of the -i.i. $t -i// be sho-n to the user -hen editing a page.
wiki.classic.synta<.help.url http*//wiki.liferay.com/inde<.php/RikiL"ortlet

Set the name of the defau/t page for a -i.i node. ,he name for the defau/t page must be a va/id -i.i -ord. A -i.i -ord fo//o-s the format of having an upper case /et) ter fo//o-ed by a series of /o-er case /etters fo//o-ed by another upper case /etter and another series of /o-er case /etters. See http277---.usemod.com7cgi)bin7-i.i.p/J <hat$sa<i.i for more information on -i.i naming conventions.
wiki.front.page.name 0ront"age

Set the name of the defau/t node that -i// be automatica//y created -hen the <i.i port/et is first used in a community.
wiki.initial.node.name $ain

Set the fo//o-ing property to specify the reHuirments for the names of -i.i pages. %y defau/t on/y a fe- characters are forbidden. 0ncomment the regu/ar e4) pression be/o- to a//o- on/y Came/Case tit/es.

Advanced Liferay Configuration

!!8

Advanced Liferay Configuration


wiki.page.titles.rege<p AU[/\\U\\VJ-+IV\B #wiki.page.titles.rege<p AAA\\pG!uH\\pG!lH\BL+B\B

Set the fo//o-ing property to specify the characters that -i// be automatica//y re) moved from the tit/es -hen importing -i.i pages. ,his rege4p shou/d remove any characters that are forbidden in the rege4p specified in -i.i.page.tit/es.rege4p.
wiki.page.titles.remove.rege<p AU/\\U\\VJ-+IV\B

Set the /ist of supported -i.i formats and the defau/t -i.i format.
wiki.formats creole,html wiki.formats.default creole

Configure settings for each of the -i.i formats.


wiki.formats.engineUclassicLwikiV com.liferay.portlet.wiki.engines.friki.0riki.ngine wiki.formats.configuration.mainUclassicLwikiV wiki.transform wiki.formats.configuration.interwikiUclassicLwikiV intermap.t<t wiki.formats.edit.pageUclassicLwikiV /html/portlet/wiki/edit/wiki.jsp wiki.formats.help.pageUclassicLwikiV /html/portlet/wiki/help/classicLwiki.js p wiki.formats.help.urlUclassicLwikiV http*//wiki.liferay.com/inde<.php/RikiL" ortlet

wiki.formats.engineUcreoleV com.liferay.portlet.wiki.engines.jspwiki.ES"Riki.ngine wiki.formats.configuration.mainUcreoleV jspwiki.properties wiki.formats.edit.pageUcreoleV /html/portlet/wiki/edit/wiki.jsp wiki.formats.help.pageUcreoleV /html/portlet/wiki/help/creole.jsp wiki.formats.help.urlUcreoleV http*//www.wikicreole.org/wiki/&reole3.4

wiki.formats.engineUhtmlV com.liferay.portlet.wiki.engines.Mtml.ngine wiki.formats.edit.pageUhtmlV /html/portlet/wiki/edit/html.jsp

wiki.formats.engineUplainLte<tV com.liferay.portlet.wiki.engines./e<t.ngine wiki.formats.edit.pageUplainLte<tV /html/portlet/wiki/edit/plainLte<t.jsp

Set the /ist of supported -i.i importers.


wiki.importers $ediaRiki

Configure settings for each of the -i.i importers.


wiki.importers.pageU$ediaRikiV /html/portlet/wiki/import/mediawiki.jsp wiki.importers.classU$ediaRikiV com.liferay.portlet.wiki.importers.mediawiki.$ediaRikiImporter

Configure emai/ notification settings.


wiki.email.from.name Eoe Sloggs wiki.email.from.address testIliferay.com

!!C

Advanced Liferay Configuration

Advanced Liferay Configuration


wiki.email.page.added.enabled true wiki.email.page.added.subject.prefi< com/liferay/portlet/wiki/dependencies/e mailLpageLaddedLsubjectLprefi<.tmpl wiki.email.page.added.body com/liferay/portlet/wiki/dependencies/emailLpageL addedLbody.tmpl wiki.email.page.added.signature com/liferay/portlet/wiki/dependencies/emailL pageLaddedLsignature.tmpl wiki.email.page.updated.enabled true wiki.email.page.updated.subject.prefi< com/liferay/portlet/wiki/dependencies/emailLpageLupdatedLsubjectLprefi<.tmpl wiki.email.page.updated.body com/liferay/portlet/wiki/dependencies/emailLpag eLupdatedLbody.tmpl wiki.email.page.updated.signature com/liferay/portlet/wiki/dependencies/emai lLpageLupdatedLsignature.tmpl wiki.rss.abstract.length 544

Plu)in /ana)ement
?ne of the primary -ays of e4tending the functiona/ity of Liferay @orta/ is by the use of %lugins. @/ugins are an umbre//a term for insta//ab/e %ortlet, theme, layout tem& %late, hoo5, and web module Java >> .-ar fi/es. ,hough Liferay comes bund/ed -ith a number of functiona/ port/ets, themes, /ayout temp/ates, hoo.s, and -eb modu/es, p/ugins provide a means of e4tending Liferay to be ab/e to do a/most anything.

Portlets
@ort/ets are sma// -eb app/ications that run in a portion of a -eb page. ,he heart of any porta/ imp/ementation is its port/ets, because a// of the functiona/ity of a porta/ resides in its port/ets. Liferay's core is a port/et container. ,he container's Iob is to manage the porta/'s pages and to aggregate the set of port/ets that are to appear on any particu/ar page. ,his means that the core doesn't contain app/ication code. $n) stead, a// of the features and functiona/ity of your porta/ app/ication must reside in its port/ets. @ort/et app/ications, /i.e serv/et app/ications, have become a Java standard -hich various porta/ server vendors have imp/emented. ,he JSR)A+( standard defines the port/et A." specification, and the JSR)!(+ standard defines the port/et !." specifica) tion. A Java standard port/et shou/d be dep/oyab/e on any port/et container -hich supports the standard. @ort/ets are p/aced on the page in a certain order by the end user and are served up dynamica//y by the porta/ server. ,his means that certain KgivensL that app/y to serv/et)based proIects, such as contro/ over 0RLs or access to the Htt%)ervlet9e7uest obIect, donOt app/y in port/et proIects, because the porta/ server generates these obIects dynamica//y. @orta/ app/ications come genera//y in t-o f/avors2 A6 port/ets can be -ritten to provide sma// amounts of functiona/ity and then aggregated by the porta/ server into a /arger app/ication, or !6 -ho/e app/ications can be -ritten to reside in on/y one or a fe- port/et -indo-s. ,he choice is up to those designing the app/ication. ,he de) ve/oper on/y has to -orry about -hat happens inside of the port/et itse/fU the porta/ server hand/es bui/ding out the page as it is presented to the user.

@/ugin :anagement

!!*

Advanced Liferay Configuration Ti#$ Liferay #.#.: and below support the -ortlet !.9 standard? J(2"!8@. Liferay 5.9 and above support the -ortlet :.9 standard? J(2":@8. >ou cannot run -ortlet :.9 portlets in Liferay #.#.:& but because the -ortlet :.9 standard is backwards"compatible& portlets written to the !.9 standard will run in Liferay 5.x and above.

:ost deve/opers no-adays /i.e to use certain frame-or.s to deve/op their ap) p/ications, because those frame-or.s provide both functiona/ity and structure to a proIect. 9or e4amp/e, Struts enforces the :ode/)Bie-)Contro//er design pattern and provides /ots of functiona/ity3such as custom tags and form va/idation3that ma.e it easier for a deve/oper to imp/ement certain standard features. <ith Liferay, de) ve/opers are free to use a// of the /eading frame-or.s in the Java >> space, inc/uding Struts, Spring, and Java Server 9aces. ,his a//o-s deve/opers fami/iar -ith those frame-or.s to more easi/y imp/ement port/ets, and a/so faci/itates the Huic. porting of an app/ication using those frame-or.s over to a port/et imp/ementation. Additiona//y, Liferay a//o-s for the consuming of @;@ and Ruby app/ications as Kport/ets,L so you do not need to be a Java deve/oper in order to ta.e advantage of Liferay's bui/t)in features 5such as user management, communities, page bui/ding and content management6. 1ou can use the @/ugins S=E to dep/oy your @;@ or Ruby ap) p/ication as a port/et, and it -i// run seam/ess/y inside of Liferay. <e have p/enty of e4amp/es of thisU to see them, chec. out the @/ugins S=E from Liferay's pub/ic code repository. =oes your organization ma.e use of any >nterprise @/anning 5>R@6 soft-are that e4poses its data via -eb servicesJ 1ou cou/d -rite a port/et p/ugin for Liferay that can consume that data and disp/ay it as part of a dashboard page for your users. =o you subscribe to a stoc. serviceJ 1ou cou/d pu// stoc. Huotes from that service and disp/ay them on your page, instead of using Liferay's bui/t)in Stoc.s port/et. =o you have a need to combine the functiona/ity of t-o or more serv/et)based app/ications on one pageJ 1ou cou/d ma.e them into port/et p/ugins and have Liferay disp/ay them in -hatever /ayout you -ant. =o you have e4isting Struts, Spring :BC, or JS9 app/ica) tions that you -ant to integrate -ith your porta/J $t is a straightfor-ard tas. to mi) grate these app/ications into Liferay, and then they can ta.e advantage of the /ayout, security, and administration infrastructure that Liferay provides.

Themes
,hemes are hot dep/oyab/e p/ugins -hich can comp/ete/y transform the /oo. and fee/ of the porta/. :ost organizations have their o-n /oo. and fee/ standards -hich go across a// of the -eb sites and -eb app/ications in the infrastructure. Liferay ma.es it possib/e for a site designer to create a theme p/ugin -hich can then be insta//ed, a/) /o-ing for the comp/ete transformation of the porta/ to -hatever /oo. and fee/ is needed. ,here are /ots of avai/ab/e theme p/ugins on Liferay's -eb site, and more are being added every day. ,his ma.es it easier for those -ho -ish to deve/op themes for Liferay, as you can no- choose a theme -hich most c/ose/y resemb/es -hat you -ant to do and then customize it. ,his is much easier than starting a theme from scratch. ,here is more about theme deve/opment in the Liferay Develo%erSs .uide.

!!+

@/ugin :anagement

Advanced Liferay Configuration

Illustration BB! (ruito%ia theme from LiferaySs theme re%ository'

Illustration BF! "lue Pigment theme from LiferaySs theme re%ository'

La&out Tem#lates
Layout ,emp/ates are -ays of choosing ho- your port/ets -i// be arranged on a page. ,hey ma.e up the body of your page, the /arge area -here you drag and drop your port/ets to create your pages. Liferay @orta/ comes -ith severa/ bui/t)in /ayout temp/ates, but if you have a comp/e4 page /ayout 5especia//y for your home page6, you may -ish to create a custom /ayout temp/ate of your o-n. ,his is covered in the Liferay Develo%erSs .uide.

3oo' Plu)ins
;oo. p/ugins are ne- to Liferay *.!. As the name imp/ies, they a//o- Khoo.ingL into Liferay's core functiona/ity. ,his means that they enab/e deve/opers to override or rep/ace functiona/ity that is in the core of the system. 1ou can hoo. into the event) ing system, mode/ /isteners, and porta/ properties. 1ou can a/so override Liferay's core JS@s -ith your o-n. ;oo.s are very po-erfu/ and have been designed to rep/ace some of the reasons for using the e4tension environment -ith something that is easi) er to use and hot dep/oyab/e.

We" Plu)ins
<eb p/ugins are regu/ar Java >> -eb modu/es that are designed to -or. -ith Liferay. Liferay supports integration -ith various >nterprise Service %us 5>S%6 imp/e) mentations, as -e// as Sing/e Sign)?n imp/ementations, -or.f/o- engines and so on. ,hese are imp/emented as -eb modu/es that are used by Liferay port/ets to provide functiona/ity.

@/ugin :anagement

!!'

Advanced Liferay Configuration

.nstallin) Plu)ins %rom Re#ositories


Liferay @orta/ has a section of the Contro/ @ane/ -hich can hand/e p/ugin insta//a) tion2 &lugin$ In$tallation, -hich is in the Ser!er category. ,his not on/y a//o-s you to see -hat p/ugins are insta//ed in your porta/, but a/so it enab/es you to run the search inde4er on those port/ets that support it and insta// ne- port/ets. Go to the =oc. and se/ect Control Panel. $n the Server category, se/ect Plugins In& stallation. 1ou shou/d no- see the screen -hich a//o-s you to configure and insta// port/ets. ,he defau/t /oo. of the @/ugin $nsta//er sho-s -hich p/ugins are a/ready insta//ed on the system, -hether it is active, and -hat @orta/ ro/es have access to it.

Illustration BG! Plugins Installation in the Control Panel $f you -ou/d /i.e to see -hat p/ugins are avai/ab/e, you can do so by c/ic.ing the Install More =Plugin 4y%e> button, -here S@/ugin ,ypeT changes based on -hich tab you are vie-ing. @/ease note that the machine upon -hich Liferay is running must have access to the $nternet in order to be ab/e to read the ?fficia/ and Community reposit) ories. $f the machine does not have access to the $nternet, you -i// need to do-n/oad the p/ugins from the site and insta// them manua//y. <e -i// discuss ho- to do this /ater in this chapter. 9rom the initia/ page you can navigate to the different pages of p/ugins, as they are a// in a/phabetica/ order. 1ou can a/so change the number of items per page and navigate to a specific page if you .no- -here a particu/ar p/ugin appears in the /ist. ,his is a standard feature of Liferay, and you -i// see it in most of Liferay's port/ets. After the Install More =Plugin 4y%e> button is c/ic.ed, a ne- vie- appears. ,his vie- has mu/tip/e tabs, and by defau/t, disp/ays the Portlet Plugins tab. &ote that the /ist disp/ayed is a /ist of a// of the p/ugins that are avai/ab/e across a// of the repositor) ies to -hich the server is subscribed. Above this is a search mechanism -hich a//o-s you to search for p/ugins by their name, by -hether they are insta//ed, by tag, or by !!( @/ugin :anagement

Advanced Liferay Configuration -hich repository they are in.

Illustration BK! Installing Plugins ,o insta// a p/ugin, choose the p/ugin by c/ic.ing on its name. 9or e4amp/e, if you -ant to provide a handy -eather forecast to your -eb site, you might -ant to insta// the <eather port/et. ,his port/et provides a handy interface to -hich sho-s the cur) rent -eather for a particu/ar zip code -hich your users can customize. 9ind the <eather @ort/et in the /ist by searching for it or bro-sing to it. ?nce you have found it, c/ic. on its name. Another page -i// be disp/ayed -hich describes the port/et p/ugin in more detai/. %e/o- the description is an Install button. C/ic. this but) ton to insta// your p/ugin.

Illustration FJ! Adding the @eather Portlet to Liferay ,he p/ugin chosen -i// be automatica//y do-n/oaded and insta//ed on your in) stance of Liferay. $f you have the Liferay conso/e open, you can vie- the dep/oyment as it happens. <hen it is finished, you shou/d be ab/e to go bac. to the Add App/ica) @/ugin :anagement !!#

Advanced Liferay Configuration tion -indo- and add your ne- p/ugin to a page in your porta/. ,he same procedure is used for insta//ing ne- Liferay ,hemes, Layout ,emp/ates, hoo.s, and -eb modu/es. $nstead of the Portlet Plugins tab, you -ou/d use the appro) priate tab for the type of p/ugin you -ish to insta// to vie- the /ist of p/ugins of that type. 9or themes, convenient thumbnai/s 5p/us a /arger version -hen you c/ic. on the detai/s of a particu/ar theme6 are sho-n in the /ist. After c/ic.ing on the Install button for a theme, the theme becomes avai/ab/e on the Loo5 and (eel tab of any page.

.nstallin) Plu)ins /anuall&


$nsta//ing p/ugins manua//y is a/most as easy as insta//ing p/ugins via the @/ugin $nsta//er. ,here are severa/ scenarios in -hich you -ou/d need to insta// p/ugins manua//y rather than from Liferay's repositories2 1our server is fire-a//ed -ithout access to the $nternet. ,his ma.es it im) possib/e for your instance of Liferay to connect to the p/ugin repositories. 1ou are insta//ing port/ets -hich you have either purchased from a vendor, do-n/oaded separate/y, or deve/oped yourse/f. 9or security reasons, you do not -ant to a//o- porta/ administrators to in) sta// p/ugins from the $nternet before they are eva/uated.

1ou can sti// use the Contro/ @ane/ to insta// p/ugins that are not avai/ab/e from the on /ine repositories. ,his is by far the easiest -ay to insta// p/ugins. $f your server is fire-a//ed, you -i// not see any p/ugins disp/ayed in the Portlet Plugins tab or in the 4heme Plugins tab. $nstead, you -i// need to c/ic. the U%load (ile tab. ,his gives you a simp/e interface for up/oading a .-ar fi/e containing a p/ugin to your Liferay @orta/. C/ic. the "rowse button and navigate your fi/e system to find the port/et or theme .-ar you have do-n/oaded. ,he other fie/d on the page is optiona/2 you can specify your o-n conte4t for dep/oyment. $f you /eave this fie/d b/an., the defau/t conte4t defined in the p/ugin 5or the .-ar fi/e name itse/f6 -i// be used. ,hat's a// the information the @/ugin $nsta//er needs in order to dep/oy your port) /et, theme, /ayout temp/ate, hoo., or -eb modu/e. C/ic. the Install button, and your p/ugin -i// be up/oaded to the server and dep/oyed. $f it is a port/et, you shou/d see it in the Add Content -indo-. $f it is a theme, it -i// be avai/ab/e on the Loo5 and (eel tab in the page definition. $f you do not -ish to use the 0pdate :anager or @/ugin $nsta//er to dep/oy p/u) gins, you can a/so dep/oy them at the operating system /eve/. ,he first time Liferay starts, it creates a hot de%loy fo/der -hich is by defau/t created inside the Liferay ;ome fo/der. ,his fo/der genera//y resides one directory up from -here your app/ication server is insta//ed, though it sometimes is e/se-here depending on -hich app/ication server you are running. ,o find out -here the Liferay ;ome fo/der is for your app/ica) tion server, p/ease see the section on your server in Chapter A. ,he first time Liferay is /aunched, it -i// create a fo/der structure in Liferay ;ome to house various configura) tion and administrative data. ?ne of the fo/ders it creates is ca//ed de%loy. $f you copy a !8" @/ugin :anagement

Advanced Liferay Configuration port/et or theme p/ugin into this fo/der, Liferay -i// dep/oy it and ma.e it avai/ab/e for use Iust as though you'd insta//ed it via the @/ugin $nsta//er in the Contro/ @ane/. $n fact, this is -hat the @/ugin $nsta//er is doing behind the scenes. 1ou can change the defau/ts for this directory structure so that it is stored any) -here you /i.e by modifying the appropriate properties in your %ortal&ext'%ro%erties fi/e. @/ease see the above section on the %ortal&ext''%ro%erties fi/e for more information. ,o have Liferay hot dep/oy a port/et or theme p/ugin, copy the p/ugin into your hot dep/oy fo/der, -hich by defau/t is in =Liferay Home>+de%loy. $f you are -atching the Liferay conso/e, you shou/d see messages /i.e the fo//o-ing2
3?*3?*3P,=64 I'0N 6.5.5.3.war U8uto)eploy)ir*312V "rocessing web-form-portlet-

3?*3?*3P,=65 I'0N U"ortlet8uto)eploy!istener*TTV &opying portlets for /opt/ liferay/liferay-portal-6.5.5/deploy/web-form-portlet-6.5.5.3.war .<panding* /opt/liferay/liferay-portal-6.5.5/deploy/web-form-portlet6.5.5.3.war into /opt/liferay/liferay-portal-6.5.5/tomcat6.6.5T/temp/544P4=523?3?3P?3T &opying 3 file to /opt/liferay/liferay-portal-6.5.5/tomcat6.6.5T/temp/544P4=523?3?3P?3T/R.S-I'0 &opying 3 file to /opt/liferay/liferay-portal-6.5.5/tomcat6.6.5T/temp/544P4=523?3?3P?3T/R.S-I'0/classes &opying 3 file to /opt/liferay/liferay-portal-6.5.5/tomcat6.6.5T/temp/544P4=523?3?3P?3T/R.S-I'0/classes &opying 3 file to /opt/liferay/liferay-portal-6.5.5/tomcat6.6.5T/temp/544P4=523?3?3P?3T/$./8-I'0 &opying 21 files to /opt/liferay/liferay-portal-6.5.5/tomcat6.6.5T/webapps/web-form-portlet &opying 3 file to /opt/liferay/liferay-portal-6.5.5/tomcat-6.6.5T/webapps/ web-form-portlet )eleting directory /opt/liferay/liferay-portal-6.5.5/tomcat6.6.5T/temp/544P4=523?3?3P?3T 3?*3?*54,P56 I'0N U"ortlet8uto)eploy!istener*1TV "ortlets for /opt/liferay/ liferay-portal-6.5.5/deploy/web-form-portlet-6.5.5.3.war copied successfully. )eployment will start in a few seconds. 3?*3?*5T,PP2 I'0N web-form-portlet U"ortletMot)eploy!istener*222V ,nregistering portlets for

3?*3?*51,444 I'0N U"ortletMot)eploy!istener*2?5V 3 portlet for web-formportlet was unregistered 8pr 52, 544P =*3?*5T "$ org.apache.catalina.startup.Most&onfig checkFesources I'0N* ,ndeploying conte<t U/web-form-portletV 3?*3?*51,=41 I'0N web-form-portlet U"ortletMot)eploy!istener*53PV Fegistering portlets for

!oading file*/opt/liferay/liferay-portal-6.5.5/tomcat-6.6.5T/temp/?-webform-portlet/R.S-I'0/classes/portlet.properties 3?*3?*51,6T4 I'0N U"ortletMot)eploy!istener*5P1V 3 portlet for web-formportlet is available for use

As /ong as you see the available for use message, your p/ugin -as insta//ed cor) rect/y, and -i// be avai/ab/e for use in the porta/.

Plu)in Trou"leshootin)
Sometimes for various reasons p/ugins fai/ to insta//. ,here are different reasons @/ugin :anagement !8A

Advanced Liferay Configuration for this based on severa/ factors, inc/uding Liferay configuration ,he container upon -hich Liferay is running Changing the configuration options in mu/tip/e p/aces ;o- Liferay is being /aunched

1ou -i// often be ab/e to te// if you have a p/ugin dep/oyment prob/em by /oo.ing at the Liferay server conso/e. $f you see the p/ugin get recognized by the hot dep/oy /istener, you -i// see a %lugin co%ied successfully message. $f this message is not fo/) /o-ed up by an available for use message, you have an issue -ith your p/ugin dep/oy) ment configuration, and it is /i.e/y one of the factors above. <e -i// /oo. at each of these factors.

L.* RA5 !1N*.G-RAT.1N .SS- S


Ti#$ This applies to Liferay versions prior to version #.;.5. Liferay versions above #.;.5 are able to auto detect the type of server it is running on& which makes things a lot easier. %f you are running a newer version of Liferay& you can skip this section.

Liferay by defau/t comes as a bund/e or as a .-ar fi/e. ,hough every effort has been made to ma.e the .-ar fi/e as generic as possib/e, sometimes the defau/t settings are inappropriate for the container upon -hich Liferay is running. :ost of these prob/ems have been reso/ved in Liferay C.8.* -ith the addition of code that a//o-s Liferay to determine -hich app/ication server it is running on and adIust the -ay it dep/oys p/ugins as a resu/t. $n versions of Liferay prior to C.8.*, there is a property ca//ed auto'de%loy'dest'dir that defines the fo/der -here p/ugins are dep/oyed after the hot dep/oy uti/ities have finished preparing them. ,his fo/der maps to a fo/der that the container defines as an auto)dep/oy or a hot dep/oy fo/der. %y defau/t, this property is set to ''+weba%%s. ,his defau/t va/ue -or.s for ,omcat containers 5if ,omcat has been /aunched from its bin fo/der6, but -i// not -or. for other containers that define their hot dep/oy fo/ders in a different p/ace. 9or e4amp/e, G/assfish defines the hot dep/oy fo/der as a fo/der ca//ed autode%loy inside of the domain fo/der in -hich your server is running. %y defau/t, this is in T.lassfish HomeR+domains+domain +autode%loy. J%oss defines the hot dep/oy fo/der as a root fo/der inside of the particu/ar server configuration you are using. %y defau/t, this is in T3"oss HomeR+server+default+de%loy. <ebLogic defines this fo/der inside of the do) main directory. %y defau/t, this is in T"ea HomeR+user/%ro*ects+domains+Tdomain nameR+ autode%loy. 1ou -i// first need to determine -here the hot dep/oy fo/der is for the container you are running. Consu/t your product documentation for this. ?nce you have this va/ue, there are t-o p/aces in -hich you can set it2 the %ortal&ext'%ro%erties fi/e and in

!8!

@/ugin :anagement

Advanced Liferay Configuration the @/ugin $nsta//er port/et. ,o change this setting in the %ortal&ext'%ro%erties fi/e, bro-se to -here Liferay -as dep/oyed in your app/ication server. $nside of this fo/der shou/d be a @1"&I6(+classes fo/der. ;ere you -i// find the %ortal&ext'%ro%erties fi/e. ?pen this fi/e in a te4t editor and /oo. for the property auto'de%loy'dest'dir. $f it does not appear in the fi/e, you can add it. ,he safest -ay to set this property3as -e -i// see /ater3is to define the property using an abso/ute path from the root of your fi/e system to your app/ication server's hot dep/oy fo/der. 9or e4amp/e, if you are using G/assfish, and you have the server in) sta//ed in +*ava+glassfish, your auto'de%loy'dest'dir property -ou/d /oo. /i.e the fo//o-) ing2
auto.deploy.dest.dir /java/glassfish/domains/domain3/autodeploy

Remember, if you are on a <indo-s system, use for-ard s/ashes instead of bac. s/ashes, /i.e so2
auto.deploy.dest.dir &*/java/glassfish/domains/domain3/autodeploy

Save the fi/e and then restart your container. &o- p/ugins shou/d insta// cor) rect/y. $f you -ou/d rather change this setting via the @/ugin $nsta//er port/et 5because you do not -ish to restart your container6, you can do that by c/ic.ing on the Config& uration tab. ?n this page are a number of settings you can change, inc/uding the de) fau/t fo/ders for hot dep/oy, -here Liferay shou/d /oo. for p/ugin repositories, and so on. Illustration F ! Changing the hot de%loy destination directory ,he setting to change is the fie/d mar.ed Destination Directory. Change this to the fu// path to your container's auto dep/oy fo/der from the root of your fi/e system. <hen you are finished, c/ic. the )ave button at the bottom of the form. ,he setting -i// no- ta.e effect -ithout your having to restart your container. &ote that the setting in the port/et overrides the setting in the properties fi/e. $f you are having hot dep/oy troub/e in Liferay versions C.8.* and greater, it is possib/e that the administrator of your app/ication server has changed the defau/t fo/der for auto dep/oy in your app/ication server. $n this case, you -ou/d -ant to set auto'de%loy'dest'dir to the customized fo/der /ocation as you -ou/d -ith o/der versions of Liferay. $n Liferay C.8.* and greater, this setting sti// e4ists, but is b/an.. Add the property to your %ortal&ext'%ro%erties fi/e and set its va/ue to the fu//y Hua/ified path to the auto dep/oy fo/der configured in your app/ication server.

T3 !1NTA.N R -P1N W3.!3 L.* RA5 .S R-NN.NG


,here are some containers, such as ?rac/e App/ication Server and <eb) Sphere, -hich do not have a hot dep/oy feature. 0nfortunate/y, these containers do not -or. -ith Liferay's hot dep/oy system. %ut this does not mean that you cannot in) sta// p/ugins on these containers. 1ou can dep/oy p/ugins manua//y using the app/ica) tion server's dep/oyment too/s. Liferay is ab/e to pic. up the port/et p/ugins once they get dep/oyed to the container manua//y, especia//y if you add it to the same >nterprise @/ugin :anagement !88

Advanced Liferay Configuration App/ication proIect that -as created for Liferay. <hen Liferay hot dep/oys port/et and theme .-ar fi/es, it sometimes ma.es modi) fications to those fi/es right before dep/oyment. $n order to successfu//y dep/oy p/u) gins using an app/ication server vendor's too/s, you -i// -ant to run your p/ugins through this process before you attempt to dep/oy them. $n the &lugin In$taller section of the Contro/ @ane/, c/ic. the Configuration tab. ,he second)most fie/d on the form is /abe/ed *e$tination *irector . @/ace the path to -hich you -ou/d /i.e p/ugin .-ar fi/es copied after they are processed by Liferay's p/ugin insta//er process. 1ou -i// use this as a staging directory for your p/ugins be) fore you insta// them manua//y -ith your server's dep/oyment too/s. <hen you are finished, c/ic. )ave. &o- you can dep/oy p/ugins using the @/ugin $nsta//er port/et or by dropping .-ar fi/es into your auto dep/oy directory. Liferay -i// pic. up the fi/es, modify them, and then copy the resu/t into the destination directory you have con) figured. 1ou may then dep/oy them from here to your app/ication server.
4A/PL

$ W (SP3 R APPL.!AT.1N S R> R

A. $f you don't have one a/ready, create a %ortal&ext'%ro%erties fi/e in the Liferay ;ome fo/der of your Liferay insta//ation. Add the fo//o-ing directive to it2
auto.deploy.dest.dir @Gliferay.homeH/websphere-deploy

!. Create a fo/der ca//ed webs%here&de%loy inside your WL$9>RA1M;?:> fo/der. ,his is the fo/der -here the Lucene inde4, Jac.rabbit config, and dep/oy fo/ders are. 8. :a.e sure the web'xml fi/e inside the p/ugin you -ant to insta// has the fo/) /o-ing conte4t parameter in it2
9conte<t-param: 9param-name:com.ibm.websphere.portletcontainer."ortlet)eployment.nabled9/param-name: 9param-value:false9/param-value: 9/conte<t-param:

Liferay versions *.!.! and higher -i// automatica//y inIect this into the web'xml fi/e on <ebSphere containers. C. ,he <ebSphere dep/oy occurs in t-o steps. 1ou -i// first use Liferay's too/s to Kpre)dep/oyL the fi/e, and then use <ebSphere's too/s to do the actua/ de) p/oyment. ,his is because Liferay ma.es dep/oyment)time modifications to the p/ugins right before they are actua//y dep/oyed to the app/ication server. 9or other app/ication servers, this can usua//y be done in one step, because Liferay can ma.e the modifications and then copy the resu/ting .-ar fi/e into an autodep/oy fo/der to have it actua//y dep/oyed. %ecause <ebSphere does not have an autodep/oy feature, -e need to separate these t-o steps. *. =ep/oy your .-ar fi/e using Liferay's @/ugin $nsta//er or by copying it into WL$9>RA1M;?:>7dep/oy. Liferay -i// ma.e its modifications and because -e changed the auto'de%loy'dest'dir in the first step, it -i// copy the

!8C

@/ugin :anagement

Advanced Liferay Configuration resu/ting .-ar fi/e into -LI(19AA/H0M1+webs%here&de%loy. 1ou -i// see a co%ied successfully message in the /og. +. 0se <ebSphere's too/s to dep/oy the .-ar fi/e. :a.e the conte4t root for the .-ar fi/e eHua/ to the fi/e name 5i.e., +my&first&%ortlet6. ?nce the .-ar fi/e is dep/oyed, save it to the master configuration. '. Go bac. to the A%%lications &R 1nter%rise A%%lications screen in the <ebSphere Admin Conso/e. 1ou -i// see that your port/et is dep/oyed, but not yet star) ted. Start it. (. Liferay -i// immediate/y recognize that the port/et has been dep/oyed and register it. ,he port/et -i// be automatica//y started and registered upon subseHuent restarts of <ebSphere. >4perienced <ebSphere system administrators can further automate this by -riting a script -hich -atches the webs%here&de%loy directory and uses wsadmin com) mands to then dep/oy p/ugins automatica//y.

!3ANG.NG T3 !1N*.G-RAT.1N 1PT.1NS .N /-LT.PL PLA! S


Sometimes, especia//y during deve/opment -hen severa/ peop/e have adminis) trative access to the server at the same time, the auto dep/oy fo/der /ocation can get customized in both the %ortal&ext'%ro%erties fi/e and in the Contro/ @ane/. $f this hap) pens, the va/ue in the Contro/ @ane/ ta.es precedence over the va/ue in the properties fi/e. $f you go into the Contro/ @ane/ and change the va/ue to the correct setting, p/u) gin dep/oyment -i// start -or.ing again.

31W L.* RA5 .S ( .NG LA-N!3 0


Ti#$ This applies to Liferay versions prior to version #.;.5. Liferay versions above #.;.5 are able to auto detect the type of server it is running on& and this property is no longer detected via the relative path from the server launch location.

$n versions of Liferay prior to C.8.*, the defau/t va/ue of the hot dep/oy destina) tion directory is a re/ative path 5e.g., ''+weba%%s or ''+server+default+de%loy6. ,his path is re/ative to the fo/der from -hich the app/ication server is norma//y /aunched. 9or e4) amp/e, ,omcat has the pictured directory structure. ,he start up and shut do-n scripts are in the bin fo/der. So to start ,omcat, you -ou/d norma//y go into the bin fo/der to run the startup script -hich starts Liferay running in ,omcat. ,omcat's hot dep/oy fo/der is the weba%%s fo/der. ,his fo/der is on the same /eve/ the bin fo/der is on. $f you are at the command prompt inside of the bin fo/der 5-here you started ,omcat6, to get to a fi/e in the hot dep/oy fo/der you -ou/d reference it by using t-o dots to go bac. up one fo/der, and then the path separator 576, and then the name of the fo/der 5weba%%s6. So in the defau/t configuration, the hot dep/oy destina) tion directory is re/ative to the fo/der from -hich the app/ication server -as /aunched. @/ugin :anagement !8*

Advanced Liferay Configuration $f you are /aunching your app/ication server from another script3perhaps as part of a cron Iob3and your script does not enter the fo/der the app/ication server's startup scripts are in 5in this case, T4omcat HomeR+bin6, the re/ative path that is set by defau/t -i// not -or.. $nstead, the path -i// be re/ative to the path from -hich you /aunched the startup script. ,his -i// cause Liferay to create3in the ,omcat e4amp/e 3a weba%%s fo/der one fo/der up from -here the startup script -as /aunched. Since this is not the correct hot dep/oy fo/der for your app/ication server, you -i// see the co%ied successfully message in the server conso/e, but you -i// never see the registered successfully message. ,o fi4 this, you can do one of t-o things2 A6 Change the re/ative path to an abso/ute path as recommended aboveU or !6 Change the -ay you /aunch Liferay by ma.ing sure you go into the fo/der -here the app/ication server's startup scripts are before you /aunch them. >ither one of these methods shou/d fi4 your hot dep/oy prob/em and -i// resu/t in the successfu/ dep/oyment of port/et and theme p/ugins.

!reatin) 5our 1wn Plu)in Re#ositor&


As your enterprise bui/ds its o-n /ibrary of port/ets for interna/ use, you can cre) ate your o-n p/ugin repository to ma.e it easy to insta// and upgrade port/ets. ,his -i// a//o- different departments -ho may be running different instances of Liferay to share port/ets and insta// them as needed. $f you are a soft-are deve/opment house, you may -ish to create a p/ugin repository for your o-n products. Liferay ma.es it easy for you to create your o-n p/ugin repository and ma.e it avai/ab/e to others. 1ou can create your p/ugin repository in t-o -ays2 A. !. 0se the Soft-are Cata/og in the Contro/ @ane/ to create the repository by us) ing its graphica/ interface and an ;,,@ server. Create an D:L fi/e using the Liferay @/ugin Repository =,= 5http277---./iferay.com7dtd7/iferay)p/ugin)repositoryM*M!M".dtd6 and an ;,,@ server.

%oth methods have their benefits. ,he first method a//o-s users to up/oad their p/ugins to an ;,,@ server to -hich they have access. ,hey can then register their p/u) gins -ith the repository by adding a /in. to it via the Contro/ @ane/'s graphica/ user interface. Liferay -i// then generate the D:L necessary to connect the repository to a Contro/ @ane/ running on another instance of Liferay. ,his D:L fi/e can then be p/aced on an ;,,@ server, and the 0RL to it can be added to the @/ugin $nsta//er, ma.) ing the port/ets in this repository avai/ab/e to the server running Liferay. ,he second method does not reHuire an instance of Liferay to be running. 1ou can up/oad p/ugins to an ;,,@ server of your choice, and then create an D:L fi/e ca//ed liferay&%lugin&re%ository'xml manua//y. $f you ma.e this fi/e avai/ab/e on an ;,,@ server 5it can be the same one upon -hich the p/ugins are stored, or a different one a/together6, you can connect the repository to a @/ugin $nsta//er in the Contro/ @ane/ running on an instance of Liferay. <e -i// first /oo. at creating a p/ugin repository using the Soft-are Cata/og in the Contro/ @ane/.

!8+

@/ugin :anagement

Advanced Liferay Configuration

T3 S1*TWAR !ATAL1G
1ou -i// -ant to use the Soft1are Catalog if you -i// have mu/tip/e users sub) mitting port/ets into the repository, and if you don't -ant to -orry about creating the liferay&%lugin&re%ository'xml fi/e yourse/f. >ach community in your porta/ can have an instance of the Soft-are Cata/og. ,he Contro/ @ane/ -i// .eep trac. of -hich community or organization you are in and present you -ith the soft-are cata/og for that community or organization. ,his means that different communities7organizations can have different soft-are reposit) ories, so you can host severa/ soft-are repositories on the same instance of Liferay if you -ish3they Iust have to be in different communities or organizations.

Illustration F#! )oftware Catalog with no %roducts Choose the community that -i// host the p/ugin repository and go to the Contro/ @ane/. 1ou -i// see at the top of the screen a message that says KContent for S?rganiz) ation7CommunityT,L -here S?rganization7CommunityT is the organization or com) munity you -ere on -hen you se/ected the Contro/ @ane/ from the =oc.. $f you -ant to administer the soft-are cata/og for a different community or organization, you can se/ect it from the se/ection bo4. ,he Soft-are Cata/og has severa/ tabs. ,he first tab is /abe/ed Products. ,he de) fau/t vie- of the port/et, -hen popu/ated -ith soft-are, disp/ays -hat p/ugins are avai/ab/e for insta// or do-n/oad. ,his can be seen in the version on Liferay's home page. <e -i// use an e4amp/e community in order to better i//ustrate ho- to use the Soft-are Cata/og port/et. Assume you, as the porta/ administrator, have created a community ca//ed 0ld Com%uters. ,his community -i// be a -eb site for users to co//ab) orate on setting up and using o/d computers -ith obso/ete hard-are and operating systems. 0sers -ho participate in the site -i// eventua//y get upgraded to a more priv) i/eged status and get their o-n b/og page. ,o imp/ement this, you have created a :y Summary port/et -hich disp/ays the user's name, picture, and description from his or her user profi/e. %ecause this port/et is generic enough that it cou/d be usefu/ to any) one using Liferay, you have decided to ma.e it avai/ab/e in your o-n soft-are cata/og.

@/ugin :anagement

!8'

Advanced Liferay Configuration

Illustration F2! Po%ulated )oftware Catalog from liferay'com ,he first step in adding a p/ugin to your soft-are repository is to add a license for your product. A /icense communicates to users the terms upon -hich you are a//o-) ing them to do-n/oad and use your soft-are. C/ic. the Licenses tab and then c/ic. the Add License button that appears. 1ou -i// then see a form -hich a//o-s you to enter the tit/e of your /icense, a 0RL pointing to the actua/ /icense document, and chec. bo4es denoting -hether the /icense is open source, active, or recommended. <hen you have finished fi//ing out the form, c/ic. the )ave button. 1our /icense -i// be saved. ?nce you have at /east one /icense in the system, you can begin adding soft-are products to your soft-are cata/og. C/ic. the Products tab, and then c/ic. the Add Product button. 1our ne4t step -i// be to create the product record in the soft-are cata/og. ,his -i// register the product in the soft-are cata/og and a//o- you to start adding ver) sions of your soft-are for users to do-n/oad and 7 or insta// direct/y from their in) stances of Liferay. 1ou -i// first need to put the .-ar fi/e containing your soft-are on a -eb server that is accessib/e -ithout authentication to the users -ho -i// be in) sta//ing your soft-are. $n the e4amp/e above, the 0ld Com%uters site is on the $nternet, so you -ou/d p/ace the fi/e on a -eb server that is accessib/e to anyone on the $nter) net. $f you are creating a soft-are cata/og for an interna/ $ntranet, you -ou/d p/ace the fi/e on a -eb server that is avai/ab/e to anyone inside of your organization's fire) -a//. ,o create the product record in the Soft-are Cata/og port/et, c/ic. the Products tab, and then c/ic. the Add Product button. 9i// out the form -ith information about !8( @/ugin :anagement

Advanced Liferay Configuration your product.

Illustration F;! Adding a %roduct to the )oftware Catalog N%artial viewO 3a+e) ,he name of your soft-are product. 8 pe) Se/ect -hether this is a port/et, theme, /ayout temp/ate, hoo., or -eb p/u) gin. Licen$e$) Se/ect the /icense5s6 under -hich you are re/easing this soft-are. Author) >nter the name of the author of the soft-are. &age 6:L) $f the soft-are has a home page, enter its ur/ here. 8ag$) >nter any tags you -ou/d /i.e added to this soft-are. Short *e$cription) >nter a short description. ,his -i// be disp/ayed in the sum) mary tab/e of your soft-are cata/og.

@/ugin :anagement

!8#

Advanced Liferay Configuration Long *e$cription) >nter a /onger description. ,his -i// be disp/ayed on the de) tai/s page for this soft-are product. &er+i$$ion$) C/ic. the Configure /in. to set permissions for this soft-are product. >roup I*) >nter a group $=. A group $= is a name space -hich usua//y identifies the company or organization that made the soft-are. 9or our e4amp/e, -e -i// use old&com%uters. Artifact I*) >nter an Artifact $=. ,he artifact $= is a uniHue name -ithin the name space for your product. 9or our e4amp/e, -e -i// use my&summary&%ortlet. Screen$hot) C/ic. the Add )creenshot button to add a screen shot of your product for users to vie-. <hen you have finished fi//ing out the form, c/ic. the )ave button. 1ou -i// be brought bac. to the product summary page, and you -i// see that your product has been added to the repository.

Illustration F?! Product has been added to the )oftware Catalog &otice that in the version co/umn, 6+A is being disp/ayed. ,his is because there are not yet any re/eased versions of your product. ,o ma.e your product do-n/oad) ab/e, you need to create a version of your product and point it to the fi/e you up/oaded to your ;,,@ server ear/ier. %efore you do that, ho-ever, you need to add a (ramewor5 <ersion to your soft) -are cata/og. A 9rame-or. version denotes -hat version of Liferay your p/ugin is de) signed for and -or.s on. 1ou cannot add a version of your product -ithout /in.ing it to a version of the frame-or. for -hich it is designed. <hy is this so importantJ %ecause as Liferay gains more and more features, you may -ish to ta.e advantage of those features in future versions of your product, -hi/e sti// .eeping o/der versions of your product avai/ab/e for those -ho are using o/der versions of Liferay. ,his is perfect/y i//ustrated in the e4amp/e :y Summary port/et -e are using. Liferay had a :y Summary port/et of its o-n, -hich does e4act/y -hat -e have described here. 9or version *.A, ho-ever, this port/et -as rep/aced by the @orld of Liferay 5<?L6 port/et, -hich ma.es use of the many socia/ net-or.ing fea)

!C"

@/ugin :anagement

Advanced Liferay Configuration tures -hich have been added to Liferay. So rather than Iust disp/aying a summary of your information, the <?L port/et adds features such as status updates, a K-a//L for each user in his or her profi/e that other users can K-riteL on, the abi/ity to become KfriendsL -ith other users3thereby granting them access to their profi/es3and more. 9or version *.!, the <?L port/et itse/f has been bro.en do-n so that the socia/ com) ponents can be insta//ed separate/y from the soft-are management components. &one of this -ou/d -or. in o/der versions of Liferay, because the core engine that enab/es deve/opers to create features /i.e this is not there. So in this case, you -ou/d -ant to .eep the o/der :y Summary port/et avai/ab/e for users -ho have not yet upgraded, ma.e the <?L port/ets avai/ab/e to those -ho are using *.A.4, and ma.e the ne-er socia/ port/ets avai/ab/e to those using /atest version of Liferay. ,his is -hat (ramewor5 <ersions does for you. $f you connect to Liferay's soft-are repositories -ith a Liferay C.C.! version, you -i// see the :y Summary port/et. $f you connect to Liferay's soft-are repositories -ith a Liferay *.A version, you -i// see the <?L port/et. $f you connect to Liferay's soft-are repositories -ith a Liferay *.! version, you -i// see the socia/ port/ets. ton. So c/ic. the (ramewor5 <ersions tab and then c/ic. the Add (ramewor5 <ersion but)

Give the frame-or. a name, a 0RL, and /eave the Active chec. bo4 chec.ed. 9or our e4amp/e, -e have entered ?'#'# for the name, because our port/et shou/d -or. on that version and higher, and http277---./iferay.com for the 0RL. C/ic. )ave' &o- go bac. to the Products tab and c/ic. on your product. 1ou -i// notice that a message is disp/ayed stating that the product does not have any re/eased versions. C/ic. the Add Product <ersion button.

Illustration FB! Adding a %roduct version to the )oftware Catalog @/ugin :anagement !CA

Advanced Liferay Configuration ;er$ion 3a+e) >nter the version of your product. Change Log) >nter some comments regarding -hat changed bet-een this ver) sion and any previous versions. Supported ?ra+e1ork ;er$ion$) Se/ect the frame-or. version for -hich your soft-are product is intended. >nter a Q at the end of the version number if you -ant to specify a version p/us any future versions. *o1nload &age 6:L) $f your product has a descriptive -eb page, enter its 0RL here. *irect *o1nload 6:L B:eco++endedC) >nter a direct do-n/oad /in. to your soft-are product here. ,he @/ugin $nsta//er port/et -i// fo//o- this /in. in order to do-n/oad your soft-are product. Include Artifact in :epo$itor ) ,o enab/e others to use the @/ugin $nsta//er port/et to connect to your repository and do-n/oad your p/ugin, se/ect yes here. <hen you are finished fi//ing out the form, c/ic. the )ave button. 1our product version -i// be saved, and your product -i// no- be avai/ab/e in the soft-are reposit) ory.

N RAT.NG

T3 S1*TWAR !ATAL1G

,he Soft-are Cata/og -or.s by generating an D:L document -hich the @/ugin $nsta//er reads. 0sing the data from this D:L document, the @/ugin $nsta//er .no-s -here it can do-n/oad the p/ugins from, -hat version of Liferay the p/ugins are de) signed for, and a// other data about the p/ugins that have been entered into the Soft) -are Cata/og port/et. $n order to get your Soft-are Cata/og to generate this D:L data, you -i// need to access a particu/ar 0RL. $f you have created a friend/y 0RL for your community 5for e4amp/e, the defau/t community, -hich is ca//ed guest$ has a friend/y 0RL of +guest a/ready configured for it6, you can use the friend/y 0RL. $f not, you -i// first need to .no- the Group $= of the community in -hich your Soft-are Cata/og port/et resides. 1ou can do this by accessing the :anage @ages interface and /oo.ing at the 0RLs for any of the pages. ,he 0RL -i// /oo. something /i.e this2 htt%!++localhost!GJGJ+web+ J ;G+ . ?bvious/y, it is much easier if you are using 9riend/y 0RLs, and -e high/y recom) mend that you do. &e4t, go to your bro-ser and go to the fo//o-ing 0RL2
http*//9server name:*9port number:/softwareLcatalog+90riendly ,F! name or Oroup I):

9or e4amp/e, if you are on the same machine as your Liferay instance, and that instance is running on port ("(", and your group $= from the database is A"AC(, you -ou/d use the fo//o-ing 0RL2
http*//localhost*1414/softwareLcatalog+343=1

$f you have a/so created a friend/y 0RL ca//ed old&com%uters for this organization or community, you -ou/d use the fo//o-ing 0RL2 !C! @/ugin :anagement

Advanced Liferay Configuration


http*//localhost*1414/softwareLcatalog+old-computers

$f you have configured everything proper/y, an D:L document shou/d be re) turned2
9+<ml version D3.4D encoding D,/0-1D+: 9plugin-repository: 9settings/: 9plugin-package: 9name:$y Summary9/name: 9module-id:old-computers/my-summary-portlet/3.4/war9/module-id: 9modified-date:/hu, 52 8pr 544P 54*=4*3? \44449/modified-date: 9types: 9type:portlet9/type: 9/types: 9tags: 9tag:social9/tag: 9tag:profile9/tag: 9/tags: 9short-description:$y Summary9/short-description: 9long-description:$y Summary9/long-description: 9change-log:Initial Kersion9/change-log: 9download-url:http*//www.liferay.com/portlets/my-summary-portlet6.5.5.war 9/download-url: 9author:Fich Se>ov9/author: 9screenshots/: 9licenses: 9license osi-approved DtrueD:$I/ !icense9/license: 9/licenses: 9liferay-versions/: 9/plugin-package: 9/plugin-repository:

Save this document to a fi/e ca//ed liferay&%lugin&%ac5age'xml and put this fi/e on your ;,,@ server -here you up/oaded your port/et .-ar fi/e. 1ou can then give out the 0RL to the directory -hich ho/ds this fi/e on your -eb site, and anyone -ith an instance of Liferay -i// be ab/e to point their @/ugin $nsta//er port/ets to it.

(N

*.TS 1* T3

S1*TWAR !ATAL1G

As you can see, the Soft-are Cata/og ma.es it easy for you to create a repository of your soft-are. 0sers of Liferay can configure their @/ugin $nsta//ers to attach to your repository, and the proper versions of your soft-are -i// be automatica//y made avai/ab/e to them by a sing/e c/ic.. ,his is by far the easiest -ay for you to .eep trac. of your soft-are, and for your users to obtain your soft-are. Another benefit of the Soft-are Cata/og is that by using it, you ma.e avai/ab/e to your users a standard interface for manua//y do-n/oading your soft-are. 9or those -ho prefer to manua//y do-n/oad p/ugins, your Soft-are Cata/og gives them an inter) face to go in, find your soft-are either by bro-sing or by searching, previe- screen

@/ugin :anagement

!C8

Advanced Liferay Configuration shots, and do-n/oad your soft-are3and you don't have to bui/d any of those pages yourse/f. Simp/y configure your soft-are in the port/et, and a// of that is done for you. ;o- can you do thisJ ,he Soft-are Cata/og is a/so avai/ab/e as a port/et. 1ou can add it to any page on your -eb site through the Add A%%lication menu. 1ou -i// find the port/et in the 4ools category.

/AN-ALL5 !R AT.NG A S1*TWAR !ATAL1G


$f you do not -ish to use the Contro/ @ane/ to create your soft-are cata/og, you can create it manua//y by manua//y typing out the D:L fi/e that the Soft-are Cata/og section of the Contro/ @ane/ -ou/d norma//y generate. &ote that if you do this, you -i// not be ab/e to use the Soft-are Cata/og port/et as a graphica/ user interface to your soft-are that end users can use to do-n/oad your soft-are manua//y2 you -i// have to bui/d this yourse/f. Eeep in mind that many instances of Liferay @orta/ sit be) hind a fire-a// -ithout access to the $nternet. %ecause of this, if you are ma.ing your soft-are avai/ab/e to $nternet users, some of them -i// have to do-n/oad it manua//y. $n this case, the Soft-are Cata/og port/et is the easiest -ay to provide a user interface for do-n/oading your soft-are. $f you sti// -ish to use a te4t editor to create your soft-are cata/og, you can. ,o manua//y create a soft-are cata/og, obtain the =,= for the D:L fi/e from Liferay's source code. 1ou -i// find this =,= in the definitions fo/der in the Liferay source. $t is a fi/e ca//ed liferay&%lugin&%ac5age/?/#/J'dtd. 0se this =,= -ith a va/idating D:L editor 5a good, free choice is J>dit -ith a// the D:L p/ugins6 to create your soft-are cata/og manua//y.

!1NN !T.NG T1 A S1*TWAR !ATAL1G


$f there is a soft-are cata/og of p/ugins that you -ou/d /i.e to point your instance of Liferay to, a// you need is the 0RL to the cata/og. ?nce you have the 0RL, go to the @/ugin $nsta//er in your Contro/ @ane/ and c/ic. the Configuration tab. 1ou -i// see that there are t-o fie/ds in -hich you can enter 0RLs to p/ugin repositories2 4rusted Plugin 9e%ositories and Untrusted Plugin 9e%ositories. Current/y, the on/y difference bet-een the t-o is to provide a visua/ cue for administrators as to -hich repositories are trus) ted and untrusted. >nter the 0RL to the repository to -hich you -ish to connect in one of the fie/ds and c/ic. )ave. ,he port/et -i// connect to the repository, and items from this reposit) ory -i// be sho-n in the /ist.

Li%era& Services 1riented Architecture


Liferay inc/udes a uti/ity ca//ed the )ervice "uilder -hich is used to generate a// of the /o- /eve/ code for accessing resources from the porta/ database. ,his uti/ity is fur) ther e4p/ained in the Liferay Develo%erSs .uide, but it is mentioned here because of its feature -hich generates interfaces not on/y for Java code, but a/so for -eb services and JavaScript. ,his means that the method ca//s for storing and retrieving porta/ ob) Iects are a// the same, and are generated in the same step.

!CC

Liferay Services ?riented Architecture

Advanced Liferay Configuration %ecause the actua/ method ca//s for re) trieving data are the same regard/ess of hoone gets access to those methods 5i.e., /oca//y or through -eb services6, Liferay provides a consistent interface for accessing porta/ data that fe- other products can match. ,he ac) tua/ interfaces for the various services -i// be covered in the Liferay Develo%erSs .uide, but before they can be used there are steps that need to be ta.en to enab/e users to ac) cess those services remote/y. $n the defau/t %ortal'%ro%erties fi/e, there is a section ca//ed %ain Ser!let. ,his section defines the security settings for a// of the re) mote services provided by Liferay. Copy this section and paste it into your custom %ortal& ext'%ro%erties fi/e, and you can configure se) curity settings for the A4is Serv/et, the Liferay ,unne/ Serv/et, the Spring Remoting Serv/et, the JS?& ,unne/ Serv/et, and the <eb=AB serv/et.

Illustration FF! Liferay )0ASs first layer of security'

%y defau/t, a user connecting from the same machine Liferay is running on can access remote services so /ong as that user has the permission to use those services in Liferay's permissions system. ?f course, you are not rea//y KremoteL un/ess you are accessing services from a different machine. Liferay has t-o /ayers of security -hen it comes to accessing its services remote/y. <ithout e4p/icit rights to both /ayers, a re) mote e4ception -i// be thro-n and access to those services -i// not be granted. ,he first /ayer of security that a user needs to get through in order to ca// a method from the service /ayer is serv/et security. ,he Main )ervlet section of the %ortal&ext'%ro%erties fi/e is used to enab/e or disab/e access to Liferay's remote services. $n that section of the properties fi/e, there are properties for each of Liferay's remote services. 1ou can set each service individua//y -ith the security settings that you reHuire. 9or e4amp/e, you may have a batch Iob -hich runs on another machine in your net) -or.. ,his Iob /oo.s in a particu/ar shared fo/der on your net-or. and up/oads docu) ments to your community's document /ibrary port/et on a regu/ar basis, using Liferay's -eb services. ,o enab/e this batch Iob to get through the first /ayer of secur) ity, you -ou/d modify the %ortal&ext'%ro%erties fi/e and put the $@ address of the ma) chine on -hich the batch Iob is running in the /ist for that particu/ar service. 9or e4) amp/e, if the batch Iob uses the A4is -eb services to up/oad the documents, you -ou/d enter the $@ address of the machine on -hich the batch Iob is running to the axis'ser& vlet'hosts'allowed property. A typica/ entry might /oo. /i.e this2
a<is.servlet.hosts.allowed 3P5.3?1.344.344, 35T.4.4.3, S.FK.FLI"

$f the machine on -hich the batch Iob is running has the $@ address A#!.A+(.A"".A"", this configuration -i// a//o- that machine to connect to Liferay's -eb services and pass in user credentia/s to be used to up/oad the documents.

Liferay Services ?riented Architecture

!C*

Advanced Liferay Configuration ,he second /ayer of security is Liferay's security mode/ that it uses for every ob) Iect in the porta/. ,he user $= that accesses the services remote/y must have the proper permission to operate on the obIects it -i// be accessing. ?ther-ise, a remote e4ception -i// be thro-n. ,he @orta/ Administrator -i// need to ma.e use of Liferay's usua/ means of granting access to these resources to the user $= that -i// be operating on them remote/y. 9or e4amp/e, say that a =ocument Lib) rary fo/der ca//ed Documents has been set up in a community. A ro/e has been created ca//ed Document U%loaders -hich has the rights to add documents to this fo/der. 1our batch Iob -i// be accessing Liferay's -eb ser) vices in order to up/oad documents into this fo/der. $n order for this to -or., you -i// have to ca// the -eb service using a user $= that is a member of this group 5or that has individua/ rights to add documents to this fo/der6. ?ther-ise, you -i// be prevented from using the <eb Service. ,o ca// the -eb service using creden)

Illustration FG! Liferay )0ASs second layer of security'

tia/s, you -ou/d use the fo//o-ing 0RL synta42


http*//D \ userId8sString \ D*D \ password \ DI9server.com:*9port:/tunnelweb/secure/a<is/D \ service'ame

,he user $= is the user's $= from the Liferay database. ,his may be obtained by /ogging in as the user and c/ic.ing My Account from the =oc.. $n the top /eft corner of the port/et that appears is the user $=. 9or e4amp/e, to get ?rganization data using a user that has the $= of # -ith a pass-ord of test, you -ou/d use the fo//o-ing 0RL2
http*//5*testIlocalhost*1414/tunnel-web/secure/a<is/"ortalLNrgani>ationService

Ti#$ %n older versions of Liferay A#.:.x and belowB& this password had to be the encrypted version from Liferay1s database.

$t is important to note here ho- Password Policies 5covered in Chapter 86 can be used in combination -ith this feature. $f you are enforcing pass-ord po/icies on your users 5reHuiring them to change their pass-ords on a periodic basis, etc.6, any admin) istrative $= -hich accesses Liferay's -eb services in a batch Iob -i// have its pass-ord e4pire too. !C+ Liferay Services ?riented Architecture

Advanced Liferay Configuration ,o prevent this from happening, you can add a ne- pass-ord po/icy -hich does not enforce the pass-ord e4piration and add your administrative user $= to it. ,hen your batch Iob can run as many times as you need it to, and the administrative $='s pass-ord -i// never e4pire. $n summary, accessing Liferay remote/y reHuires the successfu/ passing of t-o security chec.s2 A. !. ,he $@ address must be pre)configured in the server's %ortal&ext'%ro%erties fi/e. ,he user $= being used must have permission to access the resources it is at) tempting to access.

Accessin) Li%era&'s WS0L


After configuring the security settings proper/y, your first step in obtaining ac) cess to remote -eb services is to access the <S=L. $f you are on a bro-ser on the same machine Liferay is running on, you can do this by accessing the fo//o-ing 0RL2
http*//localhost*9port number:/tunnel-web/a<is

$f, for e4amp/e, you are running on ,omcat on port ("(", you -ou/d specify this 0RL2
http*//localhost*1414/tunnel-web/a<is

$f you are on a different machine from the Liferay server, you -i// need to pass in your user credentia/s on the 0RL to access the <S=L2
http*//9user I):*9password:I9server name:*9port number:/tunnel-web/a<is

$n any case, once you successfu//y bro-se to this 0RL, you -i// see the /ist of -eb services. <S=L for each service is avai/ab/e by c/ic.ing on the @)DL /in. ne4t to the name of the service. ,here are many servicesU one for each of the services avai/ab/e from the Liferay A@$. ?nce you c/ic. on one of the @)DL /in.s, the <eb Service =efinition Language document -i// be disp/ayed. ,his document can be used to generate c/ient code in any /anguage that supports it. 1ou can either save the document to your /oca/ machine and then generate the c/ient code that -ay, or use your too/ to trigger Liferay to gen) erate the document dynamica//y by using one of the 0RLs above. 9or further information about deve/oping app/ications that ta.e advantage of Liferay's remote services, p/ease see the Liferay Develo%erSs .uide.

Liferay Services ?riented Architecture

!C'

. ENTERPRISE CONFIGURATION

Liferay @orta/ is a robust, enterprise)ready porta/ so/ution. As such, it is fu//y ready to support mission)critica/, enterprise app/ications in an environment con) figured for mu/tip/e redundancy and !C7' up times. ,he product, ho-ever, /i.e other products of its .ind, does not come configured this -ay out of the bo4, and so there are some steps that need to be ta.en in order to configure it this -ay. ,his chapter -i// cover these topics in detai/. %ecause Liferay runs on so many different Java >> app/ication servers, it -i// be impossib/e to cover a// of the differ) ences bet-een these app/ication servers. 9or this reason, -e -i// cover the configura) tion of Liferay on/y. As an e4amp/e, -e -i// cover ho- to configure Liferay to -or. in a c/ustered environment, but -e -i// not cover ho- to create the c/uster in your ap) p/ication server. @/ease consu/t the documentation for your particu/ar app/ication server to see ho- you can configure your app/ication server of choice to -or. as a c/uster. <e -i//, ho-ever, cover the configuration of Liferay for a number of advanced scenarios, such as C/ustering and =istributed Caching Liferay <or.f/o=ep/oying Customized versions of Liferay @erformance ,esting and ,uning

=uring this discussion, -e -i// mention a number of other open source products upon -hich Liferay re/ies for much of this functiona/ity. ,hese products a// have their o-n documentation -hich shou/d be consu/ted for a fu//er vie- of -hat these products can do. 9or e4amp/e, Liferay uses >hcache for its caching mechanism. <e -i// cover ho- to configure >hcache to enab/e various caching functiona/ity in Liferay, but -i// refer you to that product's documentation for further information about that product.

>nterprise Configuration Sometimes Liferay supports mu/tip/e products -hich perform the same function. ,here are, for e4amp/e, mu/tip/e imp/ementations of >nterprise Service %uses for use -ith -or.f/o-, and Liferay supports severa/ of them. <e -i// /eave it up to you to se) /ect -hich product best fits the needs of your proIect -ithout recommending one product over another. <ith a// of that said, /et's get started configuring Liferay for the enterprise.

Unbreakable Liferay
To infinity and beyond

App er!er "luster Load Balancer Virtual Hosting

www.mytcl.com

www.mytte.com

www.mypmu.com

Multiple Domains

Load Balancer

Multiple Load Balancers

Liferay er!er # "ontroller #

Liferay er!er $ "ontroller $

Multiple Liferay er!ers

Database "luster

DB #

DB $

DB &

DB %

Multiple Databases

Illustration FK! IUnbrea5ableI Liferay architecture

Li%era& !lusterin)
?nce you have Liferay insta//ed in more than one node on your app/ication serv) er, there are severa/ optimizations that need to be made. At a minimum, Liferay shou/d be configured in the fo//o-ing -ay for a c/ustered environment2 A// nodes shou/d be pointing to the same Liferay database Jac.rabbit, the JSR)A'" content repository, shou/d be2 ?n a shared fi/e system avai/ab/e to a// the nodes 5not rea//y recommen) ded, though6, or $n a database that is shared by a// the nodes

!*"

Liferay C/ustering

>nterprise Configuration A/ternative/y, the =ocument Library shou/d be configured to use the 9i/e System ;oo., and the fi/es can be stored on a SA& for better performance. Simi/ar/y, Lucene, the fu// te4t search inde4er, shou/d be2 ?n a shared fi/e system avai/ab/e to a// the nodes 5not rea//y recommen) ded, though6, or $n a database that is shared by a// the nodes, or ?n separate fi/e systems for a// of the nodes, or =isab/ed, and a separate p/uggab/e enterprise search server configured 5recommended6.

$f you have not configured your app/ication server to use farms for dep/oy) ment, the hot dep/oy fo/der shou/d be a separate fo/der for a// the nodes, and p/ugins -i// have to be dep/oyed to a// of the nodes individua//y. ,his can be done via a script.

:any of these configuration changes can be made by adding or modifying prop) erties in your %ortal&ext'%ro%erties fi/e. Remember that this fi/e overrides the defau/ts that are in the %ortal'%ro%erties fi/e. ,he origina/ version of this fi/e can be found in the Liferay source code or can be e4tracted from the %ortal&im%l'*ar fi/e in your Liferay in) sta//ation. $t is a best practice to copy the re/evant section that you -ant to modify from %ortal'%ro%erties into your %ortal&ext'%ro%erties fi/e, and then modify the va/ues there.

All Nodes Should (e Pointin) to the Same Li%era& 0ata"ase


,his is pretty se/f)e4p/anatory. >ach node shou/d be configured -ith a data source that points to one Liferay database 5or a database c/uster6 that a// of the nodes -i// share. ,his ensures that a// of the nodes operate from the same basic data set. ,his means, of course, that Liferay cannot 5and shou/d not6 use the embedded ;SFL database that is shipped -ith the bund/es. $t is a/so best if the database server is a sep) arate physica/ bo4 from the server -hich is running Liferay.

0ocument Li"rar& !on%i)uration


Liferay *.!.4 no- defau/ts to using the fi/e system for storing documents. ,his has proven to be the highest performing configuration for /arge document /ibraries, -hich is -hy this decision -as made. 1ou can use the fi/e system for your c/ustered configuration, and Liferay's document /ibrary -i// prevent users from Kco//idingL -ith each other by versioning documents and /oc.ing the fi/es before they are modi) fied. $f you have a Storage Area &et-or. 5SA&6, you can configure Liferay to store documents there to ta.e advantage of the e4tra redundancy. ,o configure the /oca) tion -here your documents are stored, use the fo//o-ing property2
dl.hook.file.system.root.dir @Gliferay.homeH/data/documentLlibrary

$f you -ish to c/uster your document /ibrary configuration in a database, you can sti// do so using the Jac.rabbit JSR)A'" repository. 1ou -ou/d a/so use the Jac.rabbit repository if you -ant to have a JSR)A'" comp/iant repository for your documents.

Liferay C/ustering

!*A

>nterprise Configuration

Jac'ra""it Sharin)
Liferay uses Jac.rabbit3-hich is a proIect from Apache3as its JSR)A'" comp/iant document repository. %y defau/t, Jac.rabbit is configured to store the documents on the /oca/ fi/e system upon -hich Liferay is insta//ed, in the -H0M1+liferay+*ac5rabbit fo/der. $nside this fo/der is Jac.rabbit's configuration fi/e, ca//ed re%ository'xml. ,o simp/y move the defau/t repository /ocation to a shared fo/der, you do not need to edit Jac.rabbit's configuration fi/e. $nstead, find the section in %ortal'%ro%erties /abe/ed 4C: and copy7paste that section into your %ortal&ext'%ro%erties fi/e. ?ne of the properties, by defau/t, is the fo//o-ing2
jcr.jackrabbit.repository.root @Gliferay.homeH/data/jackrabbit

Change this property to point to a shared fo/der that a// of the nodes can see. A ne- Jac.rabbit configuration fi/e -i// be generated in that /ocation. &ote that because of fi/e /oc.ing issues, this is not the best -ay to share Jac.rab) bit resources. $f you have t-o peop/e /ogged in at the same time up/oading content, you cou/d encounter data corruption using this method, and because of this, -e do not recommend it for a production system. $nstead, to enab/e better data protection, you shou/d redirect Jac.rabbit into your database of choice. 1ou can use the Liferay database or another database for this purpose. ,his -i// reHuire editing Jac.rabbit's configuration fi/e. ,he defau/t Jac.rabbit configuration fi/e has sections commented out for moving the Jac.rabbit configuration into the database. ,his has been done to ma.e it as easy as possib/e to enab/e this configuration. ,o move the Jac.rabbit configuration into the database, simp/y comment out the sections re/ating to the fi/e system and comment in the sections re/ating to the database. ,hese by defau/t are configured for a :ySFL database. $f you are using another database, you -i// /i.e/y need to modify the config) uration, as there are changes to the configuration fi/e that are necessary for specific databases. 9or e4amp/e, the defau/t configuration uses Jac.rabbit's Db(ile)ystem c/ass to mimic a fi/e system in the database. <hi/e this -or.s -e// in :ySFL, it does not -or. for a// databases. 9or e4amp/e, if you are using an ?rac/e database, you -i// need to modify this to use 0racle(ile)ystem. @/ease see the Jac.rabbit documentation at http277Iac.rabbit.apache.org for further information. 1ou -i// a/so /i.e/y need to modify the J=%C database 0RLs so that they point your database. =on't forget to create the database first, and grant the user $= you are specifying in the configuration fi/e access to create, modify, and drop tab/es. ?nce you have configured Jac.rabbit to store its repository in a database, the ne4t time you bring up Liferay, the necessary database tab/es -i// be created automat) ica//y. Jac.rabbit, ho-ever, does not create inde4es on these tab/es, and so over time this can be a performance pena/ty. ,o fi4 this, you -i// need to manua//y go into your database and inde4 the primary .ey co/umns for a// of the Jac.rabbit tab/es. A// of your Liferay nodes shou/d be configured to use the same Jac.rabbit repos) itory in the database. ?nce that is -or.ing, you can create a Jac.rabbit c/uster 5p/ease see the section be/o-6.

!*!

Liferay C/ustering

>nterprise Configuration

Search !on%i)uration
1ou can configure search in one of t-o -ays2 use p/uggab/e enterprise search 5recommended for a c/uster configuration6 or configure Lucene in such a -ay that either the inde4 is stored on each node's fi/e system or is shared in a database.

PL-GGA(L

NT RPR.S

S AR!3

As an a/ternative to using Lucene, Liferay *.A and higher no- supports p/uggab/e search engines. ,he first imp/ementation of this uses the open source search engine )olr$ but in the future there -i// be many such p/ugins for your search engine of choice. ,his a//o-s you to use a comp/ete/y separate product for search, -hich can be insta//ed on another app/ication server in your environment. 1our search engine then operates comp/ete/y independent/y of your Liferay @orta/ nodes in a c/ustered envir) onment, acting as a search service for a// of the nodes simu/taneous/y. ,his so/ves the prob/em described be/o- -ith sharing Lucene inde4es. 1ou can no- have one search inde4 for a// of the nodes of your c/uster -ithout having to -orry about putting it in a database 5if you -ish, you can sti// do this if you configure So/r or another search engine that -ay6 or maintaining separate search inde4es on a// of your nodes. >ach Liferay node -i// send reHuests to the search engine to update the search inde4 -hen needed, and these updates are then Hueued and hand/ed automat) ica//y by the search engine, independent/y. Since at the time of this -riting there is on/y one imp/ementation of the p/ug) gab/e enterprise search, -e -i// cover ho- to imp/ement this using So/r.

!1N*.G-R.NG

T3

S1LR S AR!3 S R> R

Since So/r is a standa/one search engine, you -i// need to do-n/oad it and insta// it first according to the instructions on the So/r -eb site 5http277/u) cene.apache.org7so/r6. So/r is distributed as a .-ar fi/e -ith severa/ .Iar fi/es -hich need to be avai/ab/e on your app/ication server's c/ass path. ?nce you have So/r up and running, integrating it -ith Liferay is easy, but it -i// reHuire a restart of your ap) p/ication server. ,he first thing you -i// need to define is the /ocation of your search inde4. As) suming you are running a Linu4 server and you have mounted a fi/e system for the in) de4 at +solr, create an environment variab/e that points to this fo/der. ,his environ) ment variab/e needs to be ca//ed -)0L9/H0M1. So for our e4amp/e, -e -ou/d define2
@SN!FLMN$. /solr

,his environment variab/e can be defined any-here you need2 in your operating system's start up seHuence, in the environment for the user -ho is /ogged in, or in the start up script for your app/ication server. $f you are going to use ,omcat to host So/r, you -ou/d modify catalina'sh or catalina'bat and add the environment variab/e there. ?nce you have created the environment variab/e, you then can use it in your ap) p/ication server's start up configuration as a parameter to your JB:. ,his is con) figured different/y per app/ication server, but again, if you are using ,omcat, you -ou/d edit catalina'sh or catalina'bat and append the fo//o-ing to the -3A<A/0P4) vari)

Liferay C/ustering

!*8

>nterprise Configuration ab/e2


-)solr.solr.home @SN!FLMN$.

,his ta.es care of te//ing So/r -here to store its search inde4. Go ahead and in) sta// So/r to this bo4 according to the instructions on the So/r -eb site 5http277/u) cene.apache.org7so/r6. ?nce it's insta//ed, shut it do-n, as there is some more config) uration to do.

.NSTALL.NG

T3

S1LR L.*

RA5

PL-G.N

&e4t, you have a choice. $f you have insta//ed So/r on the same system upon -hich Liferay is running, you can simp/y go to the Contro/ @ane/ and insta// the solr& web p/ugin. ,his, ho-ever, defeats much of the purpose of using So/r, because the goa/ is to off/oad search inde4ing to another bo4 in order to free up processing for your in) sta//ation of Liferay. 9or this reason, you shou/d not run Liferay and your search en) gine on the same bo4. 0nfortunate/y, the configuration in the p/ugin defau/ts to hav) ing So/r and Liferay running on the same bo4, so to run them separate/y, you -i// have to ma.e a change to a configuration fi/e in the p/ugin before you insta// it so you can te// Liferay -here to send inde4ing reHuests. $n this case, go to the Liferay -eb site 5http277---./iferay.com6 and do-n/oad the p/ugin manua//y. ?pen or e4tract the p/ugin. $nside the p/ugin, you -i// find a fi/e ca//ed solr& s%ring'xml in the @1"&I6(+classes+M14A&I6( fo/der. ?pen this fi/e in a te4t editor and you -i// see that there are t-o entries -hich define -here the So/r server can be found by Liferay2
9bean id Dinde<SearcherD class Dcom.liferay.portal.search.solr.SolrInde<SearcherImplD: /: 9/bean: 9bean id Dinde<RriterD class Dcom.liferay.portal.search.solr.SolrInde<RriterImplD: /: 9/bean: 9property name Dserver,F!D value Dhttp*//localhost*1414/solr/updateD 9property name Dserver,F!D value Dhttp*//localhost*1414/solr/selectD

:odify these va/ues so that they point to the server upon -hich you are running So/r. ,hen save the fi/e and put it bac. into the p/ugin archive in the same p/ace it -as before. &e4t, e4tract the fi/e schema'xml from the p/ugin. $t shou/d be in the docroot+@1"& I6(+conf fo/der. ,his fi/e te//s So/r ho- to inde4 the data coming from Liferay, and can be customized for your insta//ation. Copy this fi/e to -)0L9/H0M1+conf 5you may have to create the conf directory6 on your So/r bo4. &o- you can go ahead and start So/r. 1ou can no- hot dep/oy the solr&web p/ugin to a// of your nodes. See the ne4t sec) tion for instructions on hot dep/oying to a c/uster. ?nce the p/ugin is hot dep/oyed, your Liferay search is automatica//y upgraded to use So/r. $t is /i.e/y, ho-ever, that initia/ searches -i// come up -ith nothing2 this is because you -i// need to reinde4 everything using So/r. Go to the Contro/ @ane/. $n the )erver section, c/ic. )erver Administration. C/ic. the !*C Liferay C/ustering

>nterprise Configuration 1xecute button ne4t to 9eindex all search indexes at the bottom of the page. $t may ta.e a -hi/e, but Liferay -i// begin sending inde4ing reHuests to So/r for e4ecution. <hen the process is comp/ete, So/r -i// have a comp/ete search inde4 of your site, and -i// be running independent/y of a// of your Liferay nodes. $nsta//ing the p/ugin to your nodes has the effect of overriding any ca//s to Lu) cene for searching. A// of Liferay's search bo4es -i// no- use So/r as the search inde4. ,his is idea/ for a c/ustered environment, as it a//o-s a// of your nodes to share one search server and one search inde4, and this search server operates independent/y of a// of your nodes.

L-! N !1N*.G-RAT.1N
Lucene, the search inde4er -hich Liferay uses, can be in a shared configuration for a c/ustered environment, or an inde4 can be created on each node of the c/uster. $f you -ish to have a shared inde4, you -i// need to either share the inde4 on the fi/e system or in the database. ,he Lucene configuration can be changed by modifying va/ues in your %ortal&ext'& %ro%erties fi/e. ?pen your %ortal'%ro%erties fi/e and search for the te4t Lucene. Copy that section and then paste it into your %ortal&ext'%ro%erties fi/e. $f you -ish to store the Lucene search inde4 on a fi/e system that is shared by a// of the Liferay nodes, you can modify the /ocation of the search inde4 by changing the lucene'dir property. %y defau/t, this property points to the lucene fo/der inside the home fo/der of the user that is running Liferay2
lucene.dir @Gliferay.homeH/data/lucene/

Change this to the fo/der of your choice. ,o ma.e the change ta.e effect, you -i// need to restart Liferay. 1ou can point a// of the nodes to this fo/der, and they -i// use the same inde4. Li.e Jac.rabbit, ho-ever, this is not the best -ay to share the search inde4, as it cou/d resu/t in fi/e corruption if different nodes try reinde4ing at the same time. <e do not recommend this for a production system. A better -ay is to share the inde4 is via a database, -here the database can enforce data integrity on the inde4. ,his is very easy to doU it is a simp/e change to your %ortal&ext'%ro%erties fi/e. ,here is a sing/e property ca//ed lucene'store'ty%e. %y defau/t this is set to go to the fi/e system. 1ou can change this so that the inde4 is stored in the database by ma.ing it the fo//o-ing2
lucene.store.type jdbc

,he ne4t time Liferay is started, ne- tab/es -i// be created in the Liferay data) base, and the inde4 -i// be stored there. $f a// the Liferay nodes point to the same database tab/es, they -i// be ab/e to share the inde4. @erformance on this is not a/) -ays as good as it cou/d be. 1our =%As may be ab/e to t-ea. the database inde4es a bit to improve performance. 9or better performance, you shou/d consider using a sep) arate search server 5see the section on So/r above6. 3ote) :ySFL users need to modify their J=%C connection string for this to -or.. Add the fo//o-ing parameter to your connection string2 Liferay C/ustering !**

>nterprise Configuration
emulate!ocators true

A/ternative/y, you can /eave the configuration a/one, and each node -i// then have its o-n inde4. ,his ensures that there are no co//isions -hen mu/tip/e nodes up) date the inde4, because they a// -i// have separate inde4es. ,his, ho-ever, creates du) p/icate inde4es and may not be the best use of resources. Again, for a better configur) ation, you shou/d consider using a separate search server 5see the section on So/r above6.

3ot 0e#lo&
@/ugins -hich are hot dep/oyed -i// need to be dep/oyed separate/y to a// of the Liferay nodes. >ach node shou/d, therefore, have its o-n hot dep/oy fo/der. ,his fo/der needs to be -ritab/e by the user under -hich Liferay is running, because p/ugins are moved from this fo/der to a temporary fo/der -hen they are dep/oyed. ,his is to pre) vent the system from entering an end/ess /oop, because the presence of a p/ugin in the fo/der is -hat triggers the hot dep/oy process. <hen you -ant to dep/oy a p/ugin, copy that p/ugin to the hot dep/oy fo/ders of a// of the Liferay nodes. =epending on the number of nodes, it may be best to create a script to do this. ?nce the p/ugin has been dep/oyed to a// of the nodes, you can then ma.e use of it 5by adding the port/et to a page or choosing the theme as the /oo. and fee/ for a page or page hierarchy6. Some containers contain a faci/ity -hich a//o-s the end user to dep/oy an app/ic) ation to one node, after -hich it -i// get copied to a// of the other nodes. $f you have configured your app/ication server to support this, you -on't need to hot dep/oy a p/ugin to a// of the nodes3your app/ication server -i// hand/e it transparent/y. :a.e sure, ho-ever, that you use Liferay's hot dep/oy mechanism to dep/oy p/ugins, as in many cases Liferay s/ight/y modifies p/ugin .-ar fi/es -hen hot dep/oying them. A// of the above -i// get basic Liferay c/ustering -or.ingU ho-ever, the configura) tion can be further optimized. <e -i// see ho- to do this ne4t.

0istri"uted !achin)
Liferay C.8.A and higher uses #hcache, -hich has robust distributed caching sup) port. ,his means that the cache can be distributed across mu/tip/e Liferay nodes run) ning concurrent/y. >nab/ing this cache can increase performance dramatica//y. 9or e4amp/e, say that t-o users are bro-sing the message boards. ,he first user c/ic.s on a thread in order to read it. Liferay must /oo. up that thread from the database and format it for disp/ay in the bro-ser. <ith a distributed >hcache running, this thread can be pu//ed from the database and stored in a cache for Huic. retrieva/. Say then that the second user -ants to read the same forum thread and c/ic.s on it. ,his time, because the thread is in the /oca/ cache, no trip to the database is necessary, and so retrieving the data is much faster. ,his cou/d be done by simp/y having a cache running separate/y on each node, but the po-er of distributed caching a//o-s for more functiona/ity. ,he first user can post a message to the thread he or she -as reading, and the cache -i// be updated across a// of the nodes, ma.ing the ne- post avai/ab/e immediate/y from the /oca/ cache. <ithout that, the second user -ou/d need to -ait unti/ the cache -as inva/id) !*+ =istributed Caching

>nterprise Configuration ated on the node he or she connected to before he or she cou/d see the updated forum post. Configuring distributed caching reHuires the modification of the %ortal&ext'%ro%& erties fi/e as -e// as one or more other fi/es depending on -hat you -ant to cache. ,he first thing you -i// -ant to do is determine -here on your server you -i// -ant to store your cache configuration fi/es. ,his -i// have to be some-here on Liferay's c/ass path, so you -i// need to find -here your app/ication server has stored the dep/oyed version of Liferay, and create a fo/der in Liferay's @1"&I6(+classes fo/der to store the fi/es. %ecause the origina/, defau/t fi/es are stored inside of a .Iar fi/e, you -i// need to e4tract them to this area and then te// Liferay 5by use of the %ortal&ext'%ro%erties fi/e6 -here they are. 9or e4amp/e, say you are running Liferay on ,omcat. ,omcat stores the dep/oyed version of Liferay in T4omcat HomeR+weba%%s+9004. $nside of this fo/der is the fo/der structure @1"&I6(+classes' 1ou can create a ne- fo/der in here ca//ed myehcache to store the custom versions of the cache configuration fi/es. Copy the fi/es from the +ehcache fo/der3-hich is inside the %ortal&im%l'*ar file,into the myehcache fo/der you Iust created. 1ou then need to modify the properties in %ortal&ext'%ro%erties that point to these fi/es. Copy 7 paste the 2ibernate section of %ortal'%ro%erties into your %ortal& ext'%ro%erties fi/e and then modify the net'sf'ehcache'configuration9esource6ame prop) erty to point to the c/ustered version of the configuration fi/e that is no- in your cus) tom fo/der2
net.sf.ehcache.configurationFesource'ame /myehcache/hibernate-clustered.<ml

&o- that Liferay is pointing to your custom fi/e, you can modify the settings in this fi/e to change the cache configuration for ;ibernate. &e4t, copy 7 paste the 1hcache section from the %ortal'%ro%erties fi/e into your %ortal&ext'%ro%erties fi/e. :odify the properties so that they point to the fi/es that are in your custom fo/der. 9or e4amp/e2
ehcache.multi.vm.config.location /myehcache/liferay-multi-vm.<ml

$f you are going to enab/e distributed c/ustering, uncomment the fo//o-ing /ine and point it to your custom version of the fi/e2
ehcache.multi.vm.config.location /myehcache/liferay-multi-vm-clustered.<ml

1ou can no- ta.e a /oo. at the settings in these fi/es and tune them to fit your environment and app/ication. A/ternative/y, if your Liferay proIect is using the e4tension environment to ma.e customizations to Liferay, you can p/ace your cache configuration in the e4tension environment. ,he settings there -i// override the defau/t settings that ship -ith Liferay. $f you -ish to do this, you can create ne- versions of the fi/es in ext& im%l+classes+ehcache. ,he fi/es shou/d be postfi4ed -ith &ext'xml. 9or e4amp/e, the cus) tom version of hibernate'xml shou/d be ca//ed hibernate&ext'xml$ and the custom version of liferay&multi&vm&clustered'xml shou/d be ca//ed liferay&multi&vm&clustered&ext'xml' 1ou can then modify the fi/es and tune them to fit your environment 7 app/ication, and they -i// be dep/oyed a/ong -ith the rest of your e4tension environment.

=istributed Caching

!*'

>nterprise Configuration

3.( RNAT !A!3 S TT.NGS


%y defau/t, ;ibernate 5Liferay's database persistence /ayer6 is configured to use >hcache as its cache provider. ,his is the recommended setting. ,he defau/t configur) ation, ho-ever, points to a fi/e that does not have c/ustering enab/ed. ,o enab/e c/us) tering, copy the Hibernate section from %ortal'%ro%erties into your %ortal&ext'%ro%erties fi/e. ,o enab/e a c/ustered cache, comment out the defau/t fi/e 5hibernate'xml6 and un) comment the c/ustered version of the fi/e, ma.ing sure that you change the path so that it points to your custom version of the fi/e2
net.sf.ehcache.configurationFesource'ame /myehcache/hibernate-clustered.<ml

&e4t, open this fi/e in a te4t editor. 1ou -i// notice that the configuration is a/ready set up to perform distributed caching through a mu/ti)cast connection. $t is /i.e/y, ho-ever, that the configuration is not set up optima//y for your particu/ar ap) p/ication. 1ou -i// notice that by defau/t, the on/y obIect cached in the ;ibernate cache is the 0ser obIect 5com'liferay'%ortal'model'im%l'UserIm%l6. ,his means that -hen a user /ogs in, his or her 0ser obIect -i// go in the cache so that any porta/ operation that reHuires access to it 5such as permission chec.ing6 can retrieve that obIect very Huic./y from the cache. 1ou may -ish to add other obIects to the cache. 9or e4amp/e, a /arge part of your app/ication may be document management using the =ocument Library port/et. $n this case, you may -ant to cache =ocument Library obIects, such as DL(ile1ntryIm%l in order to improve performance as users access documents. ,o do that, add another b/oc. to the configuration fi/e -ith the c/ass you -ant to cache2
9cache name Dcom.liferay.portlet.documentlibrary.model.impl.DLFileEntryImplD ma<.lementsIn$emory D34444D eternal DfalseD time/oIdleSeconds D?44D overflow/o)isk DtrueD : 9cache.vent!istener0actory class Dnet.sf.ehcache.distribution.F$I&acheFeplicator0actoryD properties Dreplicate"uts false,replicate,pdatesKia&opy falseD propertySeparator D,D /: 9bootstrap&ache!oader0actory class Dnet.sf.ehcache.distribution.F$ISootstrap&ache!oader0actoryD /: 9/cache:

1our site may use the message boards port/et, and those message boards may get a /ot of traffic. ,o cache the threads on the message boards, configure a b/oc. -ith the :%:essage$mp/ c/ass2
9cache name Dcom.liferay.portlet.messageboards.model.impl.MBMessageImplD ma<.lementsIn$emory D34444D eternal DfalseD time/oIdleSeconds D?44D

!*(

=istributed Caching

>nterprise Configuration
overflow/o)isk DtrueD : 9cache.vent!istener0actory class Dnet.sf.ehcache.distribution.F$I&acheFeplicator0actoryD properties Dreplicate"uts false,replicate,pdatesKia&opy falseD propertySeparator D,D /: 9bootstrap&ache!oader0actory class Dnet.sf.ehcache.distribution.F$ISootstrap&ache!oader0actoryD /: 9/cache:

&ote that if your deve/opers have overridden any of these c/asses, you -i// have to specify the overridden versions rather than the stoc. ones that come -ith Liferay @orta/. As you can see, it is easy to add specific data to be cached. %e carefu/, ho-ever, as too much caching can actua//y reduce performance if the JB: runs out of memory and starts garbage co//ecting too freHuent/y. 1ou -i// /i.e/y need to e4periment -ith the memory settings on your JB: as -e// as the cache settings above. 1ou can find the specifics about these settings in the documentation for >hcache.

!L-ST

R.NG JA!2RA((.T

$f you are using the =ocument Library, by defau/t you are using the JSR)A'" doc) ument repository, -hich is the Apache product 3ac5rabbit. 1ou have a/ready con) figured basic data sharing among nodes by moving its configuration into a database. ,he ne4t thing you need to do is configure c/ustering for Jac.rabbit, so that each node .no-s about data being entered into the repository by other nodes. 1ou can find the Jac.rabbit configuration fi/e in TLiferay User HomeR+liferay+*ac5& rabbit. ,he fi/e is ca//ed re%ository'xml. 1ou have /i.e/y a/ready edited this fi/e -hen you modified the configuration to move the data into the database. At the bottom of this fi/e is a c/uster configuration that is commented out. $f you are using a :ySFL database, you can uncomment this section and use it as)is. 1ou -i// need to change the c/uster $= for each node so that they don't conf/ict -ith one an) other. $f you are using another database, the on/y changes necessary are the connec) tion, credentia/s, and schema settings. :odify them according to your database of choice and then save the fi/e. ,his is a// it ta.es to set up c/ustering for Jac.rabbit.

Wor'%low
,he -or.f/o- port/et a//o-s a user to define any number of simp/e to comp/e4 business processes7-or.f/o-s, dep/oy them, and manage them through a porta/ in) terface. ,he po-er of this port/et is that it a//o-s users to create forms)based data entry app/ications that are fu//y integrated -ith Liferay's permissions system. ,hey have .no-/edge of users, groups, and ro/es -ithout -riting a sing/e /ine of code3it on/y reHuires the creation of a sing/e D:L document. ,he port/et re/ies on :u/e or Apache Service:i4 to function as an >nterprise Ser) <or.f/o!*#

>nterprise Configuration vice %us 5>S%6 that acts as a bro.er bet-een the porta/ and a -or.f/o- engine. >ssen) tia//y, the porta/ provides a generic interface through -hich -or.f/o- services are re) Huested via norma/ ;,,@ ca//s. ,he reHuests are routed through the >S% -hich in turn ca//s a -or.f/o- engine imp/ementation that the user has defined in the >S% configuration. %y defau/t, Liferay provides an imp/ementation of J%ossO I%@: -or.) f/o- engine.

.nstallation and Test


,o enab/e -or.f/o- in the porta/, you -i// have to insta// three p/ugins2 the -or.) f/o- port/et itse/f, the I%@: -eb p/ugin, and one of the >S% -eb p/ugins. ,he /atter t-o are convenient/y /ocated on the web tab of the Plugins Installation section of the Contro/ @ane/. 1ou -i// need to have I%@: and one of the >S% p/ugins insta//ed. ?nce you insta// the p/ugins, fo//o- these steps to get everything configured proper/y2 A. 9or :u/e, ma.e sure the fo//o-ing property in %ortal&ext'%ro%erties is set to the fo//o-ing2
jbi.workflow.url http*//localhost*1414/mule-web/workflow

9or Service:i4, ma.e sure the fo//o-ing property in %ortal&ext'%ro%erties is set to the fo//o-ing2
jbi.workflow.url http*//localhost*1414/servicemi<-web/workflow

!. 8. C. *. +. '.

Restart your app/ication server if you needed to change the above property. Login to the porta/ as the porta/ administrator. ,he defau/t credentia/s are testVliferay'com+test. Add the @or5flow port/et to a page. C/ic. on the Definitions tab. C/ic. on the Add button. Copy and paste the contents of *b%m&web'war+@1"& I6(+definitions+dataty%es/definition'xml into the te4t area and c/ic. the )ave 6ew <ersion button. C/ic. on the Add Instance icon. 9rom the Instances tab, c/ic. on the Manage icon ne4t to 1nter data.

(. #.

A". 9i// out the form and c/ic. the )ave buttonU a/ternative/y, you can test the various error chec.ing capabi/ities by inputting incorrect va/ues and c/ic.) ing the )ave button. AA. >ventua//y, enter correct va/ues and c/ic. the )ave button. A!. 9rom the Instances tab, c/ic. on the Manage icon ne4t to <iew Data. A8. Confirm that a// the data -as entered correct/y and c/ic. the (inished button. AC. Confirm that the instance is no- in the 1nd state.

!+"

<or.f/o-

>nterprise Configuration

-sin) 0i%%erent 0ata"ases


,he defau/t imp/ementation of I%@: uses an ;SFL database found in *b%m& web'war+@1"&I6(+s7l+*b%m'H. ,o change the /ocation of the ;SFL database, change the va/ue of the hibernate'connection'url property in *b%m&web'war+@1"&I6(+classes+hibern& ate'cfg'xml. ,he /ocation is re/ative/y addressed from -herever the startup script for your server is /ocated. ,o use a database other than ;SFL, first create the database schema using one of the SFL create scripts supp/ied in the *b%m&web'war+@1"&I6(+s7l directory. ,hen un) comment the corresponding hibernate connection properties b/oc. in *b%m&web'war+ @1"&I6(+classes+hibernate'cfg'xml.

3ow the Wor'%low Portlet Wor's


Since the defau/t imp/ementation of the -or.f/o- port/et re/ies heavi/y on the capabi/ities of I%@:, this section gives a technica/ overvie- of I%@: and e4p/ains hoit integrates into Liferay using I%@: @rocess =efinition Language 5J@=L6 formatted D:L fi/es. $t does not, ho-ever, give an in depth vie- of I%@:. 9or that, p/ease refer to the I%@: user guide 5http277docs.Iboss.com7Ibpm7v87userguide6.

PR1! SS 0 *.N.T.1NS
%efore the -or.f/o- port/et can be used, business processes must be defined. %usiness processes in I%@: are defined by D:L documents .no-n as %rocess defini& tions -hich are -ritten in I%@: @rocess =efinition Language 5J@=L6. ,his D:L format specifies entities such as the process ro/es 5.no-n as swimlanes6, the various states in the process 5.no-n as nodes6, the tas.s associated -ith each node, the ro/es associated -ith each tas., the transitions from one node to the ne4t, the variab/es associated -ith each tas.Os form, the e4terna/ actions e4ecuted on entry or e4it of a node, and many others. 9or an in depth understanding of process definitions and J@=L, refer to J%ossO I%@: user guide at the /in. above. ,here are three samp/e process definition D:Ls that are pac.aged -ith the port) /et. ,hey can be found in *b%m&web'war+@1"&I6(+definitions. <e used one in the Huic. start section above to create a samp/e -or.f/o-. An e4p/anation of each is inc/uded be/o-.

.NT GRAT.NG W.T3 -S RS, !1//-N.T. S,

AN0

R1L S

$n J@=L, there is the notion of process ro/es ca//ed swimlanes. S-im/anes can be associated -ith Liferay users, communities, and ro/es via the $dentityAssign) ment;and/er c/ass.
9swimlane name DapproverD: 9assignment class Dcom.liferay.jbpm.handler.Identity8ssignmentMandlerD config-type DfieldD: 9type:user9/type: 9companyId:344P69/companyId: 9id:343359/id: 9/assignment:

<or.f/o-

!+A

>nterprise Configuration
9/swimlane:

$n the D:L above, the a%%rover s-im/ane is associated -ith the Liferay user that has a 0ser $= of J # and be/ongs to a Company $= of JJK?. 1ou can a/so associ) ate a Liferay user -ith a s-im/ane by emai/ address as sho-n in the fo//o-ing D:L snippet.
9swimlane name DshipperD: 9assignment class Dcom.liferay.jbpm.handler.Identity8ssignmentMandlerD config-type DfieldD: 9type:user9/type: 9companyId:344P69/companyId: 9name:test.la<.5Iliferay.com9/name: 9/assignment: 9/swimlane:

$n the D:L above, the shi%%er s-im/ane is associated -ith the Liferay user that has an emai/ address of Ktest./a4.![/iferay.comL and be/ongs to a Company $= of JJK?.
9swimlane name DsalesmanD: 9assignment class Dcom.liferay.jbpm.handler.Identity8ssignmentMandlerD config-type DfieldD: 9type:community9/type: 9companyId:344P69/companyId: 9id:29/id: 9/assignment: 9/swimlane:

$n the D:L above, the salesman s-im/ane is associated -ith any Liferay user that be/ongs to a Community -ith the Group $= of 2 5-hich defau/ts to the )u%%ort com) munity if you are using the embedded ;SFL database that comes -ith the Liferay @orta/ bund/es6 and Company $= of JJK?. $n other -ords, the sa/esman s-im/ane is as) signed to the poo/ of )u%%ort users. $f one of these users -ere to manage a sa/esman tas., he7she -ou/d automatica//y be assigned to a// other sa/esman tas.s in the -or.) f/o-.
9swimlane name DaccountantD: 9assignment class Dcom.liferay.jbpm.handler.Identity8ssignmentMandlerD config-type DfieldD: 9type:community9/type: 9companyId:344P69/companyId: 9name:Support9/name: 9/assignment: 9/swimlane:

,he D:L above sho-s an a/ternative -ay to associate the accountant s-im/ane -ith the Support community using the actua/ communityOs name. Since community names must be uniHue per Company $=, this format accomp/ishes the same resu/ts as the previous D:L.
9swimlane name DuserLadminD: 9assignment class Dcom.liferay.jbpm.handler.Identity8ssignmentMandlerD config-type DfieldD:

!+!

<or.f/o-

>nterprise Configuration
9type:role9/type: 9companyId:344P69/companyId: 9id:34439/id: 9/assignment: 9/swimlane: 9swimlane name DuserLinterviewerD: 9assignment class Dcom.liferay.jbpm.handler.Identity8ssignmentMandlerD config-type DfieldD: 9type:role9/type: 9companyId:344P69/companyId: 9name:,ser Interviewer9/name: 9/assignment: 9/swimlane:

,he t-o D:L snippets above are very simi/ar to the Group D:L snippets. %oth associate their respective s-im/anes -ith a ro/e, but the first D:L does so using the Ro/e $=, and the second D:L does so using the ro/eOs uniHue name.

0ATA T5P S AN0

RR1R

!3 !2.NG

Current/y, I%@: doesnOt have support for variab/e data types. ;o-ever, data types have been dea/t -ith in the -or.f/o- port/et by incorporating them into the names of the contro//er variab/es. ,he tab/e be/o- sho-s the data types supported by the port/et as -e// as the synta4 for the variab/e names2

<or.f/o-

!+8

>nterprise Configuration

0ata T&#e )heck" box Date Email Number -ass" word -hone 2adio .utton (elect .ox Text Textarea

S&nta+ checkbox?name?checkedCalue date?name email?name number?name password?name phone?name radio?name?option!&option:&FG

0escri#tion
name$ the caption next to the checkbox checkedCalue D the value assigned to the variable if the checkbox is checked name$ the caption next to the date selector ob0ect name$ the caption next to the text input field name$ the caption next to the text input field name$ the caption next to the text input field name$ the caption next to the text input field name$ the caption next to the radio buttons o#tion6,o#tion8,EF $ a comma"delimited list of options that represent the different radio button options name$ the caption next to the select box o#tion6,o#tion8,EF $ a comma"delimited list of options that represent the different op" tions in the select drop"down name$ the caption next to the text input field name$ the caption next to the textarea input field

select?name?option!&option:&FG

text?name textarea?name

&ote that for a// name and option va/ues, the va/ues shou/d be entered in the D:L in /o-er case -ith hyphens used bet-een -ords2
radio*are-you-hungry*yes,no,a-little-bit

$n addition, you shou/d register the corresponding disp/ay va/ues in the Lan& guage'%ro%erties fi/e2
are-you-hungry 8re you hungry+ yes Zes no 'o a-little-bit 8 little bit

,his -i// ensure that the va/ues are disp/ayed correct/y in the port/et to the user. %y defau/t, a// variab/es are readab/e and -ritab/e by the user. ,herefore, they can be defined as fo//o-s2
9variable name Dte<tarea*commentsD /:

;o-ever, if variab/es shou/d on/y be readab/e or -ritab/e, or if variab/es are re) Huired, these must be specified in the variab/e definition2

!+C

<or.f/o-

>nterprise Configuration
9variable name Dte<t*nameD access Dread,write,re(uiredD /: 9variable name Ddate*birthdayD access DreadD /:

Bariab/es of data type =ate, &umber, >mai/, and @hone are va/idated in the ser) vice ca//. A/so, reHuired fie/ds are va/idated to ensure a va/ue of some .ind -as sub) mitted. $f inva/id va/ues are submitted, the user is returned to the origina/ form and error messages are disp/ayed ne4t to the inva/id input fie/ds. Refer to the samp/e definition *b%m&web'war+@1"&I6(+definitions+dataty%es/defini& tion'xml for e4amp/es of a// data types in use in a sing/e form. J%oss a/so provides a graphica/ J@=L editor -hich is imp/emented as an >c/ipse p/ugin. ,his editor a//o-s you to design -or.f/o-s graphica//y, rather than using an D:L editor. 1ou can find this too/ at http277---.Iboss.org7too/s.

Illustration GJ! 4he 3PDL editor from 3"oss

SA/PL PR1! SS 0 *.N.T.1NS


,he best -ay to understand J@=L is to /oo. over the 8 samp/e D:L fi/es inc/uded -ith the -or.f/o- port/et. ,hey can be found in *b%m&web'war+@1"&I6(+definitions+. %e/o- is a Huic. summary of each2 datat pe$Ddefinition.(+l a a good guide to fo//o- to understand ho- to use each of the data types described in the section above holida Ddefinition.(+l a a simp/e -or.f/o- that a//o-s an emp/oyee to ma.e a ho/iday reHuest -ith a start and end date, and then a manager can either approve, re) Iect, or send the reHuest bac. for revie1eb$aleDdefinition.(+l a a more comp/e4 -or.f/o- that emu/ates an on/ine auction site in -hich contro/ of the -or.f/o- passes through various ro/es. $t is the most comp/icated of the 8 -or.f/o-s, but it demonstrates a/most a// of the %@: fea) tures offered by I%@: 3ote$)

<or.f/o-

!+*

>nterprise Configuration ,he J@=L definition D:Ls can be created through a graphica/ design too/ offered by J%oss, but that is beyond the scope of this document 5see http277docs.Iboss.com7Ibpm7v87gpd for a detai/ed e4p/anation6 and is a/so beyond the scope of the porta/. 9or nodes that have tas.s associated -ith them, each of the variab/es in the contro//er -i// be converted to a form e/ement that the user must update. 9or nodes that have tas.s associated -ith them, each of the transitions out of the node is represented as a button in the tas.Os form. ,he transitionOs name attribute shou/d a/-ays be in /o-ercase -ith hyphens bet-een -ords and registered in Language'%ro%erties. ,he disp/ay va/ue is used as the but) tonOs name. :any of the action hand/er c/asses found in the com'liferay'*b%m'handler pac.age are Iust p/ace ho/ders that output re/evant te4t to the conso/e. Con) ceivab/y, these c/asses cou/d perform operations such as sending out emai/s, initiating batch processes, updating /egacy systems, etc. ,he -ebsa/e -or.f/o- demonstrates the fo//o-ing I%@: concepts, a// of -hich are discussed in further detai/ in the I%@: user guide 5http277doc) s.Iboss.com7Ibpm7v87userguide62 >vents %eanshe// scripting S-im/anes ,as.s Assigment50ser7@oo/6 Contro//ers Bariab/es ,imers State ,as. 9or. Join =ecision

&ode ,ypes

,ransitions Actions
SSAG S

WARN.NG /

$f you have -arning messages turned on for your server, in your conso/e you !++ <or.f/o-

>nterprise Configuration may see some variant of the fo//o-ing message output severa/ times -hen I%@: is ca//ed2
R8F' Uorg.hibernate.engine.Stateful"ersistence&onte<tV 'arrowing pro<y to class org.jbpm.graph.node./ask'ode - this operation breaks

According to the fo//o-ing post on the J%oss forums 5from Eoen Aers, one of the .ey contributors to the I%@: proIect6, this is not an error and is not of significance. ;e e4p/ains the reason this -arning is thro-n here2 http277---.Iboss.com7J modu/e^bbPop^vie-topicPt^'8A!8. %asica//y, the issue boi/s do-n to ;ibernate doing /azy /oading of the c/ass. After a Huery, a co//ection is returned -hich ho/ds a co//ec) tion of stubs of the c/ass. <hen a particu/ar instance is retrieved, ;ibernate goes and gets it from the database and rep/aces the stub -ith an actua/ instance, thereby brea.ing the ^^ operator.

Administration
?nce you have defined your business processes by successfu//y -riting process definitions for them, the ne4t step is to dep/oy your business processes. ?nce they are dep/oyed, users can manage the /ife of each process instance as contro/ is passed from one ro/e to the ne4t. ,his section is meant for end users -ho -i// actua//y be e4ecut) ing predefined process definitions.

0 PL15.NG W1R2*L1WS
?nce the user /ogs in to the porta/ and adds the -or.f/o- port/et to her page, he or she -i// see something simi/ar to the fo//o-ing2

Illustration G ! Default view of the @or5flow Portlet $f she c/ic.s on the K=efinitionsL tab, he or she -i// see the fo//o-ing2

Illustration G#! @or5flow Definitions ,he Definitions tab disp/ays a// of the -or.f/o-s that have been dep/oyed in the system. ,o dep/oy a -or.f/o-, c/ic. on the Add Definition button. ,he user -i// see the fo//o-ing screen2

<or.f/o-

!+'

>nterprise Configuration

Illustration G2! Adding a @or5flow Definition At this point, the user can paste in the contents of a definition D:L 5see *b%m& web'war+@1"&I6(+definitions for e4amp/es6 and c/ic. the )ave 6ew <ersion button. $f the D:L is inva/id, an error message -i// be disp/ayed. $f the D:L is va/id, it -i// be de) p/oyed, the user -i// be returned to the Definitions tab, and a success message -i// be disp/ayed. %ecause business processes may change over time, every version of the -or.) f/o-s is maintained. ,o edit an e4isting version, c/ic. on the 1dit icon ne4t to the definition name. 0pdate the D:L in the te4t area, and c/ic. the )ave 6ew <ersion but) ton. ,he ne- version number -i// be incremented by A from the previous version. ,o start a ne- instance of a -or.f/o- definition, c/ic. on the Add Instance icon. A ne- in) stance -i// appear on the Instances tab. ,o vie- a// the instances of a particu/ar defini) tion, c/ic. on the <iew Instances icon. 9ina//y, the user can a/so search for a definition by name using the Definition 6ame input bo4.

/ANAG.NG .NSTAN! S
After a definition is dep/oyed and an instance of that definition is started, it is up to the user to manage the /ife cyc/e of the instance. $nstance management is con) tro//ed from the Instances tab. %e/o- is an e4amp/e of -hat the user might see2 ,he Instances tab disp/ays every instance of every version of every -or.f/o- de) p/oyed in the system. ,hey are /isted a/phabetica//y by *efinition 3a+e fo//o-ed by Start *ate in descending order. ,he search form at the top of the screen a//o-s the user to find specific instances to manage. $n particu/ar, the Hide instances that have already ended chec. bo4 a//o-s the user to disp/ay on/y active, running instances. ,he date ranges a/so a//o- the user to search by )tart Date and7or 1nd Date 5378#) =ate ranges are inc/usive of the day. 9or e4amp/e, if the )tart Date range -as set to January !+( <or.f/o-

>nterprise Configuration

Illustration G;! @or5flow Instances !8, !""( a January !8, !""(, then on/y instances that -ere started bet-een January !(, !""(, A!2""am to January !(, !""(, AA2*#pm -ou/d be disp/ayed6. ,he first ro- for each instance describes the state of the instance. Any subseHuent ro-s in the instance define tas.s associated -ith the current state. ?ften times, the current state and cur) rent tas. have the same name. $n the e4amp/e screen shot be/o-, notice that -eb sa/e version A." is current/y in the K@erform shipping and paymentL state, and it has t-o outstanding tas.s associated -ith it a K<ait for shipment to be de/iveredL and K<ait for money.L ,he right)most co/umn in the resu/ts tab/e disp/ays -hat actions the current user can perform on the given instance in its current state. ,he tab/e be/o- sho-s a// of the possib/e actions and -hat each means2

<or.f/o-

!+#

>nterprise Configuration

Action .lank

+#lanation ; possibilities? ,he user doesnOt have the appropriate ro/e7s-im/ane to perform an action on the instance in its current state ,he user doesnOt have permissions to perform an action ,he instance has a/ready ended The user directly has the appropriate role6swimlane to perform B an action or the user belongs to a group which has the appropri" ate role6swimlane. %f the user clicks on the H*anageI icon& she will be taken to a form which must be submitted to complete the task. (ee section ;.; for more details B The instance is currently in a wait state and must be HsignalledI to continue. Typically& signals come from eternal processes Ae.g.& the arrival of a package& the successful update of a legacy sys" tem& etc.B and are not manually entered by a user. 4owever& in the case that user intervention is reJuired& the H(ignalI icon is available.

*anage icon A

(ignal icon A

'aiting on sibling This only occurs when the process has forked into multiple sub" tokens to complete processes. %n order for the main process to continue& all of the subprocesses must complete. +s each of the subprocesses com" pletes& they will go into this state. <nce all subprocesses com" plete& the main process will continue like normal.

/ANAG.NG TAS2S
,as. management is contro//ed from the K,as.sL tab. %e/o- is an e4amp/e of -hat the user might see2

Illustration G?! @or5flow 4as5s ,he 4as5s tab disp/ays every tas. that has either been assigned direct/y to the !'" <or.f/o-

>nterprise Configuration user or to the group7ro/e poo/ that the user be/ongs to. ,hey are /isted by Create *ate in ascending order, and the tas.s assigned direct/y to the user are /isted before the tas.s assigned to the userOs poo/ 5if the A$$igned 8o co/umn is b/an., that means the tas. is open to the poo/6. ,he search form at the top of the screen a//o-s the user to find specific tas.s to manage. $n particu/ar, the Hide tas5s that have already ended chec. bo4 a//o-s the user to disp/ay on/y active tas.s. ,he date ranges a/so a//o- the user to search by tas. Create Date, )tart Date, and7or 1nd Date. ,he user can a/so choose to on/y disp/ay tas.s assigned direct/y to her, tas.s assigned to her poo/, or a// tas.s assigned to either by using the Assigned 4o drop)do-n. ,o start a tas., a// a user needs to do is c/ic. on it. ,he ne4t screen that is sho-n -i// be different depending on the type of tas. that has been defined. 9or e4amp/e, if a user -as using the samp/e re7uest&holiday definition -hich has been provided, a form simi/ar to the fo//o-ing -i// be disp/ayed2

Illustration GB! @or5flow (orm ,hese tas. forms are generated from the contro/ variab/es associated -ith the tas. and defined in the definition D:L. =epending on the data type, the correspond) ing e/ement is created in the form. ReHuired fie/ds are denoted by a red asteris.. $f the user submits the form -ith inva/id data, she -i// be returned to the form -ith error messages ne4t to each of the inva/id fie/ds. $f a// data is va/id and the user submits the form, she -i// be returned to the 4as5s tab -ith a success message disp/ayed.

*uture nhancements L1GG.NG


Current/y, the -or.f/o- port/et has no notion of /ogging other than the abi/ity to revie- a// of the tas.s that a user has assigned to them or has comp/eted. ;o-ever, I%@: provides rather robust /ogging functiona/ity so administrators7users can monit) or every action that has ever been ta.en in a particu/ar -or.f/o-. ,he on/y reason /ogging functiona/ity has not been bui/t out in the current re) /ease is because the Liferay deve/opment team is not sure -hat the most effective /og) ging metrics -ou/d be to the end user. $f you or your organization has /ogging re) Huirements, p/ease submit them to the Liferay 9orums, and -e -i// revie- those re) Huirements for possib/e inc/usion in future versions of the <or.f/o- port/et.

!-ST1/.DA(L *R1NT,

N0

,hough the -or.f/o- port/etOs strength is that it can provide a forms)based data

<or.f/o-

!'A

>nterprise Configuration entry app/ication virtua//y on)the)f/y, it is obvious that there is not much contro/ over -hat the forms /oo. /i.e -hen they are rendered by the port/et. ,o address this con) cern, the Liferay deve/opment team p/ans to create sty/e sheets and temp/ates that can be app/ied to the vani//a forms. ,he functiona/ity -ou/d be very simi/ar to hoDSL sty/e sheets are current/y app/ied to Journa/ Artic/es in the Liferay Journa/ Con) tent :anagement System. ,his enhancement -ou/d give organizations f/e4ibi/ity in /ayout and 0$ design of their forms.

*.L -PL1A0 0ATA T5P


,here have a/ready been severa/ reHuests to add a fi/e data type to provide a means for users to up/oad fi/es that are associated -ith -or.f/o- tas.s. ,his -i// def) inite/y be a future enhancement.

*reGuentl& As'ed Cuestions 31W


01 51- WR.T A N W PR1! SS 0 *.N.T.1NH

,he best -ay to /earn ho- to -rite a ne- process definition is to use one of the samp/e definition D:Ls 5found in *b%m&web'war+@1"&I6(+definitions+6 as a starting point. $n particu/ar, websale/definition'xml demonstrates most of the %@: features offered by I%@:. 9or an e4haustive e4p/anation of J@=L, visit J%ossO documentation at http277docs.Iboss.com7Ibpm7v87userguide7Ipd/.htm/. ,here is a/so a graphica/ J@=L designer avai/ab/e at http277/abs.Iboss.com7IbossIbpm7do-n/oads.

J(P/H

W35 AR

T3 R

I0-PL.!AT *.L J

4! PT.1NS W3 N

!3ANG 0ATA(AS S *1R

Since -e are using Service:i4 as the service bro.er for our -or.f/o- imp/e) mentation 5by defau/t, -e are using I%@:6, -e cannot re/y on the -or.f/o- engine to maintain versions of our process definitions. ,herefore, -e maintain the process definition D:Ls as system documents in our document /ibrary. ,he D:Ls are named based on their definition $=s, and the definition $=s are maintained in the I%@: data) base. ,herefore, if you -ere to s-itch databases to a ne- instance, the definition $=s -ou/d a/so be reset, and -hen the system tries to store the process definition D:L, it -i// find a dup/icate D:L a/ready e4ists. ,he on/y -ay to ensure that this e4ception does not occur is by c/earing out the TUser HomeR+liferay+*ac5rabbit fo/der before s-itching databases. ;o-ever, be -arned that this -i// de/ete ALL the fi/es that are stored in your =ocument Library. $t is recommended that once you decide on a I%@: database that suits your needs, you shou/d on/y use that database.

0e#lo&in) A !ustomized Li%era&


As described in the Installation chapter of this boo., Liferay a//o-s for comp/ete customization of the porta/ through the >4tension >nvironment. =ep/oying the e4ten) sion environment to a server reHuires one of t-o scenarios2 ,he Liferay deve/opment too/s 5J=E, Ant, etc.6 are insta//ed on the server, the Liferay @orta/ source code is avai/ab/e on the server, and the e4tension =ep/oying A Customized Liferay

!'!

>nterprise Configuration environment is chec.ed out to a directory on the server. ?n a c/ient machine -hich contains the Liferay deve/opment too/s, a drive can be mapped or a fo/der mounted -hich points to the insta//ation direct) ory on the server.

?nce one of these t-o reHuirements have been met, dep/oying to the server be) comes as easy as dep/oying /oca//y to the deve/oper's machine.

0e#lo&in) 0irectl& on the Server


=ep/oying the e4tension environment direct/y on the server is the recommended method. ,o do this, you -i// have to create t-o ne- configuration fi/es -hich define the settings for the dep/oyment. $n the e4tension environment, create a fi/e ca//ed a%& %'server'TusernameR%ro%erties, -here TusernameR is the user name of the account under -hich the server e4ecutab/e runs. $f, for e4amp/e, you have a G/assfish server running under the user name of glassfish, your fi/e -ou/d be ca//ed a%%'server'glassfish'%ro%er& ties. ,his fi/e -i// override the defau/t va/ues -hich are found in a%%'server'%ro%erties. 1ou -i// need to configure t-o properties in this fi/e2 the server type and the server path. ,he server type shou/d be one of the fo//o-ing2
app.server.type geronimo-tomcat app.server.type glassfish app.server.type jboss-tomcat app.server.type jetty app.server.type jonas-jetty app.server.type jonas-tomcat app.server.type resin app.server.type tomcat

,he path property is simi/ar to the server type. $t shou/d /oo. /i.e this2
app.server.9server name:.dir

Rep/ace Zserver nameV -ith the server type above. 9or e4amp/e, if you are using G/assfish, your property -ou/d be2
app.server.glassfish.dir /home/glassfish/glassfish-v5

,he va/ue of the property shou/d be the fu//y Hua/ified path to the server direct) ory. &e4t, create another fi/e simi/ar to the first one ca//ed release'TusernameR'%ro%er& ties. Again, substitute TusernameR -ith the user name the server runs under and under -hose credentia/s you -i// be doing the dep/oyment. ,his fi/e -i// override the defau/t va/ues found in release'%ro%erties' ,his fi/e reHuires t-o properties2
lp.source.dir lp.e<t.dir

Set the va/ue for the l%'source'dir property to be eHua/ to the fu//y Hua/ified direct) ory name for -here you have insta//ed the Liferay @orta/ source. Set the va/ue for the =ep/oying A Customized Liferay !'8

>nterprise Configuration l%'ext'dir property to be eHua/ to the fu//y Hua/ified directory name for -here you have insta//ed the >4tension >nvironment you have chec.ed out from your source code re) pository. 9or e4amp/e2
lp.source.dir /home/glassfish/lportal/portal lp.e<t.dir /home/glassfish/lportal/e<t

?nce you have set up these t-o properties fi/es, run the fo//o-ing Ant tas.2
ant deploy

1our customized Liferay -i// be automatica//y compi/ed and dep/oyed to your ap) p/ication server.

0e#lo&in) %rom a !lient /achine


$f you -i// be dep/oying a customized Liferay from a c/ient machine, you -i// need to map a drive 5on <indo-s6 or a fo/der on your fi/e system 5:ac or Linu46 to the server. ?nce you have done this, fo//o- the same procedure out/ined above, -ith the e4ception that the TusernameR shou/d be the user name of the user /ogged in to the c/ient, not the user name on the server. 1ou -i// not need to change the release'Tuser& nameR'%ro%erties fi/eU on/y the a%%'server'TusernameR'%ro%erties fi/e -i// need to be modi) fied. $f you are using a deve/oper's machine to do the dep/oyment, these configuration fi/es -i// a/ready e4ist. :odify the a%%'server'TusernameR'%ro%erties fi/e to match the ap) p/ication server type and /ocation of the directory in -hich it is insta//ed from your mapped drive or fo/der. ,hen run the above Ant tas. to dep/oy the e4tension environ) ment. &ote that this second method is not a best practice, as it enab/es changes to be made /oca//y on a deve/oper's machine -hich can then be dep/oyed direct/y to a serv) er -ithout source code management being done first. $t is better to have deve/opers chec. in a// their code, version that code, and then pu// that version from your source code management soft-are to dep/oy it to a server.

Per%ormance Tunin)
?nce you have your porta/ up and running, you may find a need to tune it for performance, especia//y if your site -inds up generating more traffic than you'd anti) cipated. ,here are some definite steps you can ta.e -ith regard to improving Liferay's performance.

/emor&
:emory is one of the first things to /oo. at -hen you -ant to optimize perform) ance. $f you have any dis. s-apping, that -i// have a serious impact on performance. :a.e sure that your server has an optima/ amount of memory and that your JB: is tuned to use it. ,here are three basic JB: command s-itches that contro/ the amount of memory in the Java heap.

!'C

@erformance ,uning

>nterprise Configuration
-;ms -;m< -;;*$a<"ermSi>e

,hese three settings contro/ the amount of memory avai/ab/e to the JB: initia//y, the ma4imum amount of memory into -hich the JB: can gro-, and the separate area of the heap ca//ed @ermanent Generation space. ,he first t-o settings shou/d be set to the same va/ue. ,his prevents the JB: from having to rea//ocate memory if the app/ication needs more. Setting them to the same va/ue causes the JB: to be created up front -ith the ma4imum amount of memory you -ant to give it.
-;ms345=m -;m<345=m -;;*$a<"ermSi>e 351m

,his is perfect/y reasonab/e for a moderate/y sized machine or a deve/oper ma) chine. ,hese settings give the JB: A"!C:% for its regu/ar heap size and have a @erm) Gen space of A!(:%. $f, ho-ever, you have Liferay on a server -ith CG% of RA: and you are having performance prob/ems, the first thing you might -ant to /oo. at is in) creasing the memory avai/ab/e to the JB:. 1ou -i// be ab/e to te// if memory is a prob) /em by running a profi/er 5such as Jprobe, 1ourEit, or the &et%eans profi/er6 on the server. $f you see Garbage Co//ection 5GC6 running freHuent/y, you -i// definite/y -ant to increase the amount of memory avai/ab/e to the JB:. &ote that there is a /a- of diminishing returns on memory, especia//y -ith +C bit systems. ,hese systems a//o- you to create very /arge JB:s, but the /arger the JB:, the more time it ta.es for garbage co//ection to ta.e p/ace. 9or this reason, you prob) ab/y -on't -ant to create JB:s of more than ! G% in size. ,o ta.e advantage of higher amounts of memory on a sing/e system, run mu/tip/e JB:s of Liferay instead. $ssues -ith @ermGen space can a/so affect performance. @ermGen space contains /ong)/ived c/asses, anonymous c/asses and interned Strings. ;ibernate, in particu/ar3 -hich Liferay uses e4tensive/y3has been .no-n to ma.e use of @ermGen space. $f you increase the amount of memory avai/ab/e to the JB:, you may -ant to increase the amount of @ermGen space according/y.

Gar"a)e !ollection
As the system runs, various Java obIects are created. Some of these obIects are /ong)/ived, and some are not. ,he ones that are not become de&referenced, -hich means that the JB: no /onger has a /in. to them because they have ceased to be use) fu/. ,hese may be variab/es that -ere used for methods -hich have a/ready returned their va/ues, obIects retrieved from the database for a user that is no /onger /ogged on, or a host of other things. ,hese obIects sit in memory and fi// up the heap space unti/ the JB: decides it's time to c/ean them up. &orma//y, -hen garbage co//ection 5GC6 runs, it stops a// processing in the JB: -hi/e it goes through the heap /oo.ing for dead obIects. ?nce it finds them, it frees up the memory they -ere ta.ing up, and then processing can continue. $f this happens in a server environment, it can s/o- do-n the processing of reHuests, as a// processing comes to a ha/t -hi/e GC is happening. ,here are some JB: s-itches that you can enab/e -hich can reduce the amount

@erformance ,uning

!'*

>nterprise Configuration of time processing is ha/ted -hi/e garbage co//ecting happens. ,hese can improve the performance of your Liferay insta//ation if app/ied proper/y. As a/-ays, you -i// need to use a profi/er to monitor garbage co//ection during a /oad test to tune the numbers proper/y for your server hard-are, operating system, and app/ication server.

Illustration GF! 3ava memory ,he Java heap is divided into sections for the young generation, the o/d genera) tion, and the permanent generation. ,he young generation is further divided into three sections2 >den, -hich is -here ne- obIects are created, and t-o Ksurvivor spaces,L -hich -e can ca// the (rom and 4o spaces. Garbage co//ection occurs in stages. Genera//y, it is more freHuent/y done in the young generation, /ess freHuent/y done in the o/d generation, and even /ess freHuent/y done in the permanent generation, -here /ong)/ived obIects reside. <hen garbage co//ection runs in the young generation, >den is s-ept for obIects -hich are no /onger referenced. ,hose that are sti// around are moved to the K,oL survivor space, and the K9romL space is then s-ept. Any other obIects in that space -hich sti// have refer) ences to them are moved to the K,oL space, and the K9romL space is then c/eared out a/together. After this, the K9romL and the K,oL spaces s-ap ro/es, and processing is freed up again unti/ the ne4t time the JB: determines that garbage co//ection needs to run. After a predetermined number of KgenerationsL of garbage co//ection, surviving obIects may be moved to the o/d generation. Simi/ar/y, after a predetermined number of KgenerationsL of garbage co//ection in the o/d generation, surviving obIects may be moved to the permanent generation. %y defau/t, the J=E uses a seria/ garbage co//ector to achieve this. ,his -or.s very -e// for a short)/ived des.top Java app/ication, but is not necessari/y the best per) former for a server)based app/ication /i.e Liferay. 9or this reason, you may -ish to s-itch to the Concurrent :ar.)S-eep 5C:S6 co//ector. Rather than ha/ting app/ication processing a/together, this garbage co//ector ma.es one short pause in app/ication e4ecution to mar. obIects direct/y reachab/e from the app/ication code. ,hen it a//o-s the app/ication to run -hi/e it mar.s a// ob) Iects -hich are reachab/e from the set it mar.ed. 9ina//y, it adds another phase ca//ed

!'+

@erformance ,uning

>nterprise Configuration the remar5 phase -hich fina/izes mar.ing by revisiting any obIects modified -hi/e the app/ication -as running. $t then s-eeps through and garbage co//ects. ,his has the ef) fect of great/y reducing the amount of time that e4ecution needs to be ha/ted in order to c/ean out dead obIects. Just about every aspect of the -ay memory management -or.s in Java can be tuned. $n your profi/ing, you may -ant to e4periment -ith some of the fo//o-ing set) tings to see if any of them can increase your performance. 3e1Si9eE %a(3e1Si9e) ,he initia/ size and the ma4imum size of the &e- or 1oung Generation. F6$e&ar3e1>C) Causes garbage co//ection to happen in para//e/, using mu/tip/e C@0s. ,his decreases garbage co//ection overhead and increases app/ication through) put. F6$eConc%arkS1eep>C) 0se the Concurrent :ar.)S-eep Garbage Co//ector. ,his uses shorter garbage co//ection pauses, and is good for app/ications that have a re/ative/y /arge set of /ong)/ived data, and that run on machines -ith t-o or more processors, such as -eb servers. FC%S&arallel:e+ark#nabled) 9or the C:S GC, enab/es the garbage co//ector to use mu/tip/e threads during the C:S remar. phase. ,his decreases the pauses during this phase. Ser!i!or:atio) Contro/s the size of the t-o survivor spaces. $t's a ratio bet-een the survivor space size and >den. ,he defau/t is !*. ,here's not much bang for the buc. here, but it may need to be adIusted. &arallel>C8hread$) ,he number of threads to use for para//e/ garbage co//ec) tion. Shou/d be eHua/ to the number of C@0 cores in your server. this2 A samp/e configuration using the above parameters might /oo. something /i.e

E8K8LN"/S D@E8K8LN"/S -;;*'ewSi>e T44m -;;*$a<'ewSi>e T44m -;ms54=1m -;m<54=1m -;;*$a<"ermSi>e 351m -;;*\,se"ar'ewO& -;;*\,se&onc$arkSweepO& -;;* \&$S"arallelFemark.nabled -;;*SurvivorFatio 54 -;;*"arallelO&/hreads 1D

Pro#erties *ile !han)es


,here are a/so some changes you can ma.e to your %ortal&ext'%ro%erties fi/e once you are in a production environment. Set the fo//o-ing to fa/se to disab/e chec.ing the /ast modified date on server side CSS and JavaScript.
last.modified.check false

Set this property to true to /oad the theme's merged CSS fi/es for faster /oading for production. %y defau/t it is set to fa/se for easier debugging for deve/opment. 1ou can a/so disab/e fast /oading by setting the 0RL parameter css/fast/load to J.
theme.css.fast.load true

Set this property to true to /oad the combined JavaScript fi/es from the property

@erformance ,uning

!''

>nterprise Configuration *avascri%t'files into one compacted fi/e for faster /oading for production. %y defau/t it is set to fa/se for easier debugging for deve/opment. 1ou can a/so disab/e fast /oading by setting the 0RL parameter *s/fast/load to J.
javascript.fast.load true

Servlet *ilters
Liferay comes by defau/t -ith A' serv/et fi/ters enab/ed and running. $t is /i.e/y that for your insta//ation, you don't need them a//. ,o disab/e a serv/et fi/ter, simp/y comment it out of your web'xml fi/e. $f there is a feature supported by a serv/et fi/ter that you .no- you are not using, you can comment it out as -e// to achieve some performance gains. 9or e4amp/e, if you are not using CAS for sing/e sign)on, comment out the CAS 9i/ter. $f you are not using &,L: for sing/e sign)ons, comment out the &t/m 9i/ter. $f you are not using the Birtua/ ;osting for Communities feature, comment out the Birtua/ ;ost 9i/ter. ,he fe-er serv/et fi/ters you are running, the /ess processing po-er is needed for each re) Huest.

Portlets
Liferay comes pre)bund/ed -ith many port/ets -hich contain a /ot of functiona/) ity, but not every -eb site that is running on Liferay needs to use them a//. $n %ort& let'xml and liferay&%ortlet'xml, comment out the ones you are not using. <hi/e having a /oan ca/cu/ator, ana/og c/oc., or game of hangman avai/ab/e for your users to add to pages is nice, those port/ets may be ta.ing up resources that are needed by custom port/ets you have -ritten for your site. $f you are having performance prob/ems, com) menting out some of the unused port/ets may give you the performance boost you need.

Read,Writer 0ata"ase !on%i)uration


Liferay *.!.4 a//o-s you to use t-o different data sources for reading and -riting. ,his enab/es you to sp/it your database infrastructure into t-o sets2 one that is optim) ized for reading and one that is optimized for -riting. Since a// maIor databases sup) port rep/ication in one form or another, you can then use your database vendor's rep) /ication mechanism to .eep the databases in sync in a much faster manner than if you had a sing/e data source -hich hand/ed everything. >nab/ing a read)-riter database is simp/e. $n your %ortal&ext'%ro%erties fi/e, config) ure t-o different data sources for Liferay to use, one for reading, and one for -riting2
jdbc.read.driver&lass'ame com.mys(l.jdbc.)river jdbc.read.url jdbc*mys(l*//dbread.com/lportal+use,nicode true- \ character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.read.username jdbc.read.password jdbc.write.driver&lass'ame com.mys(l.jdbc.)river

!'(

@erformance ,uning

>nterprise Configuration
jdbc.write.url jdbc*mys(l*//dbwrite.com/lportal+use,nicode true- \ character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.write.username jdbc.write.password

?f course, specify the user name and pass-ord to your database in the above configuration. After this, enab/e the read)-riter database configuration by uncommenting the Spring configuration fi/e -hich enab/es it in your s%ring'configs property 5/ine to un) comment is in bo/d2
spring.configs \ $./8-I'0/base-spring.<ml,\ \ $./8-I'0/hibernate-spring.<ml,\ $./8-I'0/infrastructure-spring.<ml,\ $./8-I'0/management-spring.<ml,\ \ $./8-I'0/util-spring.<ml,\ \ $./8-I'0/editor-spring.<ml,\ $./8-I'0/jcr-spring.<ml,\ $./8-I'0/messaging-spring.<ml,\ $./8-I'0/scheduler-spring.<ml,\ $./8-I'0/search-spring.<ml,\ \ $./8-I'0/counter-spring.<ml,\ $./8-I'0/document-library-spring.<ml,\ $./8-I'0/lock-spring.<ml,\ $./8-I'0/mail-spring.<ml,\ $./8-I'0/portal-spring.<ml,\ $./8-I'0/portlet-container-spring.<ml,\ $./8-I'0/wsrp-spring.<ml,\ \ $./8-I'0/mirage-spring.<ml,\ \ META-INF dynamic-data-source-spring.!ml"# #$./8-I'0/shard-data-source-spring.<ml,\ \ $./8-I'0/e<t-spring.<ml

,he ne4t time you restart Liferay, it -i// no- use the t-o data sources you have defined. %e sure to ma.e sure that you have correct/y set up your t-o databases for rep/ication before starting Liferay.

0ata"ase Shardin)
Liferay starting -ith version *.!.8 supports database sharding for different porta/ instances. Sharding is a term used to describe an e4treme/y high sca/abi/ity configura) tion for systems -ith massive amounts of users. $n diagrams, a database is norma//y @erformance ,uning !'#

>nterprise Configuration pictured as a cy/inder. $nstead, picture it as a g/ass bott/e fu// of data. &o- ta.e that bott/e and smash it onto a concrete side-a/.. ,here -i// be shards of g/ass every) -here. $f that bott/e -ere a database, each shard no- is a database, -ith a subset of the data in each shard. ,his a//o-s you to sp/it up your database by various types of data that might be in it. 9or e4amp/e, some imp/ementations of sharding a database sp/it up the users2 those -ith /ast names beginning -ith A to = go in one databaseU > to $ go in anotherU etc. <hen users /og in, they are directed to the instance of the app/ication that is con) nected to the database that corresponds to their /ast names. $n this manner, pro) cessing is sp/it up even/y, and the amount of data the app/ication needs to sort through is reduced. %y defau/t, Liferay a//o-s you to support sharding through different porta/ in) stances, using the round robin shard selector. ,his is a c/ass -hich serves as the defau/t a/gorithm for sharding in Liferay. 0sing this a/gorithm, Liferay -i// se/ect from sever) a/ different porta/ instances and even/y distribute the data across them. ?f course, if you -ish to have your deve/opers imp/ement your o-n sharding a/) gorithm, you can do that. 1ou can se/ect -hich a/gorithm is active via the %ortal&ext'& %ro%erties fi/e2
shard.selector com.liferay.portal.dao.shard.FoundFobinShardSelector #shard.selector com.liferay.portal.dao.shard.$anualShardSelector #shard.selector Uyour implementation hereV

>nab/ing sharding is easy. 1ou -i// need to ma.e sure you are using Liferay's data source imp/ementation instead of your app/ication server's. Set your various database shards in your %ortal&ext'%ro%erties fi/e this -ay2
jdbc.default.driver&lass'ame com.mys(l.jdbc.)river jdbc.default.url jdbc*mys(l*//localhost/lportal+use,nicode true-character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.default.username jdbc.default.password jdbc.one.driver&lass'ame com.mys(l.jdbc.)river jdbc.one.url jdbc*mys(l*//localhost/lportal3+use,nicode true-character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.one.username jdbc.one.password jdbc.two.driver&lass'ame com.mys(l.jdbc.)river jdbc.two.url jdbc*mys(l*//localhost/lportal5+use,nicode true-character.ncoding ,/0-1-use0ast)ate"arsing false jdbc.two.username jdbc.two.password shard.available.names default,one,two

?nce you do this, you can set up your =&S so that severa/ domain names point to your Liferay insta//ation 5e.g., abcA.com, abc!.com, abc8.com6. &e4t, go to the Contro/ @ane/ and c/ic. Portal Instances in the Server category. Create t-o to three instances bound to the =&S names you have configured. $f you are using the RoundRobinShardSe/ector c/ass, Liferay -i// automatica//y enter data into each instance one by one, automatica//y. $f you are using the :anu) !(" @erformance ,uning

>nterprise Configuration a/ShardSe/ector c/ass, you -i// have to specify a shard for each instance using the 0$. ,he /ast thing you -i// need to do is modify the s%ring'configs section of your %ortal&ext'%ro%erties fi/e to enab/e the sharding configuration, -hich by defau/t is com) mented out. ,o do this, your spring.configs shou/d /oo. /i.e this 5modified section is in bo/d62
spring.configs \ $./8-I'0/base-spring.<ml,\ \ $./8-I'0/hibernate-spring.<ml,\ $./8-I'0/infrastructure-spring.<ml,\ $./8-I'0/management-spring.<ml,\ \ $./8-I'0/util-spring.<ml,\ \ $./8-I'0/editor-spring.<ml,\ $./8-I'0/jcr-spring.<ml,\ $./8-I'0/messaging-spring.<ml,\ $./8-I'0/scheduler-spring.<ml,\ $./8-I'0/search-spring.<ml,\ \ $./8-I'0/counter-spring.<ml,\ $./8-I'0/document-library-spring.<ml,\ $./8-I'0/lock-spring.<ml,\ $./8-I'0/mail-spring.<ml,\ $./8-I'0/portal-spring.<ml,\ $./8-I'0/portlet-container-spring.<ml,\ $./8-I'0/wsrp-spring.<ml,\ \ $./8-I'0/mirage-spring.<ml,\ \ #$./8-I'0/dynamic-data-source-spring.<ml,\ $$$$$$$$META-INF shard-data-source-spring.!ml"# \

,hat's a// there is to it. 1our system is no- set up for sharding.

@erformance ,uning

!(A

!. "AINTAINING A LIFERAY PORTAL

:aintaining a running imp/ementation of Liferay @orta/ is not much different from maintaining the app/ication server environment upon -hich it is running. ,here are, ho-ever, severa/ factors -hich administrators shou/d be a-are of -hen they are responsib/e for a running instance of Liferay. ,his chapter -i// cover these issues, out/ining for system administrators some specifics about .eeping a running Liferay instance stab/e and secure. ,his chapter -i// cover the fo//o-ing topics2 Liferay :onitoring using Goog/e Ana/ytics %ac.ing 0p a Liferay $nsta//ation Changing Logging Leve/s 0pgrading Liferay

,he discussion on bac. up -i// cover -hat parts of Liferay shou/d be bac.ed up. <e -i// not cover specific bac.up soft-are or proceduresU genera//y, most organiza) tions have standards for doing bac.ups of their systems, and Liferay as a Java >> ap) p/ication fits -e// into these standards.

Li%era& /onitorin) -sin) Goo)le Anal&tics


Liferay inc/udes bui/t)in support for Goog/e Ana/ytics, a//o-ing administrators to ma.e use of Goog/e's too/ set for ana/yzing site traffic data. <hen you sign up for Goog/e Ana/ytics, a snippet of code is provided -hich needs to be added to your -eb pages in order to a//o- Goog/e's system to register the page hit. $t can be a tedious process to add this code to every page on a site, especia//y if it is a /arge site and there is a /ot of user)generated content. ,his prob/em can be so/ved in Liferay by putting Goog/e's code into a custom theme -ritten especia//y for the site on -hich the porta/ is running. =oing this,

:aintaining A Liferay @orta/ ho-ever, reHuires that a theme deve/oper ma.e specific changes to the theme, and it prevents users from using the many free/y avai/ab/e themes that are avai/ab/e for Liferay Kout of the bo4.L %ecause of this, support for Goog/e Ana/ytics has been bui/t into Liferay, and can be turned on through a simp/e user interface. ,his a//o-s Liferay Administrators to ma.e use of Goog/e Ana/ytics on a community by community basis and turn it on and off -hen needed. ,o enab/e Goog/e Ana/ytics support, go to the :anage @ages screen for the com) munity for -hich you -ant to enab/e support. 1ou can do this through the Contro/ @ane/ by going to either the 0rganiLations or Communities /in. in the Portal section, and then c/ic.ing Actions Manage Pages for the community or organization you -ant to ana/yze. C/ic. the )ettings tab.

Illustration GG! )etting U% .oogle Analytics C/ic. the %onitoring ,ab. @ut your Goog/e Ana/ytics $= 5-hich shou/d have been provided to you -hen you signed up for the service6 in the fie/d and c/ic. )ave. A// of the pages in the community you se/ected -i// no- have the Goog/e Ana/ytics code in them and -i// be trac.ed.

(ac'in) -# A Li%era& .nstallation


?nce you have an insta//ation of Liferay @orta/ running, you -i// -ant to have proper bac.up procedures in p/ace in case of a catastrophic fai/ure of some .ind. Liferay is not very different from any other app/ication that may be running in your app/ication server, but there are some specific components that need to be bac.ed up in addition to your regu/ar bac.up procedures for your app/ication server.

Source !ode
$f you have e4tended Liferay or have -ritten port/et or theme p/ugins, they shou/d be stored in a source code repository such as Subversion, CBS, or Git. ,his re) pository shou/d be bac.ed up on a regu/ar basis to preserve your ongoing -or.. $f you are e4tending Liferay -ith the >4tension >nvironment, you -i// -ant to ma.e sure that you a/so store the version of the Liferay source on -hich your e4ten) sion environment is based. ,his a//o-s your deve/opers convenient access to a// of the too/s they need to bui/d your e4tension and dep/oy it to a server. !(C %ac.ing 0p A Liferay $nsta//ation

:aintaining A Liferay @orta/

Li%era&'s *ile S&stem


Liferay's configuration fi/e, %ortal&ext'%ro%erties, gets stored in the Liferay Home fo/der, -hich is genera//y one fo/der up from -here your app/ication server is in) sta//ed 5see Chapter A for specific info for your app/ication server6. At a minimum, this fi/e shou/d be bac.ed up, but it is genera//y best to bac. up your -ho/e app/ication server. $f you have fo//o-ed the procedure in the previous chapter to modify your ehcache configuration, you -i// have cache configuration fi/es in the dep/oy /ocation of Liferay. 1ou -i// need to bac. up this /ocation. Liferay a/so stores configuration fi/es, search inde4es, cache information, and the defau/t Jac.rabbit document repository in a fo/der ca//ed data in Liferay ;ome. 1ou shou/d genera//y bac. up a// of the contents of your Liferay ;ome fo/der. $f you have modified the /ocation -here the =ocument Library stores fi/es, you shou/d a/so bac. up this /ocation.

0ata"ase
Liferay's database is the centra/ repository for a// of the @orta/'s information and is the most important component -hich needs to be bac.ed up. 1ou can do this by either bac.ing up the database /ive 5if your database a//o-s this6 or by e4porting the database and then bac.ing up the e4ported fi/e. 9or e4amp/e, :ySFL ships -ith a mys7ldum% uti/ity -hich a//o-s you to e4port the entire database and data into a /arge SFL fi/e. ,his fi/e can then be bac.ed up. $n case of a database fai/ure, it can be used to recreate the state of the database at the time the dump -as created. $f you are using Liferay's =ocument Library -ith the Jac.rabbit JSR)A'" reposit) ory to store documents in a database, the Jac.rabbit database shou/d be bac.ed up a/so.

Li%era&'s Lo))in) S&stem


Liferay uses LogCI e4tensive/y to imp/ement /ogging for near/y every c/ass in the porta/. $f you need to debug something specific -hi/e a system is running, you can use the Contro/ @ane/ to set /ogging /eve/s by c/ass dynamica//y. ,o vie- the /og /eve/s, go to the Contro/ @ane/, c/ic. )erver Administration in the Server section, and then c/ic. the Log Levels tab. 1ou -i// then see a paginated /ist of /ogging categories. ,hese categories corres) pond to Liferay c/asses that have /og messages in them. %y defau/t, a// categories are set to disp/ay messages on/y if there is an error that occurs in the c/ass. ,his is -hy you see >RR?R disp/ayed in a// of the drop do-n /ist bo4es on the right side of the port/et. >ach category is fi/tered by its p/ace in the c/ass hierarchy. 9or e4amp/e, if you -anted to see /ogging for a specific c/ass that is registered in Liferay, you -ou/d bro-se to that specific c/ass and change its /og /eve/ to something that is more de) scriptive, such as =>%0G. ?nce you c/ic. the )ave button at the bottom of the /ist, you

Liferay's Logging System

!(*

:aintaining A Liferay @orta/ -i// start seeing =>%0G messages from that c/ass in your app/ication server's /og fi/e. $f you are not sure -hich c/ass you -ant to see /og messages for, you can find a p/ace higher up in the hierarchy and se/ect the pac.age name instead of an individua/ c/ass name. $f you do this, messages for every c/ass /o-er in the hierarchy -i// be dis) p/ayed in your app/ication server's /og fi/e.

Illustration GK! Changing Logging Levels %e carefu/ -hen you do this. $f you set the /og /eve/ to =>%0G some-here near the top of the hierarchy 5such as com'liferay, for e4amp/e6, you may -ind up -ith a /ot of messages in your /og fi/e. ,his cou/d ma.e it difficu/t to find the one you -ere /oo.) ing for, and causes the server to do more -or. -riting messages to its /og fi/e. $f you are -or.ing in the e4tension environment or have created a p/ugin and -ant to set the /og /eve/ for one of your o-n c/asses, you can register that c/ass 5so /ong as it uses LogCJ to do its /ogging6 -ith Liferay so that you can contro/ the /og /eve/s more easi/y. 1ou -i// first need to imp/ement LogCJ /ogging in your c/ass, -ith a statement such as the fo//o-ing 5ta.en from Liferay's JCR;oo. c/ass62
private static !og Llog !og0actory.get!ogAE&FMook.classB7

1ou -ou/d then use this /log variab/e to create /og messages in your code for the various /ogging /eve/s2
Llog.errorADFeinde<ing D \ node.get'ameAB, e3B7

,o enab/e your /ogging messages to appear in your server's /og fi/e via the Con) tro/ @ane/, c/ic. the Add Category tab on the same Log Levels page. 1ou -i// see that you can add a /ogging category. Simp/y put in the fu//y Hua/ified name of your c/ass or of the pac.age that contains the c/asses -hose /og messages you -ant to vie-, choose a /og /eve/, and then c/ic. the )ave button. 1ou -i// no- start to see /og messages from your o-n c/ass or c/asses in the server's /og fi/e. !(+ Liferay's Logging System

:aintaining A Liferay @orta/

Illustration KJ! Adding a Logging Category

-#)radin) Li%era&
Liferay upgrades are fair/y straightfor-ard. A consistent set of steps is a// you need to fo//o- to upgrade a standard Liferay insta//ation. ,hings do get more comp/ic) ated if your organization has used the e4tension environment to customize Liferay, as it is possib/e that A@$ changes in the ne- version -i// brea. your e4isting code. ,his, ho-ever, is usua//y fair/y straightfor-ard for your deve/opers to fi4. @ort/et p/ugins are genera//y bac.-ards compatib/e, as they are -ritten to the Java standard. ,his in) c/udes @ort/et A." 5JSR)A+(6 port/ets, as the @ort/et !." 5JSR)!(+6 standard has a/so been designed to be bac.-ards)compatib/e. ,heme p/ugins may reHuire some modi) fications in order to ta.e advantage of ne- features. :uch effort has been made to ma.e upgrades as pain/ess as possib/eU ho-ever, this is not a guarantee that everything -i// -or. -ithout modification. >4tension environment changes are the most comp/icating factor in an upgrade, so it is important to test as much as possib/e. As a genera/ ru/e, you can upgrade from one maIor re/ease to the ne4t maIor re) /ease. 9or e4amp/e, you can upgrade direct/y from Liferay C.8.4 to C.C.4, but not from C.8.4 to *.".4. $f you need to upgrade over severa/ maIor re/eases, you -i// need to run the upgrade procedure for each maIor re/ease unti/ you reach the re/ease you -ant. ,his doesn't mean you need to run the procedure for every point re/ease 5i.e., C.8.* to C.8.+ to C.C." to C.C.A, etc.6U you on/y need to run the procedure for the maIor re/eases. A good practice is to use the /atest version of each maIor re/ease to upgrade your sys) tem. So if you -anted to upgrade from Liferay C.8.* to Liferay *.!.C, you -ou/d first run the upgrade procedure for C.C.!, then *.".A, then *.A.!, and then *.!.C.

Li%era& -#)rade Procedure


Liferay C.8." and higher can auto)detect -hether the database reHuires an up) grade the first time the ne- version is started. <hen Liferay does this, it -i// auto) matica//y upgrade the database to the format reHuired by the ne- version. $n order to do this, Liferay must be accessing the database -ith an $= that can create, drop, and modify tab/es. :a.e sure that you have granted these permissions to the $= before you attempt to upgrade Liferay. $t is a/so a good idea to bac.up your database before attempting an upgrade in case something goes -rong during the process.

0pgrading Liferay

!('

:aintaining A Liferay @orta/ Ti#$ Liferay versions prior to #.;.9 reJuire that you manually run (KL scripts on your database to perform an upgrade. %f you need to upgrade from Liferay #.!.x to #.:.x& you can find these (KL scripts in the source code archive for the version of Liferay you are running. They will be in the S#L folder of the archive.

-PGRA0 ST PS
$t ta.es on/y four steps to upgrade a standard Liferay insta//ation2 A. !. Copy your customized %ortal&ext'%ro%erties fi/e to a safe p/ace, and then un) dep/oy the o/d version of Liferay and shut do-n your app/ication server. Copy the ne- versions of the dependency .Iars to a /ocation on your server's c/ass path, over-riting the ones you a/ready have for the o/d version of Liferay. =ep/oy the ne- Liferay .-ar fi/e to your app/ication server. 9o//o- the de) p/oyment instructions in Chapter A or in Chapter * 5if you have customized Liferay6. Start 5or restart6 your app/ication server. <atch the conso/e as Liferay starts2 it shou/d upgrade the database automatica//y. Revie- the %ortal'%ro%& erties changes and re)configure your previous customizations as necessary, restarting -hen customizations are comp/ete.

8.

C.

,hat's a// there is to it. >verything e/se is hand/ed by Liferay's upgrade proced) ure. &ote that as stated above, if you have to upgrade over severa/ Liferay versions, you -i// need to repeat these steps for each maIor re/ease. <hat fo//o-s are instructions for upgrading for specific versions.

-#)radin) Li%era& ;.9 to Li%era& ;.; PR R C-.S.T


$n order to upgrade to C.C.4, you must start at C.8." or above. $f you are using ver) sion C.!.! or be/o-, p/ease see the upgrade instructions on Liferay's -i.i at http277-i.i./iferay.com. 9o//o- the generic upgrade steps above. :a.e sure your Liferay .-ar and de) pendency .Iars are a// the same version.

.* 51-R 0 > L1P RS 3A> !-ST1/.D 0 L.* RA5


$f you are dep/oying Liferay from an e4tension environment, ensure that your deve/opers have2 A. Run Service %ui/der for each custom service. !. >dited their custom X:ode/YLoca/Service$mp/ c/asses and ma.e them e4tend from X:ode/YLoca/Service%ase$mp/. !(( 0pgrading Liferay

:aintaining A Liferay @orta/ 8. Run Service %ui/der again for each of the custom services after the previous change. :any of the =,= references in the various &ext'xml fi/es have changed 5liferay& %ortlet&ext'xml in particu/ar6. %e sure to compare your TZD0C4AP1 references -ith the main fi/e to insure they reference the same =,=.
4A/PL

Lifera 4.3.()
9Q)N&/Z". liferay-portlet-app ",S!I& D-!iferay)/) "ortlet 8pplication =.2.4.'D Dhttp*//www.liferay.com/dtd/liferay-portlet-appL=L2L4.dtdD:

Lifera 4.4.()
9Q)N&/Z". liferay-portlet-app ",S!I& D-!iferay)/) "ortlet 8pplication =.=.4.'D Dhttp*//www.liferay.com/dtd/liferay-portlet-appL=L=L4.dtdD:

-#)radin) Li%era& ;.; to Li%era& =.7 PR R C-.S.T


$n order to upgrade to *.".4, you must start at C.C." or above. 9o//o- the generic upgrade steps above. :a.e sure your Liferay .-ar and de) pendency .Iars are a// the same version.

.* 51-R 0 > L1P RS 3A> !-ST1/.D 0 L.* RA5


$f you are dep/oying Liferay from an e4tension environment, ensure that your deve/opers have upgraded their Service %ui/der .4m/ fi/es to the ne- =,=s. ,he generated code is s/ight/y different, and custom -ritten finders and Local)er& viceIm%l methods need to be adopted. ,he system&ext'%ro%erties and %ortal&ext'%ro%erties fi/es have moved from ext&im%l+classes to ext&im%l+src.

!1N> RT.NG W.2. PAG S ?1PT.1NAL@


$f you -ere using the -i.i port/et, you -i// be happy to find many ne- features and improvements in *."3and everything is bac.-ards compatib/e. 1ou may -ish to convert your e4isting pages from the o/d C/assic <i.i synta4 to the ne- Creo/e 5http277---.-i.icreo/e.org6 synta4 because it's more po-erfu/ and easier to /earn and use. $t may a/so be more fami/iar to your users if they have e4peri) ence -ith other popu/ar -i.is /i.e :edia<i.i or Conf/uence. ,o that end, Liferay *." inc/udes an automatic trans/ator that -i// convert a// of the pages in the database to Creo/e. ,o run it, edit %ortal&ext'%ro%erties and set2
verify.processes com.liferay.portal.verify.KerifyRiki&reole verify.fre(uency -3

Start the server and /et the process do the -ho/e trans/ation for you automatic)

0pgrading Liferay

!(#

:aintaining A Liferay @orta/ a//y. Remember to change those properties bac. to their origina/ state before the ne4t startupU other-ise the process -i// run every time you start Liferay.

-PGRA0 TR1-(L S311T.NG


,he parameter %/%/action is no- ca//ed %/%/lifecycle' ,his has to be adapted for e4amp/e in the 9riend/y0RL:appers if you -ant them to trigger a %ro& cessActionNO. 1ou need to copy %arent&build'xml in ext&im%l from our Subversion reposit) oryU other-ise, some fi/es -i// be missing -hen dep/oying. 0p/oad in Struts port/ets is bro.en. See http277support./iferay.com7bro-se7 L>@)+CA! and http277support./iferay.com7bro-se7L>@)+C'#.

-#)radin) Li%era& =.7 to Li%era& =.6 !3ANG S .N !1N*.G-RAT.1N PR1P RT. S


%ecause of changes in the defau/t configuration, Liferay no- comes -ith severa/ configuration fi/es containing the defau/ts for previous versions. $f the porta/ is not operating the -ay you are used to, it is /i.e/y that this is because a defau/t va/ue has been changed. 1ou can revert to the previous behavior by fo//o-ing the process be) /o-.

31W

T1 2 P T3 1L0 >AL- S

,he defau/t va/ues of some properties has been changed. $n order to .eep the previous va/ues you have to pass the fo//o-ing system property -hen running Liferay2
java ... -)e<ternal-properties portal-legacy-6.4.properties

>ach app/ication server has different methods to add this system property. $n ,omcat, you -ou/d modify catalina'sh+catalina'bat or catalina'conf 5depending on the e4act version you are using6.

W3AT

3AS ( N !3ANG 0H

;ere is a description of the most significant changes. Chec. the fi/e %ortal&legacy& ?'J'%ro%erties for a fu// /ist of changed properties. la out.u$er.pri!ate.la out$.po1er.u$er.re=uired) $t's no /onger reHuired to be @o-er 0ser to have a persona/ community. ,his ne- property a//o-s fa//ing bac. to the o/d behavior. per+i$$ion$.u$er.check.algorith+) the defau/t va/ue is no- a ne- a/) gorithm that is much faster.

.* 51-R 0 > L1P RS 3A> !-ST1/.D 0 L.* RA5


9o//o-ing is a /ist of A@$ changes. $f your deve/opers used the e4tension environ) ment to deve/op custom code revie- the fo//o-ing items and adapt your code accord) !#" 0pgrading Liferay

:aintaining A Liferay @orta/ ing/y2 Severa/ c/asses have been moved from porta/)imp/ to porta/).erne/ to ma.e them avai/ab/e to p/ugins. $f you -ere using any of those c/asses you -i// have to change the import pac.age. ,he JS@@ort/et c/ass has been moved to uti/)bridges so that it can be used from p/ugins. $n order to adapt to this change do the fo//o-ing2 Any references to com'liferay'%ortlet'3)PPortlet need to be changed to com'liferay'util'bridges'*s%'3)PPortlet Chec. that the paths to your JS@ fi/es in %ortlet'xml are abso/ute paths 5from the docroot6. 9or e4amp/e, if your vie-.Isp /ives in docroot+html+, set your vie-)Isp to +html+view'*s%. >rror hand/ing has been changed in order to provide a better end)user e4) perience. ,he fo//o-ing construct2
catch (Exception e) { req.setAttribute(PageContext.EXCEPTION, e) return !apping."in#$or%ar#(ActionConstants.CO&&ON'E((O() )

shou/d be rep/aced -ith


catch (Exception e) { Porta*+ti*.sen#Error(e, request, response) return nu** )

&ote that you can a/so optiona//y inc/ude an Htt%)ervlet9es%onse code in the send1rror method.

-PGRA0.NG T3 / S
,here -ere a fe- changes bet-een the C/assic theme in *." and the C/assic theme in *.A. ;o-ever, these changes -ere predominant/y CSS on/y changes, but if you bui/t your theme from the p/ugins directory, and used the Mdiffs directory and p/aced your CSS changes in custom.css, you may need to ma.e a fe- adIustments to your CSS.

N W !SS *.L
,here is a ne- fi/e -hich your deve/opers -i// need to inc/ude a fi/e ca//ed a%%lic& ation'css. ,he /ist of these fi/es is /ocated in +css+main'css. At the top, right after base'c& ss, you -ou/d add this /ine2
Iimport urlAapplication.cssB7

,his fi/e inc/udes a// of the sty/ing that is used for app/ication e/ements, such as dia/ogs, in/ine popups, tabs, tags, and other e/ements. Some ru/es -ere added 5that may need to be over-ritten for your theme6 and some ru/es -ere removed 5and may need to be re)added6. $f ho-ever, your theme is a/ready bui/t, and you edited the fi/es direct/y, for the most part, you -on't be af) fected. ?vera//, most changes are minor, but there are a coup/e that cou/d cause con) fusion. ,hese are covered be/o-. 0pgrading Liferay !#A

:aintaining A Liferay @orta/

T3 PAR NT -PGRA0.NG

L / NT 1* T3

01!2 /A5 !3ANG P1S.T.1N.NG W3 N

$n *.A a change -as made to the =oc. JavaScript -hich is a fi4, but o/der themes may re/y on the KbuggyL behavior. >ssentia//y, the CSS positioning of the =oc.'s par) ent -as a/-ays set to relativeW ho-ever, there are often times -hen a theme reHuires that it use a different positioning mechanism. ,he script no- /oo.s to see -hat the theme deve/oper has specified and uses that. ,here is, ho-ever, one caveat. Some) times, you abso/ute/y must not have a positioned parent at a//. ,he script, ho-ever, needs a positioned parent in most cases, and -i// app/y one -henever the CSS position is set to %osition! static, since that is -hat the bro-ser -i// return if no positioning is app/ied. So the prob/em in that situation is that if you must have %osition! static$ the script -i// a/-ays over-rite it. $n order to account for this, chec.ing has been added so that if your CSS se/ector has these t-o ru/es2
position* static7 top* 47

then it -i// use static positioning. ,he thin.ing is that because setting to%! J on a statica//y positioned item has no effect visua//y, -e use it as a trigger to say that you really -ant to use static positioning. ;o-ever, it no- -i// a//o- you to define other positioning 5abso/ute, re/ative, or fi4ed6 -ithout -orrying about your defined sty/ing being over-ritten.

T3 !LASS NA/ S *1R 0.** R NT -. !1/P1N NTS 3A> !3ANG 0


?ne of the on/y changes that -i// have a rea/ impact is that the sty/e '%o%u% for the in/ine popups has been changed to 'ui&dialog. ?ther c/ass name changes have been made, but have been /eft on the e/ements for no- so that brea.ages -i// be .ept to a minimum. ;o-ever, defau/t sty/ing for those c/ass names have been removed from the C/assic theme. ,he c/ass names that have been changed are as fo//o-s2 .port/et)section)header is no- .resu/ts)header .port/et)section)body is no- .resu/ts)ro.port/et)section)body)hover is no- .resu/ts)ro-.hover .port/et)section)a/ternate is no- .resu/ts)ro-.a/t .port/et)section)a/ternate)hover is no- .resu/ts)ro-.a/t.hover .popup is no- .ui)dia/og .tabs is no- .ui)tabs .tag is no- .ui)tag .autocomp/ete)bo4 is no- .ui)autocomp/ete)resu/ts .drag)indicator is no- .ui)pro4y

!3ANG

.N

T3 / !SS *AST L1A0

$n *.".A, the defau/t setting for theme'css'fast'load -as false -hich means that -hen deve/opers edited the dep/oyed CSS fi/es, the changes -ou/d ta.e effect immediate/y on the ne4t page /oad. &o-, for the sa.e of better out of the box performance, the de) fau/t in *.A has been changed to true. ?f course this means that -hen deve/opers edit !#! 0pgrading Liferay

:aintaining A Liferay @orta/ the dep/oyed CSS fi/es direct/y, they -i// not see the changes ta.e effect immediate/y on the ne4t page /oad. $nstead, deve/opers shou/d ma.e the change in the pre)de) p/oyed theme and run the dep/oy process on the theme for the changes to be bund/ed and pac.ed into the everything/%ac5ed'css fi/e. ,his of course might ma.e it harder for theme deve/opers to do rea/)time testing. So, the so/ution to get the o/d behavior is simp/y to revert theme'css'fast'load to false and restart the porta/.

!3ANG

.N JA>AS!R.PT

*AST L1A0

9or the same reasons as described above, a change -as made to *avascri%t'fast'& load from false to true. =eve/opers may -ant to revert it to false for the same reason.

-PGRA0.NG P3P P1RTL TS


Some changes -ere made to the hand/ing of @;@ port/ets, inc/uding the addition of ne- init)param va/ues 5see2 http277support./iferay.com7bro-se7L>@)+C+*6. A/so, maIor changes to util&*ava c/asses 5such as the e/imination of String:a.er, for e4) amp/e6 reHuires that some of the JARs in <>%)$&97/ib be updated. ,o upgrade an o/d @;@ port/et, deve/opers shou/d first ma.e a bac.)up of the e4) isting port/et. ,hen the @;@ portions 5inc/uding ;,:L, images, CSS, Iavascript6, shou/d be zipped and re)dep/oyed through the @/ug)$n $nsta//er. Liferay, as usua/, -i// inIect the needed fi/es, inc/uding everything in the <>%)$&9 directory, the Fuercus /ibraries, and so forth. $f your deve/opers are uneasy about this approach, you can a/so dep/oy an empty inde4.php fi/e in a G$@ through the @/ug)$n $nsta//er and then use the resu/t to do a K=$99L of your e4isting port/et -ith the inIected portions of the ne- port/et. ,hen the parts that need to be changed can be manua//y updated in the e4isting port/et. ,his might usefu/, for e4amp/e if you -ant to ma.e sure the $= of your port/et does not change 5especia//y if you have many instances scattered throughout your site6, or if you've been using the liferay&%lugin&%ac5age'xml fi/e to .eep trac. of versions and com) patibi/ity.

JA>AS!R.PT

!3ANG S

,he Javascript in Liferay has undergone a refactoring to use the IFuery 0$ en) gine, upgrading IFuery to the /atest version 5version A.!.+ in Liferay *.A6, and remov) ing the $nterface /ibrary. <e've a/so removed and changed many of our methods that -ere po//uting the g/oba/ name space and7or -ere not being used anymore.

!3ANG

0 / T310S

add&ortletE add&ortlet28%L) ,hese have no- been changed to Liferay.@ort) /et.add56 and Liferay.@ort/et.add;,:L56, respective/y. Sho1La out8e+plate$) ,his is no- Liferay.Layout.sho-,emp/ates56.

0pgrading Liferay

!#8

:aintaining A Liferay @orta/ Star:atingE 8hu+bnail:atingE 8ooltipE 8ab$) ,hese are no- Liferay.@orta/.S) tarRating56, Liferay.@orta/.,humbnai/Rating56, Liferay.@orta/.,oo/tip, and Liferay.) @orta/.,abs respective/y. #le+ent.di$able) @/ease use Liferay.0ti/.disab/e>/ements56. #le+ent.re+o!e) @/ease use IFuery5se/ector6.remove56. ;ie1port.fra+eE ;ie1port.$crollE ;ie1port.page) ,hese are noLiferay.0ti/.vie-port.frame56, Liferay.0ti/.vie-port.scro//56, and Liferay.0ti/.vie-) port.page56, respective/y.

/1> 0 JA>AS!R.PT / T310S

A@a(6tilE A@a(:e=ue$tE and load&age) @/ease use IFuery.aIa4 or any of the other IFuery AJAD methods. LinkedLi$tE 3a!?l outE *ragLinkE &hotoSliderE &ortlet2eader-ar) &o /onger needed. Coordinate$E CoordinateE %ou$e&o$) &o /onger needed. $f you need mouse co) ordinates during an event 5such as onMousemove, onMouseover6, or if you're attaching events -ith IFuery, you can re/iab/y use the event'%ageE and event'%ageA properties, /i.e so2
j%ueryAwindowB.mousemoveA functionAeventBG var < event.pageZ7 H B7 event.page;7 var y

Lifera .6til.to4S73StringE Lifera .6til.to4S737b@ect) &o /onger needed. 1ou can use IFuery.parseJS?&5str6 and IFuery.toJS?&5obI6 respective/y. Lifera .6til.getSelectedInde() &o /onger needed, as it -as being used to se/ect the Kchec.edL item in a group of radio buttons. ,o do the same thing, you -ou/d do something /i.e2
j%ueryA.lement]SelectorB.filterAW*checkedWB7

$f you abso/ute/y must have the actua/ numerica/ inde4 of the se/ected item, you cou/d do2
var radioOroup var inde< j%ueryA.lement]SelectorB7 radioOroup.inde<AradioOroup.filterAW*checkedWBU4VB7

-#)radin) *rom Li%era& =.6 to Li%era& =.8


A/-ays use the /atest version of *.! avai/ab/e as it -i// have fi4ed a// the potentia/ upgrade issues that may have been found.

PR R C-.S.T
$t's recommended to upgrade first at /east to *.A.!S> if you are running any pre) vious version.

!#C

0pgrading Liferay

:aintaining A Liferay @orta/

!3ANG S .N !1N*.G-RAT.1N PR1P RT. S


31W
T1 2 P T3 1L0 >AL- S

,he defau/t va/ues of some properties has been changed. $n order to .eep the previous va/ues you have to run Liferay passing the fo//o-ing system property2
java ... -)e<ternal-properties portal-legacy-6.3.properties

>ach app/ication server has different methods to add this system property. $n ,omcat modify setenv'sh+setenv'bat and append that option to the environment vari) ab/e JABAM?@,S. ,he scripts setenv'sh or setenv'bat are not de/ivered -ith ,omcat but if they e4ist, ,omcat -i// use them in the startup process, so it's a nice -ay to separate your o-n settings from tomcat's defau/t she// scripts. ;ere are the comp/ete contents of that fi/e 5porta/)/egacy)*.A.properties6 for ref) erence2
resource.repositories.root @Guser.homeH/liferay theme.portlet.sharing.default true organi>ations.country.re(uiredUregularV true organi>ations.assignment.auto true organi>ations.assignment.strict false organi>ations.membership.strict true lucene.dir @Gresource.repositories.rootH/lucene/ jcr.jackrabbit.repository.root @Gresource.repositories.rootH/jackrabbit dl.hook.impl com.liferay.documentlibrary.util.E&FMook dl.hook.file.system.root.dir @Gresource.repositories.rootH/documentLlibrary

./P1RTANT
.NT GRAT.1N

!3ANG S .N T3 !1N*.G-RAT.1N 1*

0ATA(AS

A!! SS AN0 /A.L

?ne very important aspect of the upgrade is that no- the configuration of the database parameters and those for mai/ integration are hand/ed through the %ortal& ext'%ro%erties fi/e to unify the configuration through a// app/ication servers. $t's sti// possib/e to use app/ication server specific data sources and poo/s if de) sired by using certain configuration properties. ,his is documented in Chapter A.

T3 / -PGRA0
$nstructions for maintaining customized themes bui/t in *.A -ithout redep/oying -ith the ne- S=E 2 Change the header of +@1"&I6(+liferay&%lugin&%ac5age'xml to2 !#*

0pgrading Liferay

:aintaining A Liferay @orta/


9Q)N&/Z". plugin-package ",S!I& D-//!iferay//)/) "lugin "ackage 6.5.4//.'D Dhttp*//www.liferay.com/dtd/liferay-plugin-packageL6L5L4.dtdD:

Change the header of +@1"&I6(+liferay&loo5&and&feel'xml to2

9Q)N&/Z". look-and-feel ",S!I& D-//!iferay//)/) !ook and 0eel 6.5.4//.'D DUhttp*//www.liferay.com/dtd/liferay-look-and-feelL6L5L4.dtdD:V

0pgrade compatibi/ity version in liferay&loo5&and&feel'xml2


9version:6.5.5\9/version:

9compatibility: 9/compatibility:

$n %ortal'vm, de/ete the fo//o-ing /ines 2

@theme.includeA@bottomLe<tLincludeB @theme.includeA@sessionLtimeoutLincludeB @theme.includeA@soundLalertsLincludeB

$f you don't remove these, you -i// see a b/an. page and an e4ception. $n order to disp/ay the contro/ pane/ in the doc., add the fo//o-ing /ines in doc5'vm2

#if A@showLcontrolLpanelB 9li class Dcontrol-panelD: 9a href D@controlLpanelLurlD:@controlLpanelLte<t9/a: 9/li: #end

$n navigation'css2
background-image* urlA../images/dock/controlLpanel.pngB7

.lfr-dock li.control-panel a G H

,hen copy +images+doc5+control/%anel'%ng 59004+html+themes+classic6 into your theme.

from

the

c/assic

theme

$n @1"&I6(+web'xml, change the deprecated dec/aration com'liferay'%ortal'ser& vlet'filters'com%ression'Com%ression(ilter into com'liferay'%ortal'servlet'filters'g& Li%'.Xi%(ilter.

AP. !3ANG S
-SAG
1*

S R>.! !1NT

4T .N

L.* RA5'S S R>.! S LA5 R

,he most significant A@$ change in *.! is that most A@$s of the service /ayer have been adapted to use the Service Conte4t @attern. ,he Service Conte4t is an obIect that contains conte4t information about a given A@$ ca//. A// of the fie/ds in this obIect are optiona/, a/though the services that store any type of content -i// reHuire you to spe) cify at /east the sco%e.rou%Id. ;ere is a simp/e e4amp/e of ho- to create a ServiceCon) te4t instance and pass it to a service A@$2
Service&onte<t service&onte<t new Service&onte<tAB7

!#+

0pgrading Liferay

:aintaining A Liferay @orta/


service&onte<t.setScopeOroupIdAmyOroupIdB7 Slogs.ntryService,til.add.ntryA...., service&onte<tB7

$f you are invo.ing the service from a serv/et, a Struts action, or any other front end c/ass -hich has access to the port/etReHuest, you can use a uti/ity method that -i// create the ServiceConte4t obIect and fi// it -ith a// the necessary va/ues automat) ica//y. $n that case the above e4amp/e shou/d be re-ritten as fo//o-s2
Service&onte<t service&onte<t Service&onte<t0actory.getInstanceASlogs.ntry.class.get'ameAB, portletFe(uestB7 Slogs.ntryService,til.add.ntryA...., service&onte<tB7

0pgrading Liferay

!#'

$. APPENDI%& DOCU"ENTATION LICENSE

,he te4t of this boo. is copyrighted by Liferay, $nc., and is re/eased under the Creative Commons Attribution&)hareali5e 2'J Un%orted /icense.

!reative !ommons License


CR>A,$B> C?::?&S C?R@?RA,$?& $S &?, A LA< 9$R: A&= =?>S &?, @R?B$=> L>GAL S>RB$C>S. =$S,R$%0,$?& ?9 ,;$S L$C>&S> =?>S &?, CR>A,> A& A,,?R&>1)CL$>&, R>LA,$?&S;$@. CR>A,$B> C?::?&S @R?B$=>S ,;$S $&9?R:A,$?& ?& A& \AS)$S\ %AS$S. CR>A,$B> C?::?&S :AE>S &? <ARRA&,$>S R>GAR=$&G ,;> $&9?R:A,$?& @R?B$=>=, A&= =$SCLA$:S L$A%$L$,1 9?R =A:AG>S R>S0L,$&G 9R?: $,S 0S>.

License
,;> <?RE 5AS =>9$&>= %>L?<6 $S @R?B$=>= 0&=>R ,;> ,>R:S ?9 ,;$S CR>) A,$B> C?::?&S @0%L$C L$C>&S> 5\CC@L\ ?R \L$C>&S>\6. ,;> <?RE $S @R?,>C,>= %1 C?@1R$G;, A&=7?R ?,;>R A@@L$CA%L> LA<. A&1 0S> ?9 ,;> <?RE ?,;>R ,;A& AS A0,;?R$G>= 0&=>R ,;$S L$C>&S> ?R C?@1R$G;, LA< $S @R?;$%$,>=. %1 >D>RC$S$&G A&1 R$G;,S ,? ,;> <?RE @R?B$=>= ;>R>, 1?0 ACC>@, A&= AGR>> ,? %> %?0&= %1 ,;> ,>R:S ?9 ,;$S L$C>&S>. ,? ,;> >D,>&, ,;$S L$C>&S> :A1 %> C?&S$=>R>= ,? %> A C?&,RAC,, ,;> L$C>&S?R GRA&,S 1?0 ,;> R$G;,S C?&,A$&>= ;>R> $& C?&S$=>RA,$?& ?9 1?0R ACC>@,A&C> ?9 S0C; ,>R:S A&= C?&=$,$?&S. 1. *efinition$ a. GAdaptationG means a -or. based upon the <or., or upon the <or. and other pre)e4isting -or.s, such as a trans/ation, adaptation, derivative -or., arrangement of music or other a/terations of a /iterary or artistic -or., or

Appendi42 =ocumentation License phonogram or performance and inc/udes cinematographic adaptations or any other form in -hich the <or. may be recast, transformed, or adapted inc/uding in any form recognizab/y derived from the origina/, e4cept that a -or. that constitutes a Co//ection -i// not be considered an Adaptation for the purpose of this License. 9or the avoidance of doubt, -here the <or. is a musica/ -or., performance or phonogram, the synchronization of the <or. in timed)re/ation -ith a moving image 5\synching\6 -i// be considered an Adaptation for the purpose of this License. GCollectionG means a co//ection of /iterary or artistic -or.s, such as encyc) /opedias and antho/ogies, or performances, phonograms or broadcasts, or other -or.s or subIect matter other than -or.s /isted in Section A5f6 be/o-, -hich, by reason of the se/ection and arrangement of their contents, consti) tute inte//ectua/ creations, in -hich the <or. is inc/uded in its entirety in unmodified form a/ong -ith one or more other contributions, each consti) tuting separate and independent -or.s in themse/ves, -hich together are assemb/ed into a co//ective -ho/e. A -or. that constitutes a Co//ection -i// not be considered an Adaptation 5as defined be/o-6 for the purposes of this License. GCreati!e Co++on$ Co+patible Licen$eG means a /icense that is /isted at http277creativecommons.org7compatib/e/icenses that has been approved by Creative Commons as being essentia//y eHuiva/ent to this License, inc/uding, at a minimum, because that /icense2 5i6 contains terms that have the same purpose, meaning and effect as the License >/ements of this LicenseU and, 5ii6 e4p/icit/y permits the re/icensing of adaptations of -or.s made avai/ab/e un) der that /icense under this License or a Creative Commons Iurisdiction /i) cense -ith the same License >/ements as this License. G*i$tributeG means to ma.e avai/ab/e to the pub/ic the origina/ and copies of the <or. or Adaptation, as appropriate, through sa/e or other transfer of o-nership. GLicen$e #le+ent$G means the fo//o-ing high)/eve/ /icense attributes as se) /ected by Licensor and indicated in the tit/e of this License2 Attribution, ShareA/i.e. GLicen$orG means the individua/, individua/s, entity or entities that offer5s6 the <or. under the terms of this License. G7riginal AuthorG means, in the case of a /iterary or artistic -or., the indi) vidua/, individua/s, entity or entities -ho created the <or. or if no individu) a/ or entity can be identified, the pub/isherU and in addition 5i6 in the case of a performance the actors, singers, musicians, dancers, and other persons -ho act, sing, de/iver, dec/aim, p/ay in, interpret or other-ise perform /iter) ary or artistic -or.s or e4pressions of fo/./oreU 5ii6 in the case of a phono) gram the producer being the person or /ega/ entity -ho first fi4es the sounds of a performance or other soundsU and, 5iii6 in the case of broadcasts, the organization that transmits the broadcast. G5orkG means the /iterary and7or artistic -or. offered under the terms of this License inc/uding -ithout /imitation any production in the /iterary, sci) entific and artistic domain, -hatever may be the mode or form of its e4pres) sion inc/uding digita/ form, such as a boo., pamph/et and other -ritingU a /ecture, address, sermon or other -or. of the same natureU a dramatic or dramatico)musica/ -or.U a choreographic -or. or entertainment in dumb sho-U a musica/ composition -ith or -ithout -ordsU a cinematographic Creative Commons License

b.

c.

d. e. f. g.

h.

8""

Appendi42 =ocumentation License -or. to -hich are assimi/ated -or.s e4pressed by a process ana/ogous to cinematographyU a -or. of dra-ing, painting, architecture, scu/pture, en) graving or /ithographyU a photographic -or. to -hich are assimi/ated -or.s e4pressed by a process ana/ogous to photographyU a -or. of app/ied artU an i//ustration, map, p/an, s.etch or three)dimensiona/ -or. re/ative to geo) graphy, topography, architecture or scienceU a performanceU a broadcastU a phonogramU a compi/ation of data to the e4tent it is protected as a copy) rightab/e -or.U or a -or. performed by a variety or circus performer to the e4tent it is not other-ise considered a /iterary or artistic -or.. i. GHouG means an individua/ or entity e4ercising rights under this License -ho has not previous/y vio/ated the terms of this License -ith respect to the <or., or -ho has received e4press permission from the Licensor to e4ercise rights under this License despite a previous vio/ation. I. G&ublicl &erfor+G means to perform pub/ic recitations of the <or. and to communicate to the pub/ic those pub/ic recitations, by any means or pro) cess, inc/uding by -ire or -ire/ess means or pub/ic digita/ performancesU to ma.e avai/ab/e to the pub/ic <or.s in such a -ay that members of the pub/ic may access these <or.s from a p/ace and at a p/ace individua//y chosen by themU to perform the <or. to the pub/ic by any means or process and the communication to the pub/ic of the performances of the <or., inc/uding by pub/ic digita/ performanceU to broadcast and rebroadcast the <or. by any means inc/uding signs, sounds or images. .. G:eproduceG means to ma.e copies of the <or. by any means inc/uding -ithout /imitation by sound or visua/ recordings and the right of fi4ation and reproducing fi4ations of the <or., inc/uding storage of a protected per) formance or phonogram in digita/ form or other e/ectronic medium. 2. ?air *ealing :ight$. &othing in this License is intended to reduce, /imit, or restrict any uses free from copyright or rights arising from /imitations or e4ceptions that are provided for in connection -ith the copyright protection under copyright /a- or other app/icab/e /a-s. 3. Licen$e >rant. SubIect to the terms and conditions of this License, Licensor hereby grants 1ou a -or/d-ide, roya/ty)free, non)e4c/usive, perpetua/ 5for the dura) tion of the app/icab/e copyright6 /icense to e4ercise the rights in the <or. as stated be/o-2 a. to Reproduce the <or., to incorporate the <or. into one or more Co//ec) tions, and to Reproduce the <or. as incorporated in the Co//ectionsU b. to create and Reproduce Adaptations provided that any such Adaptation, in) c/uding any trans/ation in any medium, ta.es reasonab/e steps to c/ear/y /a) be/, demarcate or other-ise identify that changes -ere made to the origina/ <or.. 9or e4amp/e, a trans/ation cou/d be mar.ed \,he origina/ -or. -as trans/ated from >ng/ish to Spanish,\ or a modification cou/d indicate \,he origina/ -or. has been modified.\U c. to =istribute and @ub/ic/y @erform the <or. inc/uding as incorporated in Co//ectionsU and, d. to =istribute and @ub/ic/y @erform Adaptations. e. 9or the avoidance of doubt2 i. 3on01ai!able Co+pul$or Licen$e Sche+e$. $n those Iurisdic)

Creative Commons License

8"A

Appendi42 =ocumentation License tions in -hich the right to co//ect roya/ties through any statutory or compu/sory /icensing scheme cannot be -aived, the Licensor re) serves the e4c/usive right to co//ect such roya/ties for any e4ercise by 1ou of the rights granted under this LicenseU ii. 5ai!able Co+pul$or Licen$e Sche+e$. $n those Iurisdictions in -hich the right to co//ect roya/ties through any statutory or com) pu/sory /icensing scheme can be -aived, the Licensor -aives the e4c/usive right to co//ect such roya/ties for any e4ercise by 1ou of the rights granted under this LicenseU and, iii. ;oluntar Licen$e Sche+e$. ,he Licensor -aives the right to co/) /ect roya/ties, -hether individua//y or, in the event that the Li) censor is a member of a co//ecting society that administers vo/un) tary /icensing schemes, via that society, from any e4ercise by 1ou of the rights granted under this License. ,he above rights may be e4ercised in a// media and formats -hether no- .no-n or hereafter devised. ,he above rights inc/ude the right to ma.e such modifications as are technica//y necessary to e4ercise the rights in other media and formats. SubIect to Section (5f6, a// rights not e4press/y granted by Licensor are hereby reserved. 4. :e$triction$. ,he /icense granted in Section 8 above is e4press/y made subIect to and /imited by the fo//o-ing restrictions2 a. 1ou may =istribute or @ub/ic/y @erform the <or. on/y under the terms of this License. 1ou must inc/ude a copy of, or the 0niform Resource $dentifier 50R$6 for, this License -ith every copy of the <or. 1ou =istribute or @ub) /ic/y @erform. 1ou may not offer or impose any terms on the <or. that re) strict the terms of this License or the abi/ity of the recipient of the <or. to e4ercise the rights granted to that recipient under the terms of the License. 1ou may not sub/icense the <or.. 1ou must .eep intact a// notices that refer to this License and to the disc/aimer of -arranties -ith every copy of the <or. 1ou =istribute or @ub/ic/y @erform. <hen 1ou =istribute or @ub/ic/y @erform the <or., 1ou may not impose any effective techno/ogica/ meas) ures on the <or. that restrict the abi/ity of a recipient of the <or. from 1ou to e4ercise the rights granted to that recipient under the terms of the License. ,his Section C5a6 app/ies to the <or. as incorporated in a Co//ec) tion, but this does not reHuire the Co//ection apart from the <or. itse/f to be made subIect to the terms of this License. $f 1ou create a Co//ection, upon notice from any Licensor 1ou must, to the e4tent practicab/e, remove from the Co//ection any credit as reHuired by Section C5c6, as reHuested. $f 1ou create an Adaptation, upon notice from any Licensor 1ou must, to the e4tent practicab/e, remove from the Adaptation any credit as reHuired by Section C5c6, as reHuested. b. 1ou may =istribute or @ub/ic/y @erform an Adaptation on/y under the terms of2 5i6 this LicenseU 5ii6 a /ater version of this License -ith the same License >/ements as this LicenseU 5iii6 a Creative Commons Iurisdiction /icense 5either this or a /ater /icense version6 that contains the same License >/e) ments as this License 5e.g., Attribution)ShareA/i.e 8." 0S66U 5iv6 a Creative Commons Compatib/e License. $f you /icense the Adaptation under one of the /icenses mentioned in 5iv6, you must comp/y -ith the terms of that /i) cense. $f you /icense the Adaptation under the terms of any of the /icenses 8"! Creative Commons License

Appendi42 =ocumentation License mentioned in 5i6, 5ii6 or 5iii6 5the \App/icab/e License\6, you must comp/y -ith the terms of the App/icab/e License genera//y and the fo//o-ing provi) sions2 5$6 1ou must inc/ude a copy of, or the 0R$ for, the App/icab/e License -ith every copy of each Adaptation 1ou =istribute or @ub/ic/y @erformU 5$$6 1ou may not offer or impose any terms on the Adaptation that restrict the terms of the App/icab/e License or the abi/ity of the recipient of the Adapta) tion to e4ercise the rights granted to that recipient under the terms of the App/icab/e LicenseU 5$$$6 1ou must .eep intact a// notices that refer to the Ap) p/icab/e License and to the disc/aimer of -arranties -ith every copy of the <or. as inc/uded in the Adaptation 1ou =istribute or @ub/ic/y @erformU 5$B6 -hen 1ou =istribute or @ub/ic/y @erform the Adaptation, 1ou may not im) pose any effective techno/ogica/ measures on the Adaptation that restrict the abi/ity of a recipient of the Adaptation from 1ou to e4ercise the rights granted to that recipient under the terms of the App/icab/e License. ,his Section C5b6 app/ies to the Adaptation as incorporated in a Co//ection, but this does not reHuire the Co//ection apart from the Adaptation itse/f to be made subIect to the terms of the App/icab/e License. c. $f 1ou =istribute, or @ub/ic/y @erform the <or. or any Adaptations or Co/) /ections, 1ou must, un/ess a reHuest has been made pursuant to Section C5a6, .eep intact a// copyright notices for the <or. and provide, reasonab/e to the medium or means 1ou are uti/izing2 5i6 the name of the ?rigina/ Author 5or pseudonym, if app/icab/e6 if supp/ied, and7or if the ?rigina/ Author and7or Licensor designate another party or parties 5e.g., a sponsor institute, pub) /ishing entity, Iourna/6 for attribution 5\Attribution @arties\6 in Licensor's copyright notice, terms of service or by other reasonab/e means, the name of such party or partiesU 5ii6 the tit/e of the <or. if supp/iedU 5iii6 to the e4) tent reasonab/y practicab/e, the 0R$, if any, that Licensor specifies to be as) sociated -ith the <or., un/ess such 0R$ does not refer to the copyright no) tice or /icensing information for the <or.U and 5iv6 , consistent -ith Ssection 85b6, in the case of an Adaptation, a credit identifying the use of the <or. in the Adaptation 5e.g., \9rench trans/ation of the <or. by ?rigina/ Author,\ or \Screenp/ay based on origina/ <or. by ?rigina/ Author\6. ,he credit re) Huired by this Section C5c6 may be imp/emented in any reasonab/e mannerU provided, ho-ever, that in the case of a Adaptation or Co//ection, at a min) imum such credit -i// appear, if a credit for a// contributing authors of the Adaptation or Co//ection appears, then as part of these credits and in a man) ner at /east as prominent as the credits for the other contributing authors. 9or the avoidance of doubt, 1ou may on/y use the credit reHuired by this Section for the purpose of attribution in the manner set out above and, by e4ercising 1our rights under this License, 1ou may not imp/icit/y or e4p/i) cit/y assert or imp/y any connection -ith, sponsorship or endorsement by the ?rigina/ Author, Licensor and7or Attribution @arties, as appropriate, of 1ou or 1our use of the <or., -ithout the separate, e4press prior -ritten permission of the ?rigina/ Author, Licensor and7or Attribution @arties. d. >4cept as other-ise agreed in -riting by the Licensor or as may be other) -ise permitted by app/icab/e /a-, if 1ou Reproduce, =istribute or @ub/ic/y @erform the <or. either by itse/f or as part of any Adaptations or Co//ec) tions, 1ou must not distort, muti/ate, modify or ta.e other derogatory action in re/ation to the <or. -hich -ou/d be preIudicia/ to the ?rigina/ Author's honor or reputation. Licensor agrees that in those Iurisdictions 5e.g. Japan6, Creative Commons License 8"8

Appendi42 =ocumentation License in -hich any e4ercise of the right granted in Section 85b6 of this License 5the right to ma.e Adaptations6 -ou/d be deemed to be a distortion, muti/ation, modification or other derogatory action preIudicia/ to the ?rigina/ Author's honor and reputation, the Licensor -i// -aive or not assert, as appropriate, this Section, to the fu//est e4tent permitted by the app/icab/e nationa/ /a-, to enab/e 1ou to reasonab/y e4ercise 1our right under Section 85b6 of this Li) cense 5right to ma.e Adaptations6 but not other-ise. 5. :epre$entation$E 5arrantie$ and *i$clai+er 0&L>SS ?,;>R<$S> :0,0ALL1 AGR>>= ,? %1 ,;> @AR,$>S $& <R$,$&G, L$) C>&S?R ?99>RS ,;> <?RE AS)$S A&= :AE>S &? R>@R>S>&,A,$?&S ?R <AR) RA&,$>S ?9 A&1 E$&= C?&C>R&$&G ,;> <?RE, >D@R>SS, $:@L$>=, S,A,0,?R1 ?R ?,;>R<$S>, $&CL0=$&G, <$,;?0, L$:$,A,$?&, <ARRA&,$>S ?9 ,$,L>, :>R) C;A&,$%$L$,1, 9$,&>SS 9?R A @AR,$C0LAR @0R@?S>, &?&$&9R$&G>:>&,, ?R ,;> A%S>&C> ?9 LA,>&, ?R ?,;>R =>9>C,S, ACC0RAC1, ?R ,;> @R>S>&C> ?9 A%) S>&C> ?9 >RR?RS, <;>,;>R ?R &?, =$SC?B>RA%L>. S?:> J0R$S=$C,$?&S =? &?, ALL?< ,;> >DCL0S$?& ?9 $:@L$>= <ARRA&,$>S, S? S0C; >DCL0S$?& :A1 &?, A@@L1 ,? 1?0. ". Li+itation on Liabilit . >DC>@, ,? ,;> >D,>&, R>F0$R>= %1 A@@L$CA%L> LA<, $& &? >B>&, <$LL L$C>&S?R %> L$A%L> ,? 1?0 ?& A&1 L>GAL ,;>?R1 9?R A&1 S@>C$AL, $&C$=>&,AL, C?&S>F0>&,$AL, @0&$,$B> ?R >D>:@LAR1 =A:AG>S AR$S$&G ?0, ?9 ,;$S L$C>&S> ?R ,;> 0S> ?9 ,;> <?RE, >B>& $9 L$C>&S?R ;AS %>>& A=B$S>= ?9 ,;> @?SS$%$L$,1 ?9 S0C; =A:AG>S. 7. 8er+ination a. ,his License and the rights granted hereunder -i// terminate automatica//y upon any breach by 1ou of the terms of this License. $ndividua/s or entities -ho have received Adaptations or Co//ections from 1ou under this License, ho-ever, -i// not have their /icenses terminated provided such individua/s or entities remain in fu// comp/iance -ith those /icenses. Sections A, !, *, +, ', and ( -i// survive any termination of this License. b. SubIect to the above terms and conditions, the /icense granted here is per) petua/ 5for the duration of the app/icab/e copyright in the <or.6. &ot-ith) standing the above, Licensor reserves the right to re/ease the <or. under different /icense terms or to stop distributing the <or. at any timeU provided, ho-ever that any such e/ection -i// not serve to -ithdra- this Li) cense 5or any other /icense that has been, or is reHuired to be, granted under the terms of this License6, and this License -i// continue in fu// force and ef) fect un/ess terminated as stated above. '. %i$cellaneou$ a. >ach time 1ou =istribute or @ub/ic/y @erform the <or. or a Co//ection, the Licensor offers to the recipient a /icense to the <or. on the same terms and conditions as the /icense granted to 1ou under this License. b. >ach time 1ou =istribute or @ub/ic/y @erform an Adaptation, Licensor offers to the recipient a /icense to the origina/ <or. on the same terms and condi) tions as the /icense granted to 1ou under this License. c. $f any provision of this License is inva/id or unenforceab/e under app/icab/e /a-, it sha// not affect the va/idity or enforceabi/ity of the remainder of the 8"C Creative Commons License

Appendi42 =ocumentation License terms of this License, and -ithout further action by the parties to this agree) ment, such provision sha// be reformed to the minimum e4tent necessary to ma.e such provision va/id and enforceab/e. d. &o term or provision of this License sha// be deemed -aived and no breach consented to un/ess such -aiver or consent sha// be in -riting and signed by the party to be charged -ith such -aiver or consent. e. ,his License constitutes the entire agreement bet-een the parties -ith re) spect to the <or. /icensed here. ,here are no understandings, agreements or representations -ith respect to the <or. not specified here. Licensor sha// not be bound by any additiona/ provisions that may appear in any com) munication from 1ou. ,his License may not be modified -ithout the mutua/ -ritten agreement of the Licensor and 1ou. f. ,he rights granted under, and the subIect matter referenced, in this License -ere drafted uti/izing the termino/ogy of the %erne Convention for the @ro) tection of Literary and Artistic <or.s 5as amended on September !(, A#'#6, the Rome Convention of A#+A, the <$@? Copyright ,reaty of A##+, the <$@? @erformances and @honograms ,reaty of A##+ and the 0niversa/ Copyright Convention 5as revised on Ju/y !C, A#'A6. ,hese rights and subIect matter ta.e effect in the re/evant Iurisdiction in -hich the License terms are sought to be enforced according to the corresponding provisions of the imp/ement) ation of those treaty provisions in the app/icab/e nationa/ /a-. $f the stand) ard suite of rights granted under app/icab/e copyright /a- inc/udes addition) a/ rights not granted under this License, such additiona/ rights are deemed to be inc/uded in the LicenseU this License is not intended to restrict the /i) cense of any rights under app/icab/e /a-.

!reative !ommons Notice

Creative Commons is not a party to this License, and ma.es no -arranty -hatsoever in connection -ith the <or.. Creative Commons -i// not be /iab/e to 1ou or any party on any /ega/ theory for any damages -hatsoever, inc/uding -ithout /imitation any genera/, specia/, incidenta/ or conseHuentia/ damages arising in connection to this /icense. &ot-ithstanding the foregoing t-o 5!6 sentences, if Creative Commons has e4press/y identified itse/f as the Licensor hereunder, it sha// have a// rights and ob/igations of Licensor. >4cept for the /imited purpose of indicating to the pub/ic that the <or. is /icensed under the CC@L, Creative Commons does not authorize the use by either party of the trademar. \Creative Commons\ or any re/ated trademar. or /ogo of Creative Commons -ithout the prior -ritten consent of Creative Commons. Any permitted use -i// be in comp/iance -ith Creative Commons' then) current trademar. usage guide/ines, as may be pub/ished on its -ebsite or other-ise made avai/ab/e upon reHuest from time to time. 9or the avoidance of doubt, this trademar. restriction does not form part of the License. Creative Commons may be contacted at http277creativecommons.org7.

Creative Commons License

8"*

'. COLOP(ON

,he te4t and /ayout -ere accomp/ished using ?pen?ffice.org 8.".A running on :andriva Linu4. ,he fi/e is one /arge document, rather than a mu/ti)/in.ed master document. $t's Iust easier to manage that -ay. ,he @=9 -as e4ported direct/y from ?pen?ffice.org. Some content -ritten for this boo. -as a/so e4ported to the Liferay -i.i at http277-i.i./iferay.com. $t is the intent of the author to continue doing this for every edition of this boo. that is pub/ished. <e a/so e4pect that some more com) munity documentation -i// ma.e it into the officia/ documentation. A// of the fonts used in the creation of this boo. are either open source fonts or free/y avai/ab/e fonts. ,he body te4t font is Gentium %oo. %asic, created by S$L $nter) nationa/. $t can be found here2 http277scripts.si/.org7cms7scripts7page.phpJ siteMid^nrsiPitemMid^Gentium. ,he font for the tit/es is ca//ed =e/icious, from the free e4/Ibris font foundry. $t can be found here2 http277---.Iosbuivenga.demon.n/7de/icious.htm/. ,his change -as made from the Second >dition in an attempt to give the boo. a more KmodernL /oo.. ,he te4t used in tab/es is the same. ,he font used for source code is Liberation :ono, created by Red ;at, $nc. ,he Liberation fonts can be found here2 https277---.redhat.com7promo7fonts. Screen shots that -ere ta.en by the author -ere ta.en using Esnapshot, an e4) ce//ent screen shot program that is part of the E=> des.top, version C.!.!. ?ther screen shots -ere ta.en by the contributors using un.no-n soft-are. =ra-ings in) side the boo. 5such as the 0nbrea.ab/e Liferay diagram6 -ere created in ?pen?ffice.org dra-, using some stenci/s from =ia 5http277---.gnome.org7proIects7 dia6. Some dra-ings and screen shots -ere touched up using the G$:@. ,he cover of the boo. -as done professiona//y this time by Liferay's graphics design team. ,he picture on the front cover is a picture of Crepuscu/ar Rays. ,hese are rays of sun/ight -hich appear to spring from a hidden source3usua//y from behind a c/oud,

Co/ophon but can a/so appear diffused through trees. ,he rays are actua//y para//e/, and it is perspective that ma.es them appear to converge at the Sun. A/so .no-n as God's rays, crepuscu/ar rays can be spectacu/ar and certain/y seemed appropriate for the cover of a boo. about a product ca//ed Liferay @orta/. ,his great shot -as ta.en by none other than Liferay's C>?, %ryan Cheung, in Langen, Germany, near the offices of Liferay's >uropean headHuarters. Rich Sezov, :ay !""#

8"(

Co/ophon

INDE%

A
+dmin. !& :& #& 5& L& M& !!& !:& :L& :@& ;9& #:& 5;& 5M& 8#& 8L& L9& LL"@:& @#"@@& M9"!9:& !9#& !!!& !!;& !!#& !!L& !!M& !:9& !;#& !;5& !;L" !#9& !#8& !5:& !5;& !5@& !89& !85"!L9& !L#& !L5& !LM& !M9& !ML& !M@& :95& :98& :!;& ::;& ::8& :;9& :;;& :;5& :;L& :##& :#8& :#L& :5#& :89& :8:& :8L& :L!& :@;":@5& ;9:

:5M )alendar......5& @& !:& !L& @!& M!& M5& M8& !!:& !!M& !:;& !:M"!;!& !#8& !@9& !ML& :!#& :!5 )aptcha.........................................8& #8& !@5

)as....#& 8& :!& :;& 59& M;& !9;& !95& !9M"!!!& !;;& !#9& !#@& !89& !8!& !LL& !LM& !@:& :9:& :9;& :9L& ::;& ::M& :;;& :;8& :#!& :##& :#L& :5#& :58& :5@& :8#& :88& :L9& :L@& :@#& :@5& +J+/...........................................!L& :9M& :M# :@L& :M:& :ML& ;99& ;9!& ;9; +pp.server.properties.............................:L; )hat................5& !:& !!M& !;!& !;:& !M#& :!# +uthentication pipeline.......................8& !LM )lustering...@& M& !!& !MM& :9:& :!!& :#M& :59& +uto deploy.............8& #L& !59& !5:& :;;":;5 :58":5M +uto login....................................8& !@!& !@: )ommunities.....#& @& M& @!"@#& @L& @M"M:& MM& !99& !9:& !!!& !!:& !!8& !!M& !:9& !8L& !M@& :!5& ::9& ::8& :;L& :8!& :L@& :@#

)ommunity....#& !5& !8& !@& L@"@#& @M"M:& M@" .ack up....................................:;5& :@;& :@5 !99& !!M& !:9& !:;& !:#& !:8& !:@"!;9& !;#& .logs.....5& @& !:& M;& !!:& !!M& !:;"!:M& !;L& !;5& !;M& !##& !#8& !#L& !5;& !88& !8@& !8M& !@9& !M;& !M#& :!8& ::9& ::;& ::@& :;L& :#:& !#8& !@9& !ML& :9@& :!#& :!L& :ML :#5& :#8& :8:& :@#& :M9& ;9L .undle.....;& !!& !5& !M":5& L5& !;:& ::5& :;:& )ompany %D............................................:8: :5!& :8:& :L@& :M; )ontrol panel. #& L& !:& :9& LL& LM"@!& @#& @8& @L& @M"M!& M;& M@& !9!& !9;& !95& !98& !9@& )aching. .@& #8& !5L& :9:& :9@& :!!& :#M& :58" !!9& !!:"!!8& !;:& !;M& !##& !#L& !M@& ::L& :;9& :;#":;L& :##& :5#& :89& :@9& :@#":@8&

8A"

:M8

Jackrabbit....@& M& :9& :9;& :9#& :;#& :59":5:& )ss..@& !9& !5#& :!9& :!!& :!8& ::!& :LL& :M!" :55& :5M& :L:& :@5& :M5 :M;& :M8 Jar file......#@"59& 5:& !9M& !#L& !#@& :5!& :5;& :5L

Database......;& 8& @& M& !:& !5& !L& :9":M& ;!& ;:& ;5& ;L& #9& #:"#5& #L"5#& 58"8!& 8L& 8M& L:& L;& !9;& !9#& !9L& !9@& !!#& !!8& !:9& !#L& !#M& !59& !5@& !89& !L#& !LM& !@;"!@5& !M8& :99& :9:& :9;& :#:& :##& :#8& :59":5;& :55& :58& :5@& :5M& :8!& :8:& :8L& :L:& :L5& :L@":@9& :@5& :@L":@M& :M5

Javascript. 8& !9& !L& !8!& !8:& !8#& :!9& :##& :LL& :L@& :M:":M# Jboss....;& :#& ;8"#:& !5!& !5:& :;:& :89& :8!& :85":8L& :L:& :L; J)2........L& !#M& !58& :9;& :9#& :!5& :5:& :LM& :@!& :@8& :M5 Jetty.......................;& :#& ;#";8& #5& !5!& :L;

Document Library....@& !8& M!& !!5& :98& :!5& Jonas.........................................:#& !5!& :L; :!8& :#5& :#8& :5!& :5@& :5M& :L:& :@5 Journal....@& :#& !!!& !8M& !@!& !ML& :9:& :9@& :!L":!M& :L:& ;9; Jsp......!5;& !8!& !@8& !M!"!M;& !ML& :9@& ::#& Ehcache..8& !L& !5L& !89& :9:& :!9& :#M& :58" ::L& :M! :5M& :@5 J(2"!8@.......................................L@& ::5& :@L Email......#& 5& !;& LL"LM& @#& @5& @@& M9& !9:& !9;& !95& !98& !!:& !!;& !!8& !:M"!;#& !;8& J(2"!L9....!L& :9& !!5& :9;& :59":5:& :5M& :@5 !;@& !#:& !#;& !#5& !85"!8L& !L9& !L5& !L8& J(2":@8....................!5& !L& L@& !:!& ::5& :@L !L@& !LM& !@:& !M9& :95& :98& :!;":!5& :!L" ::9& :::& ::#& ::5& :8:& :8#":88 L Extension environment...!9M& ::L& :5L& :L:" Language..;& 8& !L& !@& L@& ML& !!;& !;#& !;5& :L#& :@#& :@8":M9 !8:& !L9& !L!& !M9& :!#& :!L& ::;& :#L& :8!& :8#& :88

Language.properties. !M9& :!#& :!L& :8#& :88 =lassfish.....;& :#& :@";;& !5!& !5:& :;:& :;;& LD+-......#& 8& LL& @#& !9:"!!9& !!:& !!8& !L5" :L;& :L# !LL& !LM& !@;

Liferay -ortal. .M& !!"!;& !5"!L& !M":!& :#& :5& :L& :@& ;#& ;8";@& #9& #L"#M& 5@& 8@& 8M& L#& 4ibernate........8& @& !L& ;M& #8& !58"!5@& !89& L5& LL& @M& !95& !9@& !!!& !!5"!!L& !!M& !:#& :9:& :5L& :5@& :8!& :8L& :L5& :LM& :@! !:8& !#@& !L@& ::5& ::L& :;9& :##& :#M& :5;& 4ot deploy. .8& @& #L& !#M& !5!"!5#& ::8& ::L& :5M& :8:& :L:& :L;& :@;& :@#& ;9@ :;9":;8& :5!& :5#& :58 Liferay"portlet.xml............!L:& !L;& :9L& :L@ 4(KL........:9& :5& :8& !5M& :99& :5!& :8!& :8: Locations.........................................!L9& !M8 4tml....;!& !;L& !##& !#5& !5@& !89& !8!& !L!& Logging.....M& ;5& L@& !:;& !:#& !:L& !:@& !;;& !M;& !M#& !ML& :95& :9@& :!8& :!M& ::#& :L:& !8#& !L;& !L5& !@L& :9M& :#8& :L!& :@;& :@5& :M!& :M;& :M8& ;9L :@8 Logs..5& @& !:& :!& LM& M;& !9;& !9L& !!:& !!M& !:;"!:M& !;L& !#8& !L;& !@9& !@8& !ML& :9@& %mage =allery......................................@& :!8 :9M& :!#& :!L& :5@& :8L& :M!& :ML

%nvitation.....................................@& !ML& :!L Look and Neel....;& 8& !8& !!M& !L:& ::!& ::8& :;9& :58& :M8

Lucene...L& @& !L& :9& !MM":9!& :;#& :5!& :5;" Jaas...........8& ;5& ;8& ;@& #9& 5!& 5:& !L#& !L5 :55& :M5

8AA

/
*ail. #& 5& L& !:& !;& :5";9& ;:& ;;& ;5& ;@"#:& #5& #8& #@& 5!& 5;& 55& 5L& 5@& 8;& 88& 8@& L:" L#& LL"LM& @#& @5& @@& M9& !9:& !9;& !95& !98& !!:& !!;& !!8& !!M& !:M"!;#& !;8& !;@& !#:& !#;& !#5& !#8& !58& !85"!8L& !L9& !L5& !L8& !L@& !LM& !@:& !M9& !ML& :9#":98& :!;":!5& :!L"::9& :::& ::#& ::5& :8:& :8#":88& :LM& :@!& :M5

:#5& :#L& :5!& :5:& :55& :5L& :5@& :89& :LL& :L@& :@9& :@!& :@5& :@@& :@M& :M5 -ortal.properties........#8& !9@& !#@& :#5& :5!& :5:& :55& :5L& :5@& :@@

-ortlet. 5"!:& !5"!L& ::& #L& #@& 5@& 5M& LL"@!& @;& @#& @L& @M"M;& M5"!9!& !!:"!!8& !!M"!::& !:#"!;5& !;L"!#;& !#5"!#L& !#M"!58& !8:& !85& !L:"!L5& !LM& !@9& !@5& !@@"!M!& !M;" !ML& :9:":9M& :!!& :!;":#8& :58& :5@":8!& *emory....M& ;!& ;8& !!L& !5@& !L#& !@8& :9!& :8;":85& :8L& :L!& :L:& :L@& :LM& :@!& :@#& :@5& :@L& :@M":M5& :ML :!!& :5@& :5M& :L#& :L5& :LL *essage boards....5& @& !:& M!& M:& !99& !!;& -ortlet.xml........!5!& !5;& !L:& !L;& !M5& :9L& :L@& :M! !!M"!:!& !;;"!#:& !#8& :!M& :58& :5@ *y -laces................................@& LM& @9& ::9

*ysJl.....:8& :L& :M& ;9& ;:";5& ;L& ;M"#!& #;& 2elease.properties..................................:L; #5"5!& 5#& 58& 5L& 5M& 8@& L!"L;& !5M& !89& 2eJuest...8& L& 55& @#& M9& !!#& !88& !L!"!L;& :99& :5:& :55& :5M& :L@":@9& :@5 !@!& !@:& !@5& !@8& !M#"!M8& :95& :!9& :!!& :!5& :!8& :!@& :!M& ::!& :::& ::5& :5;":55& N :89& :85& :L!& :L:& :L5& :L@& :M!& :M#& :ML& Navigation....@& !!;& !#5& !8#& !M@& ::9& ::!& ;9:& ;9;& ;95 :M8 2esin...................;& :#& #L"59& !5!& !5:& :L; Ntlm..........#& 8& !!9& !LL& !L@& !@:& :!9& :L@ 2oles....#& 8& M& ;@& #9& LL& @!"@@& M9& M:& M@" !99& !9:& !!:"!!#& !!8& !!M& !:!& !:8& !;9& 1 !;5& !#:& !8L"!8M& !@#& !@5& :9:& ::;& ::@& <c#0............................................;& #:& ##"#8 :5M& :8!& :85& :L8 <pen%d.............................#& 8& !!!& !L@& !@: <pen((<...................#& 8& !!!& !!:& !L@& !@:

(chema.................8& !#M& !5;& :5#& :5M& :8! <rgani,ations. #& 8& !8& !M& :;& LL& @!"@#& @L" M9& !!8& !:9& !8L& !8M& !L9& !@#& !M@& :98& (ervice .uilder.............8& !55& :##& :@@& :@M ::9& ::8& :;L& :#8& :L:& :@;& :@#& :M5 (ervices <riented +rchitecture............@& :## (ervlet.......L& M& !5& :#& ;8& ;L& L@& !#@& !#M& !5!& !88& !L;& !L#& !LL& !@:& !@8& !M#& :9@& -asswords....8& !9!& !9@& !L5& !LM& !@;& !@#& :!9":!;& :!8& :!@& ::!& :::& ::5& ::8& :#5& :L@& :M!& :M8& :ML :#8

-erformance Tuning............................M& :L# (ession....8& :5";9& ;:& ;;& ;5& ;@"#:& #5& #8& #@& 5!& 5;& 55& 5L& 5@& 8;& 88& 8@& L;& L#& -ermissions. . .#"8& !5& !8& :;& :#& @:& @;& @5" !!;& !58& !5L& !8#& !85& !L:"!L#& !@!& !@:& @L& M:& M@"!9:& !!#& !:9& !:!& !:8& !;9& !;5& !@5& !@8& !M5& :9#":98& :9M":!!& :M8 !;M& !#!& !#:& !#5& !@#& !@5& !M#& :#9& :#5& (hopping...............@& !;;& !@!& !ML& ::!& ::: :5M& :L9& :@L& :M9 -lugin....;& #& 8& @& !L& :9& :;& :#& :L& #L& L@& (ingle sign"on. #& @#& !9:& !95& !9M"!!:& !!8& @!& !9!& !!;& !!8& !!L& !;:& !#L& !5:& !5;& ::L& :L@ !MM& ::5":#9& :#:":##& :5!& :5;":58& :89& (ite*inder........#& 8& !!:& !L@& !LM& !@:& !@L :85& :@#& :@8& :@L& :M!& :M;& :M5& :M8 (*T-....:8& :L& ;9& ;;& ;5& ;@& ;M& #!& #:& #5& -ortal"ext.properties. .;& 5& :;& :5":@& ;9& ;;& #@& 5!& 55& 5L& 5@& 8@& L;& @5& !;;& !;8& :9#" ;M& #!& #5& #8& 5#& 5L& 8L& L;& L#& M;& !9;& :98 !9L& !9@& !!:& !;!& !##& !#L& !#@& :;!":;5& (ocial .ookmarks................................L& :9@ 8A!

(oftware catalog.....@& :::& :;8":#9& :#:":## Cirtual 4ost.....L& 88& !9:& !!8& :9M& :!!& :L@ (olr...........................................!!#& :5;":58 (pring. .8& L& !L& !55"!5@& !89& :!:& ::8& :#5& 'ar file. :9& :L& :@& ;9& ;;";8& ;@& #9& #!& ##& :5#& :LM& :@!& ;9L 5#& 5@& 8M& L;& L#& ::5& :;9& :;:& :;#& :;5& (KL......8& :9& :#":L& :M& ;9& ;:";5& ;L& ;M"#!& :;@& :#;& :5;& :58& :@@ #;"5!& 5#& 58& 5L& 5M& 8@& L!"L;& !5@"!89& !8#& !85& :99& :5!& :5:& :55& :5M& :8!& :8:& 'E."%NN....;5& #!& #8& 59& !9M& !#@& :;!& :;;& :5#& :5L& :89& :8!& :85& :8@& :L:& :M;& :M5& :L@":@9& :@5 :M8 ((< with *+).....................................8& !@: 'eb.xml......;8& !5!& !55& !L:& !LL& !L@& !M#& (wimlane...........................:8!":8;& :88& :L9 :;#& :L@& :M8

'ebD+C...................L& !L& :!!":!;& :!8& :#5

Tags....@& ;M& L#& M9& !##& !#8& !8#& !@!& !M#& 'ebLogic........;& :9& 5:"5@& L#& !5!& !5@& :;: :::& ::;& ::8& :;M& :#;& :M! 'ebsphere..;& :9& 5@& 5M& 8L"8M& L;& L#& !5!& Theme......8& @& !9& !8& ::& L@& !!;& !!8& !##& :;;":;5 !#L& !59& !5:"!55& !8!& !L:& !@@"!M9& !M@& 'iki. 5& @& M& !:& !;& 5M& @!& M!& !!M& !#!"!#8& :9@& :!8& ::5& ::8& ::M":;!& :;#& :;8& :;M& !@!& !@:& !ML& :9;& :9#& ::;"::5& :@@& :@M& :58& :LL& :@;& :@#& :@L& :M!":M;& :M5& :M8 ;9L Time ,one.....................8& !!;& !;9& !L9& !L! 'orkflow....;& M& !8& !55& :9;& ::L& :#M& :59& Tomcat.....;& !M":!& :#& 59"5:& !9M& !!9& !59" :5M":8;& :85":8@& :L!& :L: !5:& !L#& !@8& :;!& :;:& :;5& :;8& :#L& :5;& '(DL...................................................@& :#L :5L& :L;& :M9& :M5

/ml....;!& ;#"#!& #@& 59"5:& L#& !5!"!5@& !89& Opgrade. .8& M"!!& :;& :#& !#M& !59& :;8& :;L& !L:& !L;& !LL& !L@& !@!& !M#"!M8& :9#& :9L& :#!& :5#& :@L":M9& :M;":M8 :!9& :!8& :!@& :;#& :;8& :;L& :#:":##& :5:& Oser groups...#& LL& @!"@#& @L& M:& M;& M5"M@& :5#& :5L":88& :8@& :L!& :L:& :L@& :LM& :@!& :@M":M!& :M;& :M5& :M8 !9:& !!:& !!8 Osers.....#"L& M& !!"!;& !5& !8& :!& :5& ;@& #9& D 59& L#& LL& LM"M;& M5"!!;& !!5"!!L& !!M& !::" !:@& !;9"!#:& !##& !#8& !8!& !8#"!LL& !LM" Pip. .:!& ::& :#& :5& ;@& #9"#:& #@"59& 5:& :!9& !@!& !@#& !@5& !@L"!M9& !M#& !M5& !ML& !MM& :!8& ::M& :M;& :M8 :9:& :9#& :95& :!9& :!8& ::9& ::8& ::M& :;8" :;@& :#9& :#!& :#;":#8& :5!& :55& :58& :5@& :5M& :8!& :8:& :8L& :L!& :L:& :L@":@9& :@#& .!;& :M& ;:& ;L& #9& #@& 5!& 8;& !#M"!5;& !58" :@M !5@& !85"!8M& !L:"!L#& !L8"!@!& !@;"!@M& !M:& !M#& !M5& !ML& :99":9;& :9@& :!!":!;& > :!5":!M& ::!"::5& :;;& :#L& :5:& :58":5@& Celocity............L& !L& :9@& :9M& :!!& :!L":!M :8:& :85& :88& :L9& :L:& :L;& :@M":M!& :M;& :M#& ;99& ;9@

8A8

You might also like