David Podunavac wrote:
I am David, some of you might remember me from the ApacheCon this year,
anyway I heard the need of joinin LENYA and FORREST and the discussion
monday late night.
Good to "see" you again.
<snipped what="some background info on Lenya processing"/>
here are some tries or ideas on how lenya and forrest could/should work
together
this MARRIAGE(joining lenya and forrest) what i call it now could be
done on the publication-sitemap.xmap level
There are two aspects to integration of Forrest and Lenya. The first is
the publication aspect, but the Lenya folk also want to leverage the
input side of Forrest. However, since publication is the easier part (at
least to me as a Forrest dev) lets focus on that first.
when we look at the sitemaps of lenya and forrest we will see that they
look alike
take a look at the publication-sitemap.xmap
@lenya-1.2.x/build/lenya/webapp/lenya/pubs/default/
of a clean lenya lines 120ff.
<snip what="lenya sitemap snippet"/>
[Note I am confused about this publication-sitemap.xmap file. Does
publication in its title mean the publication of documents, or is it the
publication that make up a Lenya site? I suspect it is the later very
confusing!]
and compare this to forrest sitemap.xmap @forrest/main/sitemap
<snip what="forrest sitemap snippet"/>
our plan is to integrate forrest into lenya (hope that is okay
with you forrest guys :) )
to do so marcin mentioned that:
lenya should do the matching on the first level than
forrest should receive the content like (menus, tabs, body) from lenya
and transform this content into forrest conform content (so this
content could be used in forrest)
after this step lenya lets forrest do the all the styling
For Forrest a request of http://localhost:8888/index.html is processed
as follows:
src -> [input plugin] -> core -> skin -> [output plugin]
Forrest core would make additional requests for different parts of the
page (such as navigation and tabs). So this one reqest would actually
create a number of the above processes to be executed.
You sugest (below) that we create a new sitemap to enable Forrest to
publish content, I'm not sure this is the right approach. Both Lenya and
Forrest are moving targets and keeping these sitemaps synchronised will
require maintenance by someone with a foot in both camps. What we really
need is a way of integrating things in a much more maintainable way.
In the new Locationmap functionality in Forrest 0.8-dev (see
http://forrest.apache.org/docs_0_80/locationmap.html ) we can map a
request for a particular file to a defined location. So for example.
FORREST FILE | LENYA FILE
---------------+-------------
site.xml | ????
tabs.xml | ????
*.xml | ????
If lenya can expose the relevant equivalent files via a URL then we
simply map the forrest rquired files to the relevant Lenya URL. Then we
create a forrest:view that will produce the output that Lenya needs and
we are done.
Since all data is request directly from Lenya there is no complexities
with user management and the like as Lenya still has control over all
this stuff. However, I've not yet thought about how Forrest will pass
authentication information back and forth. I'd have to explore the
authentication used in Lenya first.
All the existing publication (as in creating the output) pipelines in
lenyas sitemaps are removed. All publication is handled by Forrest.
I created a very simple demo of this some time back as a result of a
discussion with Gregor see
http://marc.theaimsgroup.com/?l=forrest-dev&m=111814596828488&w=2
Ross