forrest-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Crossley <cross...@apache.org>
Subject Re: Cocoon sitemaps and Forrest sitemaps
Date Thu, 16 Mar 2006 23:29:49 GMT
Tim Williams wrote:
> Woods, Christopher wrote:
> >
> > Here is, at least, part of the puzzle: http://wiki.apache.org/cocoon/XMLDBTransformer?highlight=%28xindice%29.
 I'll share a few of my conclusions and welcome anyone on the list to chime in with comments
or suggestions. I realize that this post may seem to be more of a cocoon or xindice post at
times but because the site is ultimately built using forrest I think it's appropriate to post
to this list.
> 
> Have you had a look at:
> http://www.cocooncenter.org/articles/xindice.html ?  Not sure if it
> helps but it sounds like you're querying and not updating so using the
> psuedo-protocol in a generator would be more what you're looking for.
> Though I really have no clue because I've never reallly looked into it
> - just saw that article and thought it may be of use to you if you
> hadn't seen it already.
> 
> > Everything that follows assumes that forrest 0.7 is in use.
> >
> > I have a very lengthy XML file that is validated to a DTD.  This file is to be the
source for a forrest site.  It appeals to me to let forrest handle all the presentation issues
as this will leave me free to focus on the XML data thus freeing me from the drudgery of building,
scripting, and tweaking a web ui (or it will if I ever figure this out).  I want to be able
to update xindice as needed and not have to tinker with the rest of the site.
> >
> > The XML file is about 1.7 MB in size.  Reading through the Xindice site, I have
concluded that it is best to break this file up into smaller chunks before adding it to the
xmldb.
> >
> > Next, I'm using cocoon 2.1.8 which has xindice bundled with it.  I haven't sorted
out how to add my XML documents to the bundled xindice.  Using xindice as a stand-alone, I
simply do startup.bat in $XINDICE_HOME and use the command line to add my documents.  At the
moment, I'm confused about how to "start" the xindice bundle within cocoon as I can't find
the startup.bat file.  Anyway, that's minor, I'll figure it out eventually though if anyone
wants to reply to that I'm most grateful.
> >
> > The rest of the plan is to cut and paste the xmldb transformer:
> >
> > <map:transformers default="xslt">
> >   <map:transformer name="xmldb" src="org.apache.cocoon.transformation.XMLDBTransformer">
> >     <driver>org.apache.xindice.client.xmldb.DatabaseImpl</driver>
> >     <base>xmldb:xindice://localhost:8888/db</base>
> >   </map:transformer>
> >   ...
> > </map:transformers>
> >
> >  from cocoon's sitemap.xmap into my forrest projects $project_home/main/webapp/sitemap.xmap.
 So now forrest should have a connection to xindice.  The wiki has an example called populate.xml
but the link is broken (maybe someone on the list knows the correct location).

Forrest uses only certain "blocks" from Cocoon and we do
not include the "xmldb" block. You can add additional
blocks to your local Forrest by following 
$FORREST_HOME/etc/cocoon_upgrade

You also need to add configuration to
$FORREST_HOME/main/webapp/WEB-INF/xconf/forrest-core.xconf
and declare the new transformers in main/webapp/sitemap.xmap
See note [1] below.

Remember that because you are using Forrest-0.7 then
you will need to get the same version of Cocoon trunk
that was being used at that time.

[1] It is far better to add new functionality via
a Forrest plugin, but to get going quickly you
can add to Forrest core sitemap instead.

Forrest does have a "Databases" plugin in our whiteboard
but i am not sure of its status or purpose.

> > Here is what I think I need to finish this up (purely conjecture):
> >
> > 1.  A pipeline to handle page requests by turning the into XPATH queries, sending
the query to the xmldb, and returning the requested XML document.
> >
> > 2.  A stylesheet to transform the returned document into document-v13 format.
> >
> > This raises the following question:
> >
> > Does forrest use whatever version of cocoon my system variable $COCOON_HOME is set
to or is it bundled with its own cocoon build?  How can I find out which version of cocoon
forrest is using?
> 
> $FORREST_HOME\lib\core\cocoon-XYZ-rABC.jar will give you which Cocoon we're on.

And that is "Cocoon trunk" i.e. Cocoon-2.2

-David

> > Once we get this sorted out, I intend to post the solution on the wiki but there
is still a way to go here.  Anyway, thanks to everyone who has replied so far and anyone who
chimes in as this thread works itself out.
> >
> > Cheers,
> >
> > Chris
> >
> > -----Original Message-----
> > From: J.D. Williams [mailto:jdwilliams@austin.rr.com]
> > Sent: Wednesday, March 15, 2006 4:46 PM
> > To: user@forrest.apache.org
> > Subject: Re: Cocoon sitemaps and Forrest sitemaps
> >
> > Sounds like we're on our own, Chris.
> >
> > :)
> >
> > Joe
> >
> > Thorsten Scherler wrote:
> >
> > > El mi?, 15-03-2006 a las 13:40 -0500, Woods, Christopher escribi?:
> > >
> > >>Hi Folks,
> > >>
> > >>I'm trying to sort out where Forrest ends and Cocoon begins with
> > >>regard to sitemaps.  As best I can tell, the only two sets of sitemaps
> > >>that are used by Forrest are the local-project sitemaps (these are
> > >>processed
> > >>first) and the forrest-home sitemaps (these are processed only if
> > >>local-project does not handle the request).
> > >
> > >
> > > Then there are the sitemaps provided by the plugins and we talking
> > > about "sets". ;) There are million of *.xmaps in forrest (at least it
> > > seems like it). ;)
> > >
> > >
> > >> Am I correct in assuming
> > >>that sitemaps in cocoon-home are only used for instances not processed
> > >>by the forrest-home sitemaps?
> > >
> > >
> > > I do not understand the question.
> > >
> > > If you tell forrest to use them then forrest will use them but if you
> > > place a *.xmap in cocoon forrest will not read it out of the box.
> > >
> > >
> > >>  Thanks very much.
> > >>
> > >>Chris
> > >
> > >
> > > http://forrest.apache.org/docs_0_70/project-sitemap.html
> >
> >
> >

Mime
View raw message