Grzegorz Kossakowski wrote:
Dominic Tootell pisze:
Hi all,

Apologies if this has been sent around before.

Hi Dominic,

Actually, if you was going to apologize for anything cross-posting to two lists would be my first choice. ;-)

I'm trying to figure out how I can access resources outside of a Block jar's, just from a directory within the Webapp:

For example:

I have the simple pipe line:

<map:pipeline>
        <map:match pattern="static/*.shtml">
                <map:generate src="content/{1}.xml"/>
                <map:serialize type="xml"/>
        </map:match>
</map:pipeline>


This is part of the block called Homepage. In Homepage block, I have /src/main/resources/COB-INF/content/index.xml. This is all fine, when access the block via jetty and tomcat, the content/index.xml file is served from COB-INF in the Homepage.jar.

However, I don't want to have to store my xslt, xml and all other static files in a jar. I don't want to have to re-jar the block and redeploy it to tomcat or start up jetty each time I make a small change an xslt.

I want a directory content/ within my webapp, where index.xml is read from there. i.e.:


webapps/Homepage
content/index.xml <---- serve this .xml file so I can make changes to it quickly and see the results

WEB-INF/lib/Homepage.jar <--- don't look at COB-INF/content/index.xml, if the above exists.


This is so I can do RAD development on my local development environment. This was possible in 2.1, but it seems in 2.2 I can't find any documentation on how this is possible. It seems like a simple thing….

Your resources should be always (or almost always) stored in a block. For RAD purposes we have created special helper plug-in[1] for Maven.

You can see it in action here:
http://people.apache.org/~gkossakowski/cocoon-tutorial-rcl-2.html

Oh gosh, I forgot that I promised to publish it officially on our site. I'll try to do it over this weekend.

[1] http://cocoon.apache.org/2.2/maven-plugins/maven-plugin/1.0/1295_1_1.html


Thanks for the tutorial video. The more of these the better for those of us who don't yet know
Java, Maven, Eclipse, ...

BUT... at the end of the video you say "Isn't that really really RAPID development?"

My answer is "No, not compared with editing the sitemap or other static file and pressing refresh in my Browser. That's been my working method for several years of Cocoon use."

OK, so this is more like minor tweaking than 'development' but that's the way I like
to do things.

Please make this possible again, or if it already is possible, tell us how.


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

Reply via email to