You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by giacomo <gi...@apache.org> on 2002/02/06 22:03:58 UTC

Re: Interpreted Sitemap?

On Wed, 30 Jan 2002, Sylvain Wallez wrote:

> shenoy, nitin wrote:
>
> ><snip>
> >Stefano wrote
> >
> >Have you tried running Cocoon with the interpreted sitemap instead of
> >the compiled one? in that case, nobody needs to reference the libraries
> >directly since it would be weblogic's classloader to give them to
> >Cocoon's classes.
> >
> ></snip>
> >
> >Where would I find info about the interpreted sitemap? I have searched the
> >archives and I saw a few discussion threads around it on the users group.
> >
> >But the last message merely said it was still in development.
> >
> >Regards,
> >Nitin
> >
> The interpreted sitemap engine isn't in the official distribution, but
> in the scratchpad. It is fully functionnal, and the only known issue I
> know of (I'm currently working on it) is view handling in aggregations.
>
> To use it, you'll have to include cocoon-scratchpad.jar in your
> WEB-INF/lib and change the <sitemap> line in cocoon.xconf into :
> <sitemap class="org.apache.cocoon.treeprocessor.TreeProcessor"
> logger="sitemap"/>
>
> At the first request, you may see an error message complaining about
> undefined "xmldb" or "parentcm" generators. You'll then have to comment
> out these pipelines in sitemap.xmap, since the interpreted sitemap is
> more strict than the compiled engine.
>
> Please report any problem you may have with this new engine.

And here it is :)

We usually deploy our apps as sub-sitemaps with the following approach:

- install an unpacked cocoon.war into the servlet container
  (Catalina in our case)
- copy the sitemap.xmap to original.sitemp.xmap
- in sitemap.xmap strip out all resources, action-sets and pipelines and
  leave a:

  <map:pipeline>
   <map:match pattern="our-app/**">
    <map:mount uri-prefix="our-app"
               src="our-app/sitemap.xmap"
               check-reload="yes"/>
   </map:match>

   <map:match pattern="**">
    <map:mount uri-prefix=""
               src="original.sitemap.xmap"
               check-reload="yes"/>
   </map:match>

   <map:handle-errors>
    <map:transform src="stylesheets/system/error2html.xsl"/>
    <map:serialize status-code="500"/>
   </map:handle-errors>
  </map:pipeline>

A request to http://localhost:8080/cocoon/welcome work smart with the
compiled sitemap but with the TreeProcessor it spews alot of

"Problem setting up the connection: org.dbxml.client.xmldb.DatabaseImpl"

ProcessingExceptions and finally dies an OutOfMemoryError.

Any thoughts?

Giacomo


---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Re: Interpreted Sitemap?

Posted by Peter Royal <pr...@managingpartners.com>.
On Thursday 07 February 2002 05:00 pm, Sylvain Wallez wrote:
> Fixed !
>
> Peter, Giacomo, could you please test again ?

Verified! :)
-pete

-- 
peter royal -> proyal@managingpartners.com

---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Re: Interpreted Sitemap?

Posted by giacomo <gi...@apache.org>.
On Thu, 7 Feb 2002, Sylvain Wallez wrote:

> giacomo wrote:
>
> >On Wed, 6 Feb 2002, Peter Royal wrote:
> >
> >>On Wednesday 06 February 2002 04:35 pm, Sylvain Wallez wrote:
> >>
> >>>> <map:pipeline>
> >>>>  <map:match pattern="our-app/**">
> >>>>   <map:mount uri-prefix="our-app"
> >>>>              src="our-app/sitemap.xmap"
> >>>>              check-reload="yes"/>
> >>>>  </map:match>
> >>>>
> >>>>  <map:match pattern="**">
> >>>>   <map:mount uri-prefix=""
> >>>>              src="original.sitemap.xmap"
> >>>>              check-reload="yes"/>
> >>>>  </map:match>
> >>>>
> >>>>  <map:handle-errors>
> >>>>   <map:transform src="stylesheets/system/error2html.xsl"/>
> >>>>   <map:serialize status-code="500"/>
> >>>>  </map:handle-errors>
> >>>> </map:pipeline>
> >>>>
> >>>Peter Royal found a bug that affects mounts that have a file and not a
> >>>directory in their "src" attribute, just as in your sitemap. I'll fix it
> >>>ASAP so you can try again. But I'm really surprised this causes such a
> >>>violent death of the JVM !
> >>>
> >>The bug causes the mount to pick up the sitemap.xmap in the root as the
> >>sitemap for the mount, thus you will go into an infinite loop if you request
> >>something that does not match the first match.
> >>
> >
> >This explaines the dozends of dbxml exception and the OutOfMemoryError.
> >Thanks.
> >
> >Giacomo
> >
> Fixed !
>
> Peter, Giacomo, could you please test again ?

I'm running an app we have for internal use. I've changed it right now
to use the TreeProcessor. If you don't hear any complaints it will runn
and nobody found somthing isn't working ;)

Thanks.

Giacomo


---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Re: Interpreted Sitemap?

Posted by Sylvain Wallez <sy...@anyware-tech.com>.
giacomo wrote:

>On Wed, 6 Feb 2002, Peter Royal wrote:
>
>>On Wednesday 06 February 2002 04:35 pm, Sylvain Wallez wrote:
>>
>>>> <map:pipeline>
>>>>  <map:match pattern="our-app/**">
>>>>   <map:mount uri-prefix="our-app"
>>>>              src="our-app/sitemap.xmap"
>>>>              check-reload="yes"/>
>>>>  </map:match>
>>>>
>>>>  <map:match pattern="**">
>>>>   <map:mount uri-prefix=""
>>>>              src="original.sitemap.xmap"
>>>>              check-reload="yes"/>
>>>>  </map:match>
>>>>
>>>>  <map:handle-errors>
>>>>   <map:transform src="stylesheets/system/error2html.xsl"/>
>>>>   <map:serialize status-code="500"/>
>>>>  </map:handle-errors>
>>>> </map:pipeline>
>>>>
>>>Peter Royal found a bug that affects mounts that have a file and not a
>>>directory in their "src" attribute, just as in your sitemap. I'll fix it
>>>ASAP so you can try again. But I'm really surprised this causes such a
>>>violent death of the JVM !
>>>
>>The bug causes the mount to pick up the sitemap.xmap in the root as the
>>sitemap for the mount, thus you will go into an infinite loop if you request
>>something that does not match the first match.
>>
>
>This explaines the dozends of dbxml exception and the OutOfMemoryError.
>Thanks.
>
>Giacomo
>
Fixed !

Peter, Giacomo, could you please test again ?

Thanks,
Sylvain

-- 
Sylvain Wallez
Anyware Technologies - http://www.anyware-tech.com




---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Re: Interpreted Sitemap?

Posted by giacomo <gi...@apache.org>.
On Wed, 6 Feb 2002, Peter Royal wrote:

> On Wednesday 06 February 2002 04:35 pm, Sylvain Wallez wrote:
> > >  <map:pipeline>
> > >   <map:match pattern="our-app/**">
> > >    <map:mount uri-prefix="our-app"
> > >               src="our-app/sitemap.xmap"
> > >               check-reload="yes"/>
> > >   </map:match>
> > >
> > >   <map:match pattern="**">
> > >    <map:mount uri-prefix=""
> > >               src="original.sitemap.xmap"
> > >               check-reload="yes"/>
> > >   </map:match>
> > >
> > >   <map:handle-errors>
> > >    <map:transform src="stylesheets/system/error2html.xsl"/>
> > >    <map:serialize status-code="500"/>
> > >   </map:handle-errors>
> > >  </map:pipeline>
> >
> > Peter Royal found a bug that affects mounts that have a file and not a
> > directory in their "src" attribute, just as in your sitemap. I'll fix it
> > ASAP so you can try again. But I'm really surprised this causes such a
> > violent death of the JVM !
>
> The bug causes the mount to pick up the sitemap.xmap in the root as the
> sitemap for the mount, thus you will go into an infinite loop if you request
> something that does not match the first match.

This explaines the dozends of dbxml exception and the OutOfMemoryError.
Thanks.

Giacomo


---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Re: Interpreted Sitemap?

Posted by Peter Royal <pr...@managingpartners.com>.
On Wednesday 06 February 2002 04:35 pm, Sylvain Wallez wrote:
> >  <map:pipeline>
> >   <map:match pattern="our-app/**">
> >    <map:mount uri-prefix="our-app"
> >               src="our-app/sitemap.xmap"
> >               check-reload="yes"/>
> >   </map:match>
> >
> >   <map:match pattern="**">
> >    <map:mount uri-prefix=""
> >               src="original.sitemap.xmap"
> >               check-reload="yes"/>
> >   </map:match>
> >
> >   <map:handle-errors>
> >    <map:transform src="stylesheets/system/error2html.xsl"/>
> >    <map:serialize status-code="500"/>
> >   </map:handle-errors>
> >  </map:pipeline>
>
> Peter Royal found a bug that affects mounts that have a file and not a
> directory in their "src" attribute, just as in your sitemap. I'll fix it
> ASAP so you can try again. But I'm really surprised this causes such a
> violent death of the JVM !

The bug causes the mount to pick up the sitemap.xmap in the root as the 
sitemap for the mount, thus you will go into an infinite loop if you request 
something that does not match the first match.
-pete

-- 
peter royal -> proyal@managingpartners.com

---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Re: Interpreted Sitemap?

Posted by giacomo <gi...@apache.org>.
On Wed, 6 Feb 2002, Sylvain Wallez wrote:

> giacomo wrote:
>
> >On Wed, 30 Jan 2002, Sylvain Wallez wrote:

<snipped/>

> >>
> >>Please report any problem you may have with this new engine.
> >>
> >
> >And here it is :)
> >
> >We usually deploy our apps as sub-sitemaps with the following approach:
> >
> >- install an unpacked cocoon.war into the servlet container
> >  (Catalina in our case)
> >- copy the sitemap.xmap to original.sitemp.xmap
> >- in sitemap.xmap strip out all resources, action-sets and pipelines and
> >  leave a:
> >
> >  <map:pipeline>
> >   <map:match pattern="our-app/**">
> >    <map:mount uri-prefix="our-app"
> >               src="our-app/sitemap.xmap"
> >               check-reload="yes"/>
> >   </map:match>
> >
> >   <map:match pattern="**">
> >    <map:mount uri-prefix=""
> >               src="original.sitemap.xmap"
> >               check-reload="yes"/>
> >   </map:match>
> >
> >   <map:handle-errors>
> >    <map:transform src="stylesheets/system/error2html.xsl"/>
> >    <map:serialize status-code="500"/>
> >   </map:handle-errors>
> >  </map:pipeline>
> >
> >A request to http://localhost:8080/cocoon/welcome work smart with the
> >compiled sitemap but with the TreeProcessor it spews alot of
> >
> >"Problem setting up the connection: org.dbxml.client.xmldb.DatabaseImpl"
> >
> >ProcessingExceptions and finally dies an OutOfMemoryError.
> >
> >Any thoughts?
> >
> >Giacomo
> >
> Hi Giacomo,
>
> Peter Royal found a bug that affects mounts that have a file and not a
> directory in their "src" attribute, just as in your sitemap. I'll fix it

I've seen it after my reply :/

> ASAP so you can try again.

Sure, will do, thanks.

Giacomo

> But I'm really surprised this causes such a
> violent death of the JVM !
>
> Sylvain
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Re: Interpreted Sitemap?

Posted by Sylvain Wallez <sy...@anyware-tech.com>.
giacomo wrote:

>On Wed, 30 Jan 2002, Sylvain Wallez wrote:
>
>>shenoy, nitin wrote:
>>
>>><snip>
>>>Stefano wrote
>>>
>>>Have you tried running Cocoon with the interpreted sitemap instead of
>>>the compiled one? in that case, nobody needs to reference the libraries
>>>directly since it would be weblogic's classloader to give them to
>>>Cocoon's classes.
>>>
>>></snip>
>>>
>>>Where would I find info about the interpreted sitemap? I have searched the
>>>archives and I saw a few discussion threads around it on the users group.
>>>
>>>But the last message merely said it was still in development.
>>>
>>>Regards,
>>>Nitin
>>>
>>The interpreted sitemap engine isn't in the official distribution, but
>>in the scratchpad. It is fully functionnal, and the only known issue I
>>know of (I'm currently working on it) is view handling in aggregations.
>>
>>To use it, you'll have to include cocoon-scratchpad.jar in your
>>WEB-INF/lib and change the <sitemap> line in cocoon.xconf into :
>><sitemap class="org.apache.cocoon.treeprocessor.TreeProcessor"
>>logger="sitemap"/>
>>
>>At the first request, you may see an error message complaining about
>>undefined "xmldb" or "parentcm" generators. You'll then have to comment
>>out these pipelines in sitemap.xmap, since the interpreted sitemap is
>>more strict than the compiled engine.
>>
>>Please report any problem you may have with this new engine.
>>
>
>And here it is :)
>
>We usually deploy our apps as sub-sitemaps with the following approach:
>
>- install an unpacked cocoon.war into the servlet container
>  (Catalina in our case)
>- copy the sitemap.xmap to original.sitemp.xmap
>- in sitemap.xmap strip out all resources, action-sets and pipelines and
>  leave a:
>
>  <map:pipeline>
>   <map:match pattern="our-app/**">
>    <map:mount uri-prefix="our-app"
>               src="our-app/sitemap.xmap"
>               check-reload="yes"/>
>   </map:match>
>
>   <map:match pattern="**">
>    <map:mount uri-prefix=""
>               src="original.sitemap.xmap"
>               check-reload="yes"/>
>   </map:match>
>
>   <map:handle-errors>
>    <map:transform src="stylesheets/system/error2html.xsl"/>
>    <map:serialize status-code="500"/>
>   </map:handle-errors>
>  </map:pipeline>
>
>A request to http://localhost:8080/cocoon/welcome work smart with the
>compiled sitemap but with the TreeProcessor it spews alot of
>
>"Problem setting up the connection: org.dbxml.client.xmldb.DatabaseImpl"
>
>ProcessingExceptions and finally dies an OutOfMemoryError.
>
>Any thoughts?
>
>Giacomo
>
Hi Giacomo,

Peter Royal found a bug that affects mounts that have a file and not a 
directory in their "src" attribute, just as in your sitemap. I'll fix it 
ASAP so you can try again. But I'm really surprised this causes such a 
violent death of the JVM !

Sylvain

-- 
Sylvain Wallez
Anyware Technologies - http://www.anyware-tech.com




---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org