I have integrated Struts bridge with JBoss Portal. It is only available in CVS 
head only.

The bridge is based on jetspeed 2.0 M2 bridge and provide an experimental 
implementation of it.

First you need to read the documentation provided by the struts bridge that 
explains how it works and what are the limitations of the bridge regarding the 
application to convert.

The struts mail demo application works with it. Here is what needs to be 
modified :

1/
in WEB-INF/portlet.xml change the bridge implementation value

  |     ...
  |     <init-param>
  |       <name>ServletContextProvider</name>
  |       <value>org.jboss.portal.bridge.JBossServletContextProvider</value>
  |     </init-param>
  |     ...
  | 
That will tell the StrutsPortlet to use the specific implementation of the 
ServletContextProvider implementation that make it works into JBoss

2/
add WEB-INF/jboss-portlet.xml containing

  | <portlet-app>
  |    <portlet>
  |       <portlet-name>StrutsPortletDemo</portlet-name>
  |       <!-- Use the specific struts container configuration -->
  |       <config-name>StrutsPortlet</config-name>
  |    </portlet>
  | </portlet-app>
  | 
that tells portlet deployer to use an alternative configuration specific to 
struts portlets

3/ add WEB-INF/portlet-instances.xml

  | <instances>
  |    <instance>
  |       <instance-name>StrutsPortletDemoInstance</instance-name>
  |       <component-ref>StrutsPortletDemo</component-ref>
  |    </instance>
  | </instances>
  | 
that will create an instance of the portlet

4/ add WEB-INF/struts-pages.xml

  | <pages>
  |    <portal-name>default</portal-name>
  |    <page>
  |       <page-name>struts</page-name>
  |       <window>
  |          <window-name>StrutsPortletWindow</window-name>
  |     
<instance-ref>/struts-demo.StrutsPortletDemo.StrutsPortletDemoInstance</instance-ref>
  |          <region>center</region>
  |          <height>0</height>
  |       </window>
  |    </page>
  | </pages>
  | 
that create a page in the default portal containing the instance we have created

5/ have the struts bridge jar in the web application : 
WEB-INF/lib/portals-bridges-struts-0.2.jar

note that :

1/ not all struts applications can be converted to work into portlet
2/ the taglib used by the integration is different from the one provided with 
struts in order to integrate properly with PortletURL


You can dowload the bundled sample here
http://docs.jboss.org/jbportal/samples/struts-demo-for-jboss-portal.zip

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3876429#3876429

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3876429


-------------------------------------------------------
This SF.Net email is sponsored by: NEC IT Guy Games.
Get your fingers limbered up and give it your best shot. 4 great events, 4
opportunities to win big! Highest score wins.NEC IT Guy Games. Play to
win an NEC 61 plasma display. Visit http://www.necitguy.com/?r=20
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to