You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Barbara Post <ba...@ifrance.com> on 2002/08/05 12:59:07 UTC

Sitemap problem : ContentAggregator.recycle

Hello, I get the following with C 2.0.3... (should I upgrade to 2.0.4 ? I
have to use a "release" for my project... :-/ ). I use Tomcat 4.0.4 and the
error is written in Tomcat's window. (using Windows NT).

java.lang.NullPointerException
        at
org.apache.cocoon.sitemap.ContentAggregator.recycle(ContentAggregator
.java:290)
        at
org.apache.avalon.excalibur.pool.ResourceLimitingPool.put(ResourceLim
itingPool.java:395)
        at
org.apache.avalon.excalibur.component.PoolableComponentHandler.doPut(
PoolableComponentHandler.java:200)
        at
org.apache.avalon.excalibur.component.ComponentHandler.put(ComponentH
andler.java:176)

My pipeline is indeed pretty complicated. It worked until I added the
"map:act type="reqparams-exists". (RequestParameterExistsAction)

Indeed I have to perform a form validation only if the form has been
submitted at least once, this is why I check whether "CustomerID" is in the
req. parameters.

Any idea ? Thanks a lot !
I use Sunrise authentication and Christian's SimpleFormTransformer.

Barbara

<map:match pattern="defaultgenerationform2fill">
    <!-- be sure one gets the request parameters -->
    <map:act type="request">
     <map:parameter name="parameters" value="true"/>
     <!-- authenticate as usual -->
     <map:act type="sunRise-auth">
      <map:parameter name="handler" value="baepp-handler"/>
      <!-- this wraps with action that checks whether
      some request parameters exist, if so performs
      form validation since form has been submitted
      at least once, else generate input form -->
      <map:act type="reqparam-exists">
       <map:parameter name="parameters" value="CustomerID"/>
       <!-- form validation -->
       <map:act type="form-validator">
        <map:parameter name="descriptor"
value="cocoon://getdescriptor/{../../template}"/>
        <map:parameter name="validate-set" value="default"/>
        <!-- ok  so to test -->
                <map:redirect-to uri="http://www.google.fr"/>
       </map:act>
       <!-- form validation failed so show input form -->
       <map:aggregate element="page">
        (...)
       </map:aggregate>
       <map:transform type="sunShine"/>
       <map:transform src="xsl/genlicform2fill.xsl">
        <map:parameter name="use-request-parameters" value="true"/>
       </map:transform>
              <!-- keeps request params but not errors added
      by form validation -->
       <map:transform type="simple-form"/>
       <map:serialize type="html"/>
      </map:act>
      <!-- no form validation occured, generates input form -->
      <map:aggregate element="page">
    (... same as above excepted path to sitemap parameters)
      </map:aggregate>
      <map:transform type="sunShine"/>
      <map:transform src="xsl/genlicform2fill.xsl">
       <map:parameter name="use-request-parameters" value="true"/>
      </map:transform>
      <map:transform type="simple-form"/>
     </map:act>
    </map:act>
   </map:match>


---------------------------------------------------------------------
Please check that your question  has not already been answered in the
FAQ before posting.     <http://xml.apache.org/cocoon/faq/index.html>

To unsubscribe, e-mail:     <co...@xml.apache.org>
For additional commands, e-mail:   <co...@xml.apache.org>