temp solution to run struts-bridge-app in pluto rc1

2005-03-22 Thread Thomas . Koch
hi !
i dont know, why i got no answer for my mail rom 03.03 - so two reasons 
are possible.
nobody or everybody knows the answer...
for everybody who is interisting to know how he
could start a struts-bridge-application in pluto rc1:

at the moment its only a temporary solution with the struts-demo

 go to file:
ServletContextProviderImpl in J2 project :-)

change line:
return 
((JetspeedPortletContext)portlet.getPortletContext()).getServletContext();

into
 return 
((PortletContextImpl)portlet.getPortletContext()).getServletContext();

you havt to import
import org.apache.pluto.core.impl.PortletContextImpl;

compile an build the j2 project.

find the
jetspeed-commons-2.0-M2-dev.jar (it includes the 
ServletContextProviderImpl)
and copy it into the web-inf/lib







web.xml:
servlet
servlet-nameStrutsPortletDemo/servlet-name
display-nameStrutsPortletDemo Wrapper/display-name
descriptionAutomated generated Portlet Wrapper/description
 servlet-classorg.apache.pluto.core.PortletServlet/servlet-class
init-param
param-nameportlet-class/param-name
 
param-valueorg.apache.portals.bridges.struts.StrutsPortlet/param-value
/init-param
init-param
param-nameportlet-guid/param-name
param-valuestruts-demo.StrutsPortletDemo/param-value
/init-param
/servlet
servlet-mapping
servlet-nameStrutsPortletDemo/servlet-name
url-pattern/StrutsPortletDemo/*/url-pattern
/servlet-mapping
taglib







Portlet.xml

?xml version=1.0 encoding=UTF-8?
portlet-app id=struts-demo version=1.0
  portlet id=StrutsPortletDemo
init-param
  nameServletContextProvider/name
 valueorg.apache.jetspeed.portlet.ServletContextProviderImpl/value
/init-param
init-param
  nameViewPage/name
  value/Welcome.do/value
/init-param
init-param
  nameHelpPage/name
  value/Tour.do/value
/init-param
portlet-nameStrutsPortletDemo/portlet-name
display-nameStruts Portlet Demo/display-name
descriptionThis is the struts MailReader portlet demo/description
 
portlet-classorg.apache.portals.bridges.struts.StrutsPortlet/portlet-class
expiration-cache-1/expiration-cache
supports
  mime-typetext/html/mime-type
  portlet-modeVIEW/portlet-mode
  portlet-modeHELP/portlet-mode
/supports
portlet-info
  titleStruts MailReader Demo/title
  short-titleThis is the short title/short-title
  keywordsStruts/keywords
/portlet-info
  /portlet
/portlet-app





Portletentitieregsitry.xml

application id=5
definition-idstruts-demo/definition-id
portlet id=1
 definition-idstruts-demo.StrutsPortletDemo/definition-id
preferences
pref-nameStrutsPortletDemo/pref-name
pref-valueStrutsPortletDemo/pref-value
read-onlyfalse/read-only
/preferences
/portlet
/application









Pageregistry.xml

?xml version=1.0?

portal

fragment name=navigation 
class=org.apache.pluto.portalImpl.aggregation.navigation.TabNavigation
/fragment
 
fragment name=test type=page
navigation
titleTest/title
description.../description
/navigation

fragment name=row type=row

fragment name=col1 type=column

fragment name=p1 type=portlet
property name=portlet value=3.1/
/fragment

fragment name=p2 type=portlet
property name=portlet value=5.1/
/fragment

/fragment

/fragment

/fragment

Re: temp solution to run struts-bridge-app in pluto rc1

2005-03-22 Thread Ate Douma
Thomas,
[EMAIL PROTECTED] wrote:
hi !
i dont know, why i got no answer for my mail rom 03.03 - so two reasons 
are possible.
nobody or everybody knows the answer...
for everybody who is interisting to know how he
could start a struts-bridge-application in pluto rc1:
3: everybody who does know the answer was too damn busy at the time ;-)
Although your solution will work, I can't say I recommend doing it like this.
Once the Bridges subproject is finally started under Apache Portals (hopefully
soon now...) I will provide portal specific providers for the 
ServletContextProvider.
I could do so right now for Pluto except I don't want to bring its dependency 
into
the bridges-common project just to be able to compile it.
I suggest the following solution until we can provide this through the Bridges 
Project:
- Copy the 
jetspeed/commons/src/java/org/apache/jetspeed/portlet/ServletContextProviderImpl.java
  into a new package/folder of your own like:
org.apache.portals.bridges.common.providers.pluto
  and adapt the package in the ServletContextProviderImpl.java file accordingly.
- Make the changes you described below (replacing JetspeedPortletContext with 
PortletContextImpl)
  and replace import statement 
org.apache.jetspeed.container.JetspeedPortletContext with
  org.apache.pluto.core.impl.PortletContextImpl.
  Now you will have a Jetspeed independant ServletContextProvider for pluto.
- Compile the class and put it into $Tomcat/shared/lib and you're done.
  And you *don't* have to use the jetspeed-commons-2.0-M2-dev.jar anymore.
Regards, Ate
at the moment its only a temporary solution with the struts-demo
 go to file:
ServletContextProviderImpl in J2 project :-)
change line:
return 
((JetspeedPortletContext)portlet.getPortletContext()).getServletContext();

into
 return 
((PortletContextImpl)portlet.getPortletContext()).getServletContext();

you havt to import
import org.apache.pluto.core.impl.PortletContextImpl;
compile an build the j2 project.
find the
jetspeed-commons-2.0-M2-dev.jar (it includes the 
ServletContextProviderImpl)
and copy it into the web-inf/lib




web.xml:
servlet
servlet-nameStrutsPortletDemo/servlet-name
display-nameStrutsPortletDemo Wrapper/display-name
descriptionAutomated generated Portlet Wrapper/description
 servlet-classorg.apache.pluto.core.PortletServlet/servlet-class
init-param
param-nameportlet-class/param-name
 
param-valueorg.apache.portals.bridges.struts.StrutsPortlet/param-value
/init-param
init-param
param-nameportlet-guid/param-name
param-valuestruts-demo.StrutsPortletDemo/param-value
/init-param
/servlet
servlet-mapping
servlet-nameStrutsPortletDemo/servlet-name
url-pattern/StrutsPortletDemo/*/url-pattern
/servlet-mapping
taglib




Portlet.xml
?xml version=1.0 encoding=UTF-8?
portlet-app id=struts-demo version=1.0
  portlet id=StrutsPortletDemo
init-param
  nameServletContextProvider/name
 valueorg.apache.jetspeed.portlet.ServletContextProviderImpl/value
/init-param
init-param
  nameViewPage/name
  value/Welcome.do/value
/init-param
init-param
  nameHelpPage/name
  value/Tour.do/value
/init-param
portlet-nameStrutsPortletDemo/portlet-name
display-nameStruts Portlet Demo/display-name
descriptionThis is the struts MailReader portlet demo/description
 
portlet-classorg.apache.portals.bridges.struts.StrutsPortlet/portlet-class
expiration-cache-1/expiration-cache
supports
  mime-typetext/html/mime-type
  portlet-modeVIEW/portlet-mode
  portlet-modeHELP/portlet-mode
/supports
portlet-info
  titleStruts MailReader Demo/title
  short-titleThis is the short title/short-title
  keywordsStruts/keywords
/portlet-info
  /portlet
/portlet-app



Portletentitieregsitry.xml
application id=5
definition-idstruts-demo/definition-id
portlet id=1
 definition-idstruts-demo.StrutsPortletDemo/definition-id
preferences
pref-nameStrutsPortletDemo/pref-name
pref-valueStrutsPortletDemo/pref-value
read-onlyfalse/read-only
/preferences
/portlet
/application




Pageregistry.xml
?xml version=1.0?
portal
fragment name=navigation 
class=org.apache.pluto.portalImpl.aggregation.navigation.TabNavigation
/fragment
 
fragment name=test type=page
navigation
titleTest/title
description.../description
/navigation

fragment name=row type=row
fragment name=col1 type=column
fragment name=p1 type=portlet
property name=portlet value=3.1/
/fragment
fragment name=p2 type=portlet
property name=portlet value=5.1/
/fragment
/fragment
  

Re: temp solution to run struts-bridge-app in pluto rc1

2005-03-22 Thread Thomas . Koch
thanks a lot !

your description elucidated why a temp is in the subject.
my way is(was) the brute force of course.
i did it like this, because i needed a fast way and
i did't know what dependencies the ServletContextProviderImpl.java has...

thomas






Thomas,

[EMAIL PROTECTED] wrote:
 hi !
 i dont know, why i got no answer for my mail rom 03.03 - so two reasons 
 are possible.
 nobody or everybody knows the answer...
 for everybody who is interisting to know how he
 could start a struts-bridge-application in pluto rc1:
3: everybody who does know the answer was too damn busy at the time ;-)

Although your solution will work, I can't say I recommend doing it like 
this.
Once the Bridges subproject is finally started under Apache Portals 
(hopefully
soon now...) I will provide portal specific providers for the 
ServletContextProvider.
I could do so right now for Pluto except I don't want to bring its 
dependency into
the bridges-common project just to be able to compile it.

I suggest the following solution until we can provide this through the 
Bridges Project:
- Copy the 
jetspeed/commons/src/java/org/apache/jetspeed/portlet/ServletContextProviderImpl.java
   into a new package/folder of your own like:
 org.apache.portals.bridges.common.providers.pluto
   and adapt the package in the ServletContextProviderImpl.java file 
accordingly.
- Make the changes you described below (replacing JetspeedPortletContext 
with PortletContextImpl)
   and replace import statement 
org.apache.jetspeed.container.JetspeedPortletContext with
   org.apache.pluto.core.impl.PortletContextImpl.
   Now you will have a Jetspeed independant ServletContextProvider for 
pluto.
- Compile the class and put it into $Tomcat/shared/lib and you're done.
   And you *don't* have to use the jetspeed-commons-2.0-M2-dev.jar 
anymore.

Regards, Ate

 
 at the moment its only a temporary solution with the struts-demo
 
  go to file:
 ServletContextProviderImpl in J2 project :-)
 
 change line:
 return 
 
((JetspeedPortletContext)portlet.getPortletContext()).getServletContext();
 
 into
  return 
 ((PortletContextImpl)portlet.getPortletContext()).getServletContext();
 
 you havt to import
 import org.apache.pluto.core.impl.PortletContextImpl;
 
 compile an build the j2 project.
 
 find the
 jetspeed-commons-2.0-M2-dev.jar (it includes the 
 ServletContextProviderImpl)
 and copy it into the web-inf/lib
 
 
 
 
 
 
 
 web.xml:
 servlet
 servlet-nameStrutsPortletDemo/servlet-name
 display-nameStrutsPortletDemo Wrapper/display-name
 descriptionAutomated generated Portlet Wrapper/description
  servlet-classorg.apache.pluto.core.PortletServlet/servlet-class
 init-param
 param-nameportlet-class/param-name
 
 
param-valueorg.apache.portals.bridges.struts.StrutsPortlet/param-value
 /init-param
 init-param
 param-nameportlet-guid/param-name
 param-valuestruts-demo.StrutsPortletDemo/param-value
 /init-param
 /servlet
 servlet-mapping
 servlet-nameStrutsPortletDemo/servlet-name
 url-pattern/StrutsPortletDemo/*/url-pattern
 /servlet-mapping
 taglib
 
 
 
 
 
 
 
 Portlet.xml
 
 ?xml version=1.0 encoding=UTF-8?
 portlet-app id=struts-demo version=1.0
   portlet id=StrutsPortletDemo
 init-param
   nameServletContextProvider/name
  valueorg.apache.jetspeed.portlet.ServletContextProviderImpl/value
 /init-param
 init-param
   nameViewPage/name
   value/Welcome.do/value
 /init-param
 init-param
   nameHelpPage/name
   value/Tour.do/value
 /init-param
 portlet-nameStrutsPortletDemo/portlet-name
 display-nameStruts Portlet Demo/display-name
 descriptionThis is the struts MailReader portlet 
demo/description
 
 
portlet-classorg.apache.portals.bridges.struts.StrutsPortlet/portlet-class
 expiration-cache-1/expiration-cache
 supports
   mime-typetext/html/mime-type
   portlet-modeVIEW/portlet-mode
   portlet-modeHELP/portlet-mode
 /supports
 portlet-info
   titleStruts MailReader Demo/title
   short-titleThis is the short title/short-title
   keywordsStruts/keywords
 /portlet-info
   /portlet
 /portlet-app
 
 
 
 
 
 Portletentitieregsitry.xml
 
 application id=5
 definition-idstruts-demo/definition-id
 portlet id=1
  definition-idstruts-demo.StrutsPortletDemo/definition-id
 preferences
 pref-nameStrutsPortletDemo/pref-name
 pref-valueStrutsPortletDemo/pref-value
 read-onlyfalse/read-only
 /preferences
 /portlet
 /application
 
 
 
 
 
 
 
 
 
 Pageregistry.xml
 
 ?xml version=1.0?
 
 portal
 
 fragment name=navigation 
 
class=org.apache.pluto.portalImpl.aggregation.navigation.TabNavigation
 /fragment
 
 fragment name=test type=page
 navigation