Andre Juffer wrote:
> Reinhard Poetz wrote:
Apart from that, having a block doesn't necessarily require a Cocoon
web application with configured servlet services being part of it.
It's also a valid use case to have blocks that only contain Java
resources and Spring beans (e.g. for domain specific logic).
If this block would contain only classes and relevant resources
pertinent to these classes that otherwise have absolutely no knowledge
at all of cocoon, it should not even be required to create a cocoon
block. Such a set of classes could be contained in a standard maven
project, which can be created like
mvn archetype:create -DgroupId=com.mycompany.app -DartifactId=my-app
(see
http://maven.apache.org/guides/getting-started/maven-in-five-minutes.html)
One would simply use the standard install goal to create a jar upon
which the webapp would depend. The only problem I can see at this point
is an application-context.xml that is possibly contained in that jar.
The cocoon-based webapp only needs to be made aware of that file. But
this could possible handled by an import statement in the cocoon
application.context.xml (see for instance
http://static.springframework.org/spring/docs/2.5.x/reference/beans.html#beans-factory-instantiation)
You only have to put your Spring bean configuration file (*.xml) into the
META-INF/cocoon/spring/ directory. Cocoon will pick it up automatically and add
all components to the global Spring application context.
--
Reinhard Pötz Managing Director, {Indoqa} GmbH
http://www.indoqa.com/en/people/reinhard.poetz/
Member of the Apache Software Foundation
Apache Cocoon Committer, PMC member, PMC Chair [EMAIL PROTECTED]
_________________________________________________________________________
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]