I just saw that the constructor is called with each request I make, I don't think that is normal behaviour.

Ivo Limmen wrote:

I use Cocoon 2.1.2 on Tomcat 4.1.24. I had build an generator in Cocoon 2.0.3 and wanted to update the code to use the ServiceableGenerator class.
I added logging to each method of my generator but I see nothing. I added System.err outputs and only say that the constructor is called. So I at least know that the classes are found and that Cocoon instantiated my generator.
But setup() service() and dispose() are not called at all...


Sitemap.log:

ERROR (2003-10-23) 08:44.02:601 [sitemap.handled-errors] (/cocoon/butterfly/dealDetail.xml) Thread-11/PipelineNode: Lookup of generator for role 'dealGen' failed.
org.apache.cocoon.ProcessingException: Lookup of generator for role 'dealGen' failed.: org.apache.avalon.framework.component.ComponentException: generators: ComponentSelector could not find the component for hint [dealGen] (key [dealGen])
at org.apache.cocoon.components.pipeline.AbstractProcessingPipeline.setGenerator(AbstractProcessingPipeline.java:254)


at org.apache.cocoon.components.pipeline.impl.AbstractCachingProcessingPipeline.setGenerator(AbstractCachingProcessingPipeline.java:158)

at org.apache.cocoon.components.treeprocessor.sitemap.GenerateNode.invoke(GenerateNode.java:92)


Sitemap.xmap:


<map:generators default="dealGen">

      <map:generator logger="sitemap.generator.dealGen"
        name="dealGen" src="nl.virgil.butterfly.DealDetailGenerator"/>

</map:generators>

...

    <map:pipeline>
      <!-- XML output of deal details -->
      <map:match pattern="*">
        <map:act type="request">
          <map:parameter name="parameters" value="true"/>
          <map:generate type="dealGen">
            <parameter name="id" value="{id}"/>
            <parameter name="product" value="{product}"/>
            <parameter name="language" value="{lang}"/>
          </map:generate>
        </map:act>
        <map:serialize type="xml"/>
      </map:match>
    </map:pipeline>


Thanks,

-- Ivo Limmen


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to