From portal-commits at lists.jboss.org Tue Jul 13 21:46:04 2010
Content-Type: multipart/mixed; boundary="===============0041630524224032913=="
MIME-Version: 1.0
From: portal-commits at lists.jboss.org
To: portal-commits at lists.jboss.org
Subject: [portal-commits] JBoss Portal SVN: r13959 - in
docs/enterprise/trunk/PortletBridge: en-US and 1 other directory.
Date: Tue, 13 Jul 2010 21:46:04 -0400
Message-ID: <201007140146.o6E1k4g7010826@svn01.web.mwc.hst.phx2.redhat.com>
--===============0041630524224032913==
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: quoted-printable
Author: smumford
Date: 2010-07-13 21:46:03 -0400 (Tue, 13 Jul 2010)
New Revision: 13959
Added:
docs/enterprise/trunk/PortletBridge/publican.cfg
Removed:
docs/enterprise/trunk/PortletBridge/Makefile
Modified:
docs/enterprise/trunk/PortletBridge/en-US/Author_Group.xml
docs/enterprise/trunk/PortletBridge/en-US/Book_Info.xml
docs/enterprise/trunk/PortletBridge/en-US/Configuration.xml
docs/enterprise/trunk/PortletBridge/en-US/Feedback.xml
docs/enterprise/trunk/PortletBridge/en-US/Getting_Started.xml
docs/enterprise/trunk/PortletBridge/en-US/JBoss_Portlet_Bridge_Overview.=
ent
docs/enterprise/trunk/PortletBridge/en-US/JBoss_Portlet_Bridge_Overview.=
xml
docs/enterprise/trunk/PortletBridge/en-US/Overview.xml
docs/enterprise/trunk/PortletBridge/en-US/Portlet_Development.xml
docs/enterprise/trunk/PortletBridge/en-US/Preface.xml
docs/enterprise/trunk/PortletBridge/en-US/Revision_History.xml
Log:
JBEPP-376: Updated for 4.3 CP05 Release
Deleted: docs/enterprise/trunk/PortletBridge/Makefile
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- docs/enterprise/trunk/PortletBridge/Makefile 2010-07-09 02:29:28 UTC (r=
ev 13958)
+++ docs/enterprise/trunk/PortletBridge/Makefile 2010-07-14 01:46:03 UTC (r=
ev 13959)
@@ -1,13 +0,0 @@
-#Makefile for portletOverview
-
-XML_LANG =3D en-US
-BRAND =3D JBoss
-
-#OTHER_LANGS =3D as-IN bn-IN de-DE es-ES fr-FR gu-IN hi-IN it-IT ja-JP kn-=
IN ko-KR ml-IN mr-IN or-IN pa-IN pt-BR ru-RU si-LK ta-IN te-IN zh-CN zh-TW
-OTHER_LANGS =3D ja-JP =
-# Extra Parameters start here
-
-# Extra Parameters stop here
-COMMON_CONFIG =3D /usr/share/publican
-include $(COMMON_CONFIG)/make/Makefile.common
-
Modified: docs/enterprise/trunk/PortletBridge/en-US/Author_Group.xml
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- docs/enterprise/trunk/PortletBridge/en-US/Author_Group.xml 2010-07-09 0=
2:29:28 UTC (rev 13958)
+++ docs/enterprise/trunk/PortletBridge/en-US/Author_Group.xml 2010-07-14 0=
1:46:03 UTC (rev 13959)
@@ -1,11 +1,11 @@
-
Red Hat
-
+
+
=
Modified: docs/enterprise/trunk/PortletBridge/en-US/Book_Info.xml
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- docs/enterprise/trunk/PortletBridge/en-US/Book_Info.xml 2010-07-09 02:2=
9:28 UTC (rev 13958)
+++ docs/enterprise/trunk/PortletBridge/en-US/Book_Info.xml 2010-07-14 01:4=
6:03 UTC (rev 13959)
@@ -1,36 +1,38 @@
+
+ JBoss Portlet Bridge Overview
+ For use with JBoss Enterprise Portal Platform 4.3
+ JBoss Portlet Bridge
+ 6
+ 1.0
+ 5
+ Jul, 2010
+
+
+ The JBoss Portlet Bridge is an implementation of the JSR-301 specificat=
ion to support JSF within a portlet and with added enhancements to support =
other web frameworks. Currently the bridge supports any combination of JSF,=
Seam, and RichFaces to run inside a portlet.
+
+
+
+
+
+
+
+
+ Logo
+
=
-
- Overview
- For use with JBoss Enterprise Portal Platform 4.3
- JBoss Portlet Bridge Beta
- 6
- 1.0
- 5
- Jan, 2009
-
- The JBoss Portlet Bridge is an implementation of the JSR-301
-specification to support JSF within a portlet and with added
-enhancements to support other web frameworks. Currently the bridge
-supports any combination of JSF, Seam, and RichFaces to run inside
-a portlet.
-
-
-
-
-
-
- Logo
-
-
-
-
- &YEAR;
- &HOLDER;
-
-
-
-
- =
+
+
+
+
+ &YEAR;
+ &HOLDER;
+
+
+
+
+
+
+
Modified: docs/enterprise/trunk/PortletBridge/en-US/Configuration.xml
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- docs/enterprise/trunk/PortletBridge/en-US/Configuration.xml 2010-07-09 =
02:29:28 UTC (rev 13958)
+++ docs/enterprise/trunk/PortletBridge/en-US/Configuration.xml 2010-07-14 =
01:46:03 UTC (rev 13959)
@@ -1,277 +1,296 @@
-
-
+
Bridge Configuration
-
+
The 301 specification is aimed at making the developer's life as eas=
y as possible when developing with JSF+Portlet. You will see below that the=
re are minimal settings to getting any JSF web application up and running i=
n the Portal environment.
-
+
Core Setup and Configuration
-
+
portlet.xml
-
+
The basic JSR-301 portlet configuration.
- =
+ =
- <portlet>
- <portlet-name>yourPortletName</portlet-name>
- <portlet-class>
+ <portlet>
+ <portlet-name>yourPortletName</portlet-name>
+ <portlet-class>
javax.portlet.faces.GenericFacesPortlet
- </portlet-class>
+ </portlet-class>
=
- <init-param>
- <name>javax.portlet.faces.defaultViewId.view</name>
- <value>/welcome.xhtml</value>
- </init-param>
+ <init-param>
+ <name>javax.portlet.faces.defaultViewId.view</name=
>
+ <value>/welcome.xhtml</value>
+ </init-param>
=
- <init-param>
- <name>javax.portlet.faces.defaultViewId.edit</name>
- <value>/jsf/edit.xhtml</value>
- </init-param>
+ <init-param>
+ <name>javax.portlet.faces.defaultViewId.edit</name=
>
+ <value>/jsf/edit.xhtml</value>
+ </init-param>
=
- <init-param>
- <name>javax.portlet.faces.defaultViewId.help</name>
- <value>/jsf/help.xhtml</value>
- </init-param>
+ <init-param>
+ <name>javax.portlet.faces.defaultViewId.help</name=
>
+ <value>/jsf/help.xhtml</value>
+ </init-param>
-
- When preserveActionParams is set to TRUE, the bridge must maintain any=
request parameters assigned during the portlet's action request. The r=
equest parameters are maintained in the"bridge r=
equest scope". When this attribute is not present or is FALSE th=
e action's request parameters are only maintained for the duration of t=
he portlet request scope.
+
+ When preserveActionParams is set to TRUE, the bridge must maintain any=
request parameters assigned during the portlet's action request. The r=
equest parameters are maintained in the"brid=
ge request scope". When this attribute is not present or is =
FALSE the action's request parameters are only maintained for the durat=
ion of the portlet request scope.
- =
+ =
- <init-param>
- <name>javax.portlet.faces.preserveActionParams</name>
- <value>true</value>
- </init-param>
+ <init-param>
+ <name>javax.portlet.faces.preserveActionParams</name&=
#62;
+ <value>true</value>
+ </init-param>
+
=
-
+
faces-config.xml
-
+
The PortletViewHandler ensures that each JSF portlet instance is porpe=
rly namespaced.
- =
+ =
- <faces-config>
- <application>
- <view-handler>
+ <faces-config>
+ <application>
+ <view-handler>
org.jboss.portletbridge.application.PortletViewHandler
- </view-handler>
- <state-manager>org.jboss.portletbridge.application.Po=
rtletStateManager</state-manager>
- </application>
+ </view-handler>
+ <state-manager>org.jboss.portletbridge.application.=
PortletStateManager</state-manager>
+ </application>
...
+
=
-
+
Facelets Configuration
-
+
The following web.xml setting is only for Facelets based applications
-
+
web.xml
- =
+ =
- <web-app xmlns=3D"http://java.sun.com/xml/ns/j2ee"
- xmlns:xsi=3D"http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation=3D"http://java.sun.com/xml/ns/j2ee htt=
p://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
- version=3D"2.4">
+ <web-app xmlns=3D"http://java.sun.com/xml/ns/j2ee"
+ xmlns:xsi=3D"http://www.w3.org/2001/XMLSchema-instanc=
e"
+ xsi:schemaLocation=3D"http://java.sun.com/xml/ns/j2ee=
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
+ version=3D"2.4">
...
- <!-- This is optional parameters for a facelets based appli=
cation -->
- <context-param>
- <param-name>org.ajax4jsf.VIEW_HANDLERS</param-nam=
e>
- <param-value>org.jboss.portletbridge.application.Fac=
eletPortletViewHandler</param-value>
- </context-param>
+ <!-- This is optional parameters for a facelets based appl=
ication -->
+ <context-param>
+ <param-name>org.ajax4jsf.VIEW_HANDLERS</param-=
name>
+ <param-value>org.jboss.portletbridge.application.F=
aceletPortletViewHandler</param-value>
+ </context-param>
- =
+ =
- <context-param>
- <param-name>javax.portlet.faces.renderPolicy</par=
am-name>
- <param-value>
+ <context-param>
+ <param-name>javax.portlet.faces.renderPolicy</=
param-name>
+ <param-value>
ALWAYS_DELEGATE
- </param-value>
- </context-param>
+ </param-value>
+ </context-param>
...
- </web-app>
+ </web-app>
-
+
RenderPolicy Options
-
+
ALWAYS_DELEGATE Indicates the bridge should not=
render the view itself but rather always delegate the rendering.
+
-
+
NEVER_DELEGATE Indicates the bridge should alwa=
ys render the view itself and never delegate.
+
-
+
DEFAULT Directs the bridge to first delegate th=
e render and if (and only if) an Exception is thrown then to render the vie=
w based on its own logic. If the configuration parameter is not present or =
has an invalid value the bridge renders using the default behavior i.e. as =
though DEFAULT were set.
+
+
+
+
+ =
=
=
-
+
JSP Only Configuration
-
+
The following web.xml setting is only for JSP based applications
-
+
web.xml
- =
+ =
- <web-app xmlns=3D"http://java.sun.com/xml/ns/j2ee"
- xmlns:xsi=3D"http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation=3D"http://java.sun.com/xml/ns/j2ee htt=
p://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
- version=3D"2.4">
+ <web-app xmlns=3D"http://java.sun.com/xml/ns/j2ee"
+ xmlns:xsi=3D"http://www.w3.org/2001/XMLSchema-instanc=
e"
+ xsi:schemaLocation=3D"http://java.sun.com/xml/ns/j2ee=
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
+ version=3D"2.4">
=
- <context-param>
- <param-name>javax.portlet.faces.renderPolicy</par=
am-name>
- <param-value>
+ <context-param>
+ <param-name>javax.portlet.faces.renderPolicy</=
param-name>
+ <param-value>
NEVER_DELEGATE
- </param-value>
- </context-param>
+ </param-value>
+ </context-param>
...
- </web-app>
+ </web-app>
+
+ =
=
=
-
+
JSR-301
-
+
The Jboss Portlet Bridge can be used with a any compatible implementat=
ion (for example, MyFaces implementation). Simply put the following into we=
b.xml :
- =
+ =
=
- <context-param>
- <param-name>javax.portlet.faces.BridgeImplClass</param-na=
me>
- <param-value>org.apache.myfaces.portlet.faces.bridge.BridgeI=
mpl</param-value>
- </context-param>
+ <context-param>
+ <param-name>javax.portlet.faces.BridgeImplClass</param=
-name>
+ <param-value>org.apache.myfaces.portlet.faces.bridge.Bridg=
eImpl</param-value>
+ </context-param>
+
+ =
=
=
-
-
+
RichFaces Setup and Configuration Options
-
+
Please be aware that RichFaces integration is a technology preview and=
hence is currently unsupported.
+
-
+
web.xml
-
+
The following configuration is designated for portlets using the RichF=
aces library. These settings will vary based on your individual needs. See =
this section of the RichFaces documentation for mor=
e details.
- =
+ =
- <context-param>
- <param-name>org.richfaces.LoadStyleStrategy</para=
m-name>
- <param-value>NONE</param-value>
- </context-param>
- <context-param>
- <param-name>org.richfaces.LoadScriptStrategy</par=
am-name>
- <param-value>NONE</param-value>
- </context-param>
+ <context-param>
+ <param-name>org.richfaces.LoadStyleStrategy</p=
aram-name>
+ <param-value>NONE</param-value>
+ </context-param>
+ <context-param>
+ <param-name>org.richfaces.LoadScriptStrategy</=
param-name>
+ <param-value>NONE</param-value>
+ </context-param>
-
+
The org.ajax4jsf.RESOURCE_URI_PREFIX configuration =
cross references a setting in your jboss-portlet.xml f=
ile (see below). These settings are required for RichFaces.
- =
+ =
- <context-param>
- <param-name>org.ajax4jsf.RESOURCE_URI_PREFIX</par=
am-name>
- <param-value>rfRes</param-value>
- </context-param>
+ <context-param>
+ <param-name>org.ajax4jsf.RESOURCE_URI_PREFIX</=
param-name>
+ <param-value>rfRes</param-value>
+ </context-param>
=
- <filter>
- <display-name>Ajax4jsf Filter</display-name>
- <filter-name>ajax4jsf</filter-name>
- <filter-class>org.ajax4jsf.Filter</filter-class&g=
t;
- </filter>
+ <filter>
+ <display-name>Ajax4jsf Filter</display-name=
2;
+ <filter-name>ajax4jsf</filter-name>
+ <filter-class>org.ajax4jsf.Filter</filter-clas=
s>
+ </filter>
=
- <filter-mapping>
- <filter-name>ajax4jsf</filter-name>
- <servlet-name>FacesServlet</servlet-name>
- <dispatcher>FORWARD</dispatcher>
- <dispatcher>REQUEST</dispatcher>
- <dispatcher>INCLUDE</dispatcher>
- </filter-mapping>
+ <filter-mapping>
+ <filter-name>ajax4jsf</filter-name>
+ <servlet-name>FacesServlet</servlet-name>
+ <dispatcher>FORWARD</dispatcher>
+ <dispatcher>REQUEST</dispatcher>
+ <dispatcher>INCLUDE</dispatcher>
+ </filter-mapping>
...
- </web-app>
+ </web-app>
+
=
-
+
jboss-portlet.xml
-
- To avoid scripts loading more than once from different portlet windows=
you can define additional scripts in jboss-portlet.xml. *Note the "rfRes" =
URI prefix that is mapped in the web.xml.
+
+ To avoid scripts loading more than once from different portlet windows=
you can define additional scripts in jboss-portlet.xml. *Note the "rfR=
es" URI prefix that is mapped in the web.xml.
- =
+ =
- <portlet>
- <portlet-name>ajaxPortlet</portlet-name>
- <header-content>
- <script src=3D"/faces/rfRes/org/ajax4jsf/framework.pack.js"=
type=3D"text/javascript"></script>
- <script src=3D"/faces/rfRes/org/richfaces/ui.pack.js" type=
=3D"text/javascript"></script>
- <link rel=3D"stylesheet" type=3D"text/css" href=3D"/faces/r=
fRes/org/richfaces/skin.xcss"/>
- </header-content>
- </portlet>
+ <portlet>
+ <portlet-name>ajaxPortlet</portlet-name>
+ <header-content>
+ <script src=3D"/faces/rfRes/org/ajax4jsf/framework.pac=
k.js" type=3D"text/javascript"></script>
+ <script src=3D"/faces/rfRes/org/richfaces/ui.pack.js=
34; type=3D"text/javascript"></script>
+ <link rel=3D"stylesheet" type=3D"text/css"=
href=3D"/faces/rfRes/org/richfaces/skin.xcss"/>
+ </header-content>
+ </portlet>
+
+ =
=
=
-
+
Seam Setup and Configuration Options
-
+
Please be aware that Seam integration is a technology preview and henc=
e is currently unsupported.
+
-
+
Configuration
-
+
The ExceptionHandler is used to clean Seam contexts and transactions a=
fter errors.
- =
+ =
- <context-param>
- <param-name>org.jboss.portletbridge.ExceptionHandler</pa=
ram-name>
- <param-value>
+ <context-param>
+ <param-name>org.jboss.portletbridge.ExceptionHandler<=
/param-name>
+ <param-value>
org.jboss.portletbridge.SeamExceptionHandlerImpl
- </param-value>
- </context-param>
+ </param-value>
+ </context-param>
-
+
Earlier 2.0.x versions of Seam portlets must have the LIFECYCLE_ID set=
to SEAM_PORTLET in the web.xml file. This setting allows the bridge to rep=
lace the original Seam phase listener during the faces life-cycle addPhaseL=
isteners. This setting is not needed for Seam portlets version 2.1.x and up.
- =
+ =
- <context-param>
- <param-name>javax.faces.LIFECYCLE_ID</param-name>
- <param-value>SEAM_PORTLET</param-value>
- </context-param>
+ <context-param>
+ <param-name>javax.faces.LIFECYCLE_ID</param-name>
+ <param-value>SEAM_PORTLET</param-value>
+ </context-param>
+
+ =
=
+ =
=
=
Modified: docs/enterprise/trunk/PortletBridge/en-US/Feedback.xml
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- docs/enterprise/trunk/PortletBridge/en-US/Feedback.xml 2010-07-09 02:29=
:28 UTC (rev 13958)
+++ docs/enterprise/trunk/PortletBridge/en-US/Feedback.xml 2010-07-14 01:46=
:03 UTC (rev 13959)
@@ -1,21 +1,15 @@
-
-
+
We Need Feedback!
-
+
feedback
- contact information for this manual
+ contact information for this manual
+
-
- If you find a typographical error in this manual, or if you have thought=
of a way to make this manual
- better, we would love to hear from you! Submit a report in JIRA
- against the Version: &JBEPPVERS;, Component: Documentation.
- When submitting a bug report, be sure to mention the manual's identifier=
: Portal_User_Guide
- If you have a suggestion for improving the documentation, try to be as s=
pecific as possible when
- describing it. If you have found an error, please include the section nu=
mber and some of the
- surrounding text so we can find it easily.
+
+ If you find a typographical error in this manual, or if you have thought=
of a way to make this manual better, we would love to hear from you! Submi=
t a report in JIRA=
ulink> against the Version: &JBEPPVERS;, Component: Documentation. When submitting a bug report, be sure to =
mention the manual's identifier: Portal_User_Guide If you have a sugges=
tion for improving the documentation, try to be as specific as possible whe=
n describing it. If you have found an error, please include the section num=
ber and some of the surrounding text so we can find it easily.
=
Modified: docs/enterprise/trunk/PortletBridge/en-US/Getting_Started.xml
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- docs/enterprise/trunk/PortletBridge/en-US/Getting_Started.xml 2010-07-0=
9 02:29:28 UTC (rev 13958)
+++ docs/enterprise/trunk/PortletBridge/en-US/Getting_Started.xml 2010-07-1=
4 01:46:03 UTC (rev 13959)
@@ -1,107 +1,121 @@
-
-
+
Getting started with JBoss Portlet Bridge
-
+
JBoss Portlet Bridge not only gives you the ability to run JSF web appli=
cations in a portlet, but also gives you the benefit of running supported J=
Boss frameworks like Seam and RichFaces.
-
+
Bridge Frameworks and Extensions
-
+
The JBoss Portlet Bridge project is also actively developing extensions=
, or Bridgelets, that enhance or bring together features of JBoss Portal, S=
eam, and Richfaces. For example, the PortalIdentity seam component allows y=
ou to drop the jar in your classpath and you instantly have SSO between Sea=
m and Portal. This extension can also be configured with additional attribu=
tes in your Seam application's components.xml file. =
Don't forget that the bridge is still in Beta and so are any exte=
nsions. If you would like to contribute to any part of this project, we enc=
ourage you to participate on the user forum and brin=
g issues/enhancements to our attention.
+
+
-
-
+
+
Available Bridgelets
-
+
-
-
-
-
+
+
+
+
Bridgelet
-
+
Command
+
+
-
+
Single Sign On
-
+
By including the following dependency in your web pom, you will a=
utomatically enable SSO between JBoss Portal and your Seam 2.1.1.GA applica=
tion. =
-<dependency>
- <groupId>org.jboss.portletbridge.extensions.seam</groupId>
- <artifactId>PortalIdentity</artifactId>
- <version>1.0.0.CR2</version>
-</dependency>
+<dependency>
+ <groupId>org.jboss.portletbridge.extensions.seam</groupId=
62;
+ <artifactId>PortalIdentity</artifactId>
+ <version>1.0.0.CR2</version>
+</dependency>
+
+
+
+
+
+
+
+
=
-
+
Before you start
-
+
Current version and compatibility information can be easily located on =
the JBoss Portl=
et Bridge wiki. Ensure you are using compatible versions of all int=
egrated frameworks before you begin.
-
+
JBoss Portal provides its latest distribution with the JBoss Applicatio=
n Server. All of the guesswork has been eliminated so that you can unzip an=
d run Portal with a few clicks. Get the latest version here (ensure you ch=
oose the JBoss Portal + JBoss AS link)
-
- Next, all that's left is to download the JBoss Portlet Bridge distribution=
and configure your portlet to use the bridge. Or, you can run a provided a=
rchetype and deploy the generated W=
AR in a few easy steps. This will also give you an empty project to play ar=
ound with or start from scratch.
+
+ Next, all that's left is to download the JBoss Portlet Bridge distribution=
and configure your portlet to use the bridge. Or, you can run a provided a=
rchetype and deploy the generated WAR in a few easy step=
s. This will also give you an empty project to play around with or start fr=
om scratch.
-
+
For system requirements and setting up your JBoss Portal environment se=
e the reference guide.
+
=
-
- Maven Archetypes =
-
+
+ Maven Archetypes
+
The JBPB project utilizes Maven archetypes whic=
h allow you get up and running with different flavors of the bridge quickly=
. =
-
+
Available Archetypes
-
+
-
-
-
-
+
+
+
+
Archetype
-
+
Command
+
+
-
+
JSF 1.2 Basic
-
+
=
mvn archetype:generate
-DarchetypeGroupId=3Dorg.jboss.portletbridge.archetypes
@@ -111,13 +125,15 @@
-DartifactId=3Dmyprojectname
-DarchetypeRepository=3Dhttp://repository.jboss.org/maven2/
+
+
-
+
RichFaces Basic
-
+
=
mvn archetype:generate
-DarchetypeGroupId=3Dorg.jboss.portletbridge.archetypes
@@ -127,13 +143,15 @@
-DartifactId=3Dmyprojectname
-DarchetypeRepository=3Dhttp://repository.jboss.org/maven2/
+
+
-
+
Seam Basic (Modular EAR)
-
+
=
mvn archetype:generate
-DarchetypeGroupId=3Dorg.jboss.portletbridge.archetypes
@@ -143,30 +161,36 @@
-DartifactId=3Dseamproject
-DarchetypeRepository=3Dhttp://repository.jboss.org/maven2/
+
+
+
+
+
+
-
+
Running the Examples
-
- JSF 1.2 Basic, RichFaces Basic, Seam Basic, and=
other demos
+
+ JSF 1.2 Basic, RichFaces Basic, Seam Basic, an=
d other demos
-
- Each example application is configured to download the latest version =
of JBoss Portal bundled with JBoss Application Server. After running the ar=
chetype or downloading the source code for=
the example application that you are interested in, you can run one of the=
following Maven profiles to save time and get everything up and running wi=
th only 2 commands.
+
+ Each example application is configured to download the latest version =
of JBoss Portal bundled with JBoss Application Server. After running the ar=
chetype or downloading the source code for the example applicat=
ion that you are interested in, you can run one of the following Maven prof=
iles to save time and get everything up and running with only 2 commands.
-
+
JBoss Portal 2.7.2.GA + JBoss AS 4.2.3 (Bundle=
d)
- =
+ =
mvn install -Plocal-portal cargo:start
mvn cargo:deploy -Plocal-portal
visit http://localhost:8080/portal
-
-
+ -->
Time Saving Tips
-
+
If you plan on using the cargo profiles to d=
o active development, you can save a lot of time by not downloading the bun=
dle each time you do a clean install. To use a locally configured server bu=
ndled with portal, use the following command line parameters. The variable =
for JBOSS_HOME_DIR is related to how you zip the server directory. If you z=
ip the files under JBOSS_HOME/* then it will only be the name of your archi=
ve. But if you zip the actual folder JBOSS_HOME then JBOSS_HOME_DIR must be=
defined as 'zip file name/JBOSS_HOME folder name'.
- =
-
+ -->
+ =
=
+ =
=
=
Modified: docs/enterprise/trunk/PortletBridge/en-US/JBoss_Portlet_Bridge_Ov=
erview.ent
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- docs/enterprise/trunk/PortletBridge/en-US/JBoss_Portlet_Bridge_Overview=
.ent 2010-07-09 02:29:28 UTC (rev 13958)
+++ docs/enterprise/trunk/PortletBridge/en-US/JBoss_Portlet_Bridge_Overview=
.ent 2010-07-14 01:46:03 UTC (rev 13959)
@@ -1,4 +1,5 @@
-
-
-
+
+
+
+
Modified: docs/enterprise/trunk/PortletBridge/en-US/JBoss_Portlet_Bridge_Ov=
erview.xml
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- docs/enterprise/trunk/PortletBridge/en-US/JBoss_Portlet_Bridge_Overview=
.xml 2010-07-09 02:29:28 UTC (rev 13958)
+++ docs/enterprise/trunk/PortletBridge/en-US/JBoss_Portlet_Bridge_Overview=
.xml 2010-07-14 01:46:03 UTC (rev 13959)
@@ -1,14 +1,13 @@
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
=
Modified: docs/enterprise/trunk/PortletBridge/en-US/Overview.xml
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- docs/enterprise/trunk/PortletBridge/en-US/Overview.xml 2010-07-09 02:29=
:28 UTC (rev 13958)
+++ docs/enterprise/trunk/PortletBridge/en-US/Overview.xml 2010-07-14 01:46=
:03 UTC (rev 13959)
@@ -1,61 +1,48 @@
-
-
+
JBoss Portlet Bridge Overview
- =
-
- As part of the support contract, only JSF applications are support=
ed and
- should be used in production.
- Seam and RichFaces portlets are provided here as technology preview, at =
this
- stage it is recommended to not use those in prod=
uction.
- Work is being done to support those two technologies. In the meantime it=
is
- encouraged to try those during development to report any issue in our co=
mmunity
- forums to help mature the integration. =
-
- =
-
- This project is marked as 'Beta' since the JSR-301 specificatio=
n is not final
- at the time of release and because support for RichFaces and Seam nee=
d to mature.
- As part of the professional support the API will not change for JSF p=
ortlets during
- the lifetime of the Enterprise Portal Platform to guarantee that no i=
ssue will
- arise during an upgrade.
- Again JSF applications are fully supported and can be
- used in production.
- Also note that the Maven archetypes may download binaries that are no=
t supported by
- the support contract.
- =
+
+
+ As part of the support contract, only JSF applications are supported an=
d should be used in production. Seam and RichFaces portlets are provided he=
re as technology preview, at this stage it is recommended to not use those in production. Work is being done to sup=
port those two technologies. In the meantime it is encouraged to try those =
during development to report any issue in our community forums to help matu=
re the integration.
+
+
+
+
+
+ This project is marked as 'Beta' since the JSR-301 specificatio=
n is not final at the time of release and because support for RichFaces and=
Seam need to mature. As part of the professional support the API will not =
change for JSF portlets during the lifetime of the Enterprise Portal Platfo=
rm to guarantee that no issue will arise during an upgrade. Again JSF appli=
cations are fully supported and can be used in production. Also note that t=
he Maven archetypes may download binaries that are not supported by the sup=
port contract.
+
+
- =
-
+
To get an idea of the JBoss Portlet Bridge community, the developers, an=
d for wiki resources, check out the project page.
-
+
What is the JBoss Portlet Bridge?
-
+
The JBoss Portlet Bridge (or JBPB for short) is an implementation of the=
JSR-301 speci=
fication which supports JSF within a portlet and with added enhancements, o=
ffers support of other web frameworks (such as Seam and RichFaces). It basically allows any Java developer to ge=
t started quickly with their JSF web application running in a portal enviro=
nment. The developer no longer needs to worry about the underlying portlet =
development, portlet concepts, or the API.
-
+
Understanding how JSF works with Portal
-
+
It is important to understand that the portlet bridge is not a portlet. =
Rather, it is the mediator between the two environments and allows JSF and =
Portal to be completely unaware of each other and live in their own seperat=
e worlds. The bridge is used to execute Faces requests on behalf of the por=
tlet. During each request, the Faces environment is set up and handled by t=
he bridge. Part of this implementation acts as a Faces controller much like=
how the FacesServlet does for direct client requests. The other part of th=
is implementation is provided by incorporating a variety of (standard) Face=
s extensions.
-
+ -->
=
Modified: docs/enterprise/trunk/PortletBridge/en-US/Portlet_Development.xml
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- docs/enterprise/trunk/PortletBridge/en-US/Portlet_Development.xml 2010-=
07-09 02:29:28 UTC (rev 13958)
+++ docs/enterprise/trunk/PortletBridge/en-US/Portlet_Development.xml 2010-=
07-14 01:46:03 UTC (rev 13959)
@@ -1,103 +1,108 @@
-
-
+
Developing Portlets with the Bridge
-
+
This chapter demonstrates common development tasks described by the 301 =
specification.
-
+
Excluding Attributes from the Bridge Request Scope
-
+
When your application uses request attributes on a per request basis an=
d you do not want that particular attribute to be managed in the extended b=
ridge request scope, you must use the following configuration in your faces=
-config.xml file. Below you will see that any attribute namespaced as foo.b=
ar or any attribute beginning with foo.baz (wildcard) will be excluded from=
the bridge request scope and only be used per that application's reque=
st.
- =
+ =
- <application>
- <application-extension>
- <bridge:excluded-attributes>
- <bridge:excluded-attribute>foo.bar</bridge:excl=
uded-attribute>
- <bridge:excluded-attribute>foo.baz.*</bridge:ex=
cluded-attribute>
- </bridge:excluded-attributes>
- </application-extension>
- </application>
+ <application>
+ <application-extension>
+ <bridge:excluded-attributes>
+ <bridge:excluded-attribute>foo.bar</bridge:e=
xcluded-attribute>
+ <bridge:excluded-attribute>foo.baz.*</bridge=
:excluded-attribute>
+ </bridge:excluded-attributes>
+ </application-extension>
+ </application>
+
=
-
+
Supporting PortletMode Changes
-
+
A PortletMode represents a distinct render path within an application. =
There are three standard modes: view, edit and help. The bridge's Exter=
nalContext.encodeActionURL recognizes the query string parameter javax.port=
let.faces.PortletMode and uses this parameter's value to set the portle=
t mode on the underlying portlet actionURL or response. Once processed it t=
hen removes this parameter from the query string. This means the following =
navigation rule causes one to render the edit.jspx viewId in the portlet ed=
it mode:
- =
+ =
- <navigation-rule>
- <from-view-id>/register.jspx</from-view-id>
- <navigation-case>
- <from-outcome>edit</from-outcome>
- <to-view-id>/edit.jspx?javax.portlet.faces.PortletMode=
=3Dedit</to-view-id>
- </navigation-case>
- </navigation-rule>
+ <navigation-rule>
+ <from-view-id>/register.jspx</from-view-id>
+ <navigation-case>
+ <from-outcome>edit</from-outcome>
+ <to-view-id>/edit.jspx?javax.portlet.faces.PortletMo=
de=3Dedit</to-view-id>
+ </navigation-case>
+ </navigation-rule>
+
=
-
+
Navigating to a mode's last viewId
-
- By default, a mode change will start in the mode's default view wit=
hout any (prior) existing state. One common portlet pattern when returning =
to the mode one left after entering another mode (e.g.. view -> edit -&g=
t; view) is to return to the last view (and state) of this origin mode. The=
bridge will explicitly encode the necessary information so that when retur=
ning to a prior mode it can target the appropriate view and restore the app=
ropriate state. The session attributes maintained by the bridge are intende=
d to be used by developers to navigate back from a mode to the last locatio=
n and state of a prior mode. As such a developer needs to describe a dynami=
c navigation: "from view X return to the last view of mode y". This is most=
easily expressed via an EL expression. E.g.
+
+ By default, a mode change will start in the mode's default view wit=
hout any (prior) existing state. One common portlet pattern when returning =
to the mode one left after entering another mode (e.g.. view -> edit -&=
#62; view) is to return to the last view (and state) of this origin mode. T=
he bridge will explicitly encode the necessary information so that when ret=
urning to a prior mode it can target the appropriate view and restore the a=
ppropriate state. The session attributes maintained by the bridge are inten=
ded to be used by developers to navigate back from a mode to the last locat=
ion and state of a prior mode. As such a developer needs to describe a dyna=
mic navigation: "from view X return to the last view of mode y". Th=
is is most easily expressed via an EL expression. E.g.
- =
+ =
- <navigation-rule>
- <from-view-id>/edit.jspx*</from-view-id>
- <navigation-case>
- <from-outcome>view</from-outcome>
- <to-view-id>#{sessionScope['javax.portlet.faces.vie=
wIdHistory.view']}</to-view-id>
- </navigation-case>
- </navigation-rule>
+ <navigation-rule>
+ <from-view-id>/edit.jspx*</from-view-id>
+ <navigation-case>
+ <from-outcome>view</from-outcome>
+ <to-view-id>#{sessionScope['javax.portlet.faces.v=
iewIdHistory.view']}</to-view-id>
+ </navigation-case>
+ </navigation-rule>
-
+
Note to Portlet Developers Depending on the bridg=
e implementation, when using values from these session scoped attributes or=
any viewIds which may contain query string parameters it may be necessary =
to use the wildcard syntax when identifying the rule target. For example, t=
he above =
-<to-view-id>
+<to-view-id>
expression returns a viewId of the form =
/viewId?javax.portlet.faces.PortletMode=3Dview&....
Without wildcarding, when a subsequent navigation occurs from this ne=
w view, the navigation rules wouldn't resolve because there wouldn'=
t be an exact match. Likewise, the above edit.jspx =
-<from-view-id>
+<from-view-id>
is wildcarded because there are navigation rules that target it that =
use a query string ( =
-<to-view-id> /edit.jspx?javax.portlet.faces.PortletM=
ode=3Dedit </to-view-id>
+<to-view-id> /edit.jspx?javax.portlet.faces.Portle=
tMode=3Dedit </to-view-id>
). Developers are encouraged to use such wildcards to ensure they exe=
cute properly in the broadest set of bridge implementations.
+
+
=
-
+
Custom Ajax Error Handling
-
+
By default, error handling is sent to a standard servlet page for Ajax =
requests. To handle the error inside the portlet, use the following javascr=
ipt:
- =
+ =
- <script type=3D"text/javascript">
+ <script type=3D"text/javascript">
A4J.AJAX.onError =3D function(req,status,message){
- window.alert("Custom onError handler "+message);
+ window.alert("Custom onError handler "+message);
}
=
A4J.AJAX.onExpired =3D function(loc,expiredMsg){
- if(window.confirm("Custom onExpired handler "+expiredMsg+" fo=
r a location: "+loc)){
+ if(window.confirm("Custom onExpired handler "+expired=
Msg+" for a location: "+loc)){
return loc;
} else {
return false;
}
}
- </script>
+ </script>
+
+ =
=
=
Modified: docs/enterprise/trunk/PortletBridge/en-US/Preface.xml
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- docs/enterprise/trunk/PortletBridge/en-US/Preface.xml 2010-07-09 02:29:=
28 UTC (rev 13958)
+++ docs/enterprise/trunk/PortletBridge/en-US/Preface.xml 2010-07-14 01:46:=
03 UTC (rev 13959)
@@ -1,12 +1,11 @@
-
-
+
Preface
-
-
-
-
+
+
+
+
=
Modified: docs/enterprise/trunk/PortletBridge/en-US/Revision_History.xml
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- docs/enterprise/trunk/PortletBridge/en-US/Revision_History.xml 2010-07-=
09 02:29:28 UTC (rev 13958)
+++ docs/enterprise/trunk/PortletBridge/en-US/Revision_History.xml 2010-07-=
14 01:46:03 UTC (rev 13959)
@@ -1,26 +1,31 @@
-
-
+
Revision History
-
+
- 1.0
-
-
-
-
-
+ 1.1
+ Wed 14 Jul 2010
+
+ Scott
+ Mumford
+ smumford(a)redhat.com
+
-
+
-
+ Updated for 4.3 CP05 Release
+
+
+
+
+
=
Added: docs/enterprise/trunk/PortletBridge/publican.cfg
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- docs/enterprise/trunk/PortletBridge/publican.cfg =
(rev 0)
+++ docs/enterprise/trunk/PortletBridge/publican.cfg 2010-07-14 01:46:03 UT=
C (rev 13959)
@@ -0,0 +1,7 @@
+# Config::Simple 4.59
+# Wed Jul 14 11:15:41 2010
+
+debug: 1
+xml_lang: en-US
+brand: JBoss
+
--===============0041630524224032913==--