cocoon-docs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@cocoon.apache.org
Subject [Cocoon Wiki] Updated: JSR168Portlet
Date Mon, 15 Nov 2004 07:01:50 GMT
   Date: 2004-11-14T23:01:50
   Editor: RalphGoers <Ralph_Goers@dslextreme.com>
   Wiki: Cocoon Wiki
   Page: JSR168Portlet
   URL: http://wiki.apache.org/cocoon/JSR168Portlet

   no comment

Change Log:

------------------------------------------------------------------------------
@@ -42,164 +42,77 @@
 
 === Deployment ===
 
-Here we outline deployment of !CocoonPortlet in the Pluto Portlet container. You'll need:
- *  jars:
-  * pluto-20031202.jar: Pluto portlet container 
-  * pluto-portal-impl-20031202.jar: Pluto portal implementation
-
- *  portlet.xml:
-{{{
-<?xml version="1.0" encoding="UTF-8"?>
-
-<portlet-app xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd"
-             version="1.0"
-             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
-             xsi:schemaLocation="
-               http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd
-               http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd">
-
-  <portlet>
-    <portlet-name>CocoonPortlet</portlet-name>
-    <display-name>JSR-168 Cocoon Portlet</display-name>
-    <portlet-class>org.apache.cocoon.portlet.CocoonPortlet</portlet-class>
-
-    <!--
-      This parameter indicates the category id of the logger from the LogKit
-      configuration used by the CocoonServlet.
-    -->
-    <init-param>
-      <name>portlet-logger</name>
-      <value>access</value>
-    </init-param>
-
-    <!--
-      Causes all files in multipart requests to be processed.
-      Default is false for security reasons.  
-      Unsupported values will be interpreted as false.
-    -->
-    <init-param>
-      <name>enable-uploads</name>
-      <value>true</value>
-    </init-param>
-
-    <!--
-      Causes all files in multipart requests to be saved to upload-dir.
-      Default is true for security reasons.  
-      Unsupported values will be interpreted as false.
-    -->
-    <init-param>
-      <name>autosave-uploads</name>
-      <value>true</value>
-    </init-param>
-
-    <!--
-      Specify handling of name conflicts when saving uploaded files
-      to disk.  Acceptable values are deny, allow, rename (default).
-      Files are renamed x_filename where x is an integer value incremented
-      to make the new filename unique.
-    -->
-    <init-param>
-      <name>overwrite-uploads</name>
-      <value>rename</value>
-    </init-param>
-
-    <!--
-      Specify maximum allowed size of the upload. Defaults to 10 Mb.
-
-    <init-param>
-      <name>upload-max-size</name>
-      <value>10000000</value>
-    </init-param>    
-    -->
-
-    <!--
-      If you set this parameter to 'true' or 'yes', Cocoon will add processing
-      time to the end of each response. Value 'hide' adds processing time as an HTML
-      comment. By default, processing time is not added (corresponds to value 'no').
-
-    <init-param>
-      <name>show-time</name>
-      <value>hide</value>
-    </init-param>
-    -->
-
-    <!--
-      If true or not set, this class will try to catch and handle all Cocoon exceptions.
-      If false, it will rethrow them to the servlet container.
-    -->
-    <init-param>
-      <name>manage-exceptions</name>
-      <value>true</value>
-    </init-param>
-
-    <!--
-      Set encoding used by the container. If not set the ISO-8859-1 encoding will be assumed.
-
-    <init-param>
-      <name>container-encoding</name>
-      <value>utf-8</value>
-    </init-param>
-    -->
-
-    <!--
-      Set form encoding. This will be the character set used to decode request parameters.
-      If not set the ISO-8859-1 encoding will be assumed. 
-
-    <init-param>
-      <name>form-encoding</name>
-      <value>utf-8</value>
-    </init-param>
-    -->
-        
-    <expiration-cache>-1</expiration-cache>
-            
-    <supports>
-      <mime-type>text/html</mime-type>
-      <portlet-mode>VIEW</portlet-mode>
-      <portlet-mode>EDIT</portlet-mode>
-      <portlet-mode>HELP</portlet-mode>
-    </supports>
-
-    <supported-locale>en</supported-locale>                
-
-    <portlet-info>
-      <title>JSR-168 Cocoon Portlet</title>
-      <short-title>Cocoon Portlet</short-title>
-      <keywords>Apache, Cocoon, XML, Jakarta, Pluto, Portlet, WSRP, WSRP4J, JSR-168</keywords>
-    </portlet-info>            
-  </portlet>  
-</portlet-app>
+This example documents how to install the R''''''ssPortlet found at [http://sourceforge.net/projects/portlet-opensrc
Portlet Open Source Trading Site]. You'll need:
+ *  jars (found in webapps/WEB-INF/lib of your Cocoon build):
+  * The pluto jar (pluto-1.0.1-rc1.jar in release 2.1.6). 
+  * portlet-api-1.0.jar.
+Move these two jars into a library shared across web applications in your servlet container.
In Tomcat this should be $CATALINA_BASE/shared/lib however as of release 5.0.28 this did not
work and the jars need to be placed in $CATALINA_HOME/common/lib.
+
+Unjar R''''''ssPortlet.war into an exploded web application directory in the servlet container
(i.e. webapps/R''''''ssPortlet in Tomcat).
+
+ *  web.xml - Replace the web.xml with the following for Tomcat:
+{{{
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
+                         "http://java.sun.com/dtd/web-app_2_3.dtd">
+
+<web-app>
+  <!-- Servlet Configuration ========================================== -->
+  <servlet>
+    <servlet-name>RssPortlet</servlet-name>
+    <display-name>Pluto wrapper for RssPortlet</display-name>
+    <servlet-class>org.apache.pluto.core.PortletServlet</servlet-class>
+    <init-param>
+      <param-name>portlet-guid</param-name>
+      <param-value>RssPortlet.RssPortlet</param-value>
+    </init-param>
+    <init-param>
+      <param-name>portlet-class</param-name>
+      <param-value>com.plumtree.portlet.portlets.RssPortlet</param-value>
+    </init-param>
+  </servlet>
+
+  <!-- URL space mappings ============================================= -->
+  <servlet-mapping>
+    <servlet-name>RssPortlet</servlet-name>
+    <url-pattern>/*</url-pattern>
+  </servlet-mapping>
+</web-app>
+}}}
+
+To integrate the portlet into the Cocoon sample site:
+ *  copletdata/portal.xml:
+    After the C''''''ocoonPortlet definition add:
+{{{
+   <coplet-data id="RssPortlet" name="standard">
+      <title>RssPortlet</title>
+      <coplet-base-data>Portlet</coplet-base-data>
+      <attribute>
+         <name>portlet</name>
+         <value xsi:type="java:java.lang.String" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">RssPortlet.RssPortlet</value>
+      </attribute>
+      <attribute>
+         <name>buffer</name>
+         <value xsi:type="java:java.lang.Boolean" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">true</value>
+      </attribute>
+   </coplet-data>
 }}}
 
- *  web.xml:
-{{{
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
-                         "http://java.sun.com/dtd/web-app_2_3.dtd">
-
-<web-app>
-  <!-- Servlet Configuration ========================================== -->
-  <servlet>
-    <servlet-name>CocoonPortlet Wrapper</servlet-name>
-    <display-name>Pluto wrapper for CocoonPortlet</display-name>
-    <servlet-class>org.apache.pluto.core.PortletServlet</servlet-class>
-    <init-param>
-      <param-name>portlet-guid</param-name>
-      <param-value>cocoon.CocoonPortlet</param-value>
-    </init-param>
-    <init-param>
-      <param-name>portlet-class</param-name>
-      <param-value>org.apache.cocoon.portlet.CocoonPortlet</param-value>
-    </init-param>
-  </servlet>
-
-  <!-- URL space mappings ============================================= -->
-  <servlet-mapping>
-    <servlet-name>CocoonPortlet</servlet-name>
-    <url-pattern>/CocoonPortlet/*</url-pattern>
-  </servlet-mapping>
-</web-app>
+ *  copletinstancedata/portal.xml:
+    After the C''''''ocoonPortlet definition add:
+{{{
+   <coplet-instance-data id="RssPortlet" name="standard">
+     <coplet-data>RssPortlet</coplet-data>
+   </coplet-instance-data>
 }}}
 
- *  sitemap.xmap:
+  * layout/portal.xml:
+    After the C''''''ocoonPortlet item definition add:
+{{{
+   <item>
+     <coplet-layout name="coplet" layout-renderer-name="portlet-window">
+       <coplet-instance-data>RssPortlet</coplet-instance-data>
+     </coplet-layout>
+   </item>
+}}}

Mime
View raw message