cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Reinhard Poetz <reinh...@apache.org>
Subject Switching to servlet-service-fw
Date Tue, 06 Feb 2007 08:18:20 GMT

For those of you who are using the blocks-fw and want to switch to the 
refactored servlet-service-fw (the blocks-fw can be considered as deprecated!), 
here is a writeup of what needs to be done to switch:

  -  pom.xml: remove dependency on blocks-fw and replace it with

     <dependency>
       <groupId>org.apache.cocoon</groupId>
       <artifactId>cocoon-servlet-service-components</artifactId>
       <version>1.0.0-SNAPSHOT</version>
     </dependency>


  -  change your servlet bean definitions
     See 
http://svn.apache.org/repos/asf/cocoon/trunk/core/cocoon-servlet-service/cocoon-servlet-service-sample/src/main/resources/META-INF/cocoon/spring/
     for working examples.


  -  if you use property replacement, you have to change the property
     "blockContextUrl" to "contextPath"

  - if you use the "block:" protocol, replace it with "servlet:".

  - update your web.xml to use the new DispatcherServlet:

   <servlet>
     <description>Cocoon blocks dispatcher</description>
     <display-name>DispatcherServlet</display-name>
     <servlet-name>DispatcherServlet</servlet-name>
<servlet-class>org.apache.cocoon.servletservice.DispatcherServlet</servlet-class>
     <load-on-startup>1</load-on-startup>
   </servlet>


For me that was all I had to do but the three projects that I updaded aren't the 
most complicated ones. I won't put this into the CMS or the Wiki as it will 
confuse people very soon rather than being helpful. As I guess that all 
block-fw^^^servlet-service-fw users are reading this list, this information 
should find its audience anyway.

-- 
Reinhard Pötz           Independent Consultant, Trainer & (IT)-Coach 

{Software Engineering, Open Source, Web Applications, Apache Cocoon}

                                        web(log): http://www.poetz.cc
--------------------------------------------------------------------

Mime
View raw message