You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Carsten Ziegeler <cz...@apache.org> on 2006/11/03 23:17:11 UTC

[2.2] Runtime deployment

With the help from Leszek we now have a Cocoon version in trunk which
does not need any deployment plugin. This means you can just drop the
jar files into WEB-INF/lib and are done! So it doesn't matter if you're
using Maven, Ant or some other strange tool :)
All you need is the main Spring applicationContext.xml with our two
elements for setting up Cocoon and the Avalon bridge.

So, what has changed?
We now load all configuration files directly from within the jar files,
so all files in META-INF/cocoon/avalon, META-INF/cocoon/spring and
META-INF/cocoon/properties are applied at runtime without the need to
extract these files.

Currently on startup of Cocoon, all COB-INF directories are extracted to
{webapp-directory}/blocks/{block-name}.

What is missing?
1. With the changes from above, Cocoon does not run as an unexpanded war
file anymore. So I think we should extract the COB-INF directory into
the temporary directory and mount the blocks from there. This should be
very simple to change.
2. We should check on startup if we need to extract a COB-INF directory
again. If anyone has a good idea how to check this without too much work
would be great.
3. Update to our deployer plugins (and perhaps archetypes) - we changed
some directory names and obviously the deployment has changed. So we
should check if all our plugins, development procedures, archetypes etc.
are still working. I just tested the core-webapp.

Once we have solved these three issues we should release a RC-1 asap.

Carsten
-- 
Carsten Ziegeler - Chief Architect
http://www.s-und-n.de
http://www.osoco.org/weblogs/rael/

Re: [2.2] Runtime deployment

Posted by Leszek Gawron <lg...@mobilebox.pl>.
Carsten Ziegeler wrote:
> What is missing?
> 1. With the changes from above, Cocoon does not run as an unexpanded war
> file anymore. So I think we should extract the COB-INF directory into
> the temporary directory and mount the blocks from there. This should be
> very simple to change.
> 2. We should check on startup if we need to extract a COB-INF directory
> again. If anyone has a good idea how to check this without too much work
> would be great.
> 3. Update to our deployer plugins (and perhaps archetypes) - we changed
> some directory names and obviously the deployment has changed. So we
> should check if all our plugins, development procedures, archetypes etc.
> are still working. I just tested the core-webapp.

4. now we are unable to override default .xconf files. When they were 
unpacked from jar files they could be later on overwritten with own 
xconf version (especially useful for trimming down default 
cocoon-core-sitemap.xmap which is laaarge). Now there is no such 
possibility. The file will at best be loaded _additionally_ to the 
original one.

-- 
Leszek Gawron                                    CTO at MobileBox Ltd.


Re: [2.2] Runtime deployment

Posted by Leszek Gawron <lg...@mobilebox.pl>.
Leszek Gawron wrote:
> 
> I am trying to fix it now.
> 

fixed. One more difference of cocoon deployer plugin vs. DeployerUtil: 
blocks are unpacked to block-name-version instead of block-name:

c:\dev\projects\XXX-pi\server\webapp\target\XXX-pi-server-webapp-1.0.0-SNAPSHOT\blocks\XXX-pi-server-piapi-1.0.0-SNAPSHOT

while it should be:
c:\dev\projects\XXX-pi\server\webapp\target\XXX-pi-server-webapp-1.0.0-SNAPSHOT\blocks\XXX-pi-server-piapi

otherwise every time you up the version number you will have to adjust 
your main sitemap.xmap:

<map:match pattern="piapi/**">
   <map:mount uri-prefix="piapi" src="blocks/XXX-pi-server-piapi/"/>
</map:match>


There's more: cocoon will not start up correctly if you leave

   <!--+
       | Include all configuration files ending with ".xconf"
       | from the xconf directory.
       +-->
   <include dir="context://WEB-INF/cocoon/avalon" pattern="*.xconf"/>

uncommented in cocoon-core.jar!/org/apache/cocoon/cocoon.xconf

The directory does not exist by default and include will fail.

-- 
Leszek Gawron                                    CTO at MobileBox Ltd.


Re: [2.2] Runtime deployment

Posted by Leszek Gawron <lg...@mobilebox.pl>.
Carsten Ziegeler wrote:
> 3. Update to our deployer plugins (and perhaps archetypes) - we changed
> some directory names and obviously the deployment has changed. So we
> should check if all our plugins, development procedures, archetypes etc.
> are still working. I just tested the core-webapp.
DeployerUtils breaks because it constructs some invalid paths:

> 3640 [main] ERROR org.springframework.web.context.ContextLoader - Context initialization failed
> org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.apache.cocoon.configuration.Settings': Invocation of init
> method failed; nested exception is java.io.FileNotFoundException: C:\dev\projects\viessmann-pi\server\webapp\target\viessmann-pi-server-webapp-1.0.0-S
> NAPSHOT\blocks\C:\Documents and Settings\lgawron\.m2\repository\com\mobilebox\viessmann-pi\server\viessmann-pi-server-piapi\1.0.0-SNAPSHOT\viessmann-p
> i-server-piapi-1.0.0-SNAPSHOT.jar\sitemap.xmap (Nazwa pliku, nazwa katalogu lub sk│adnia etykiety woluminu jest niepoprawna)
> Caused by: java.io.FileNotFoundException: C:\dev\projects\viessmann-pi\server\webapp\target\viessmann-pi-server-webapp-1.0.0-SNAPSHOT\blocks\C:\Docume
> nts and Settings\lgawron\.m2\repository\com\mobilebox\viessmann-pi\server\viessmann-pi-server-piapi\1.0.0-SNAPSHOT\viessmann-pi-server-piapi-1.0.0-SNA
> PSHOT.jar\sitemap.xmap (Nazwa pliku, nazwa katalogu lub sk│adnia etykiety woluminu jest niepoprawna)
>         at java.io.FileOutputStream.open(Native Method)
>         at java.io.FileOutputStream.<init>(FileOutputStream.java:179)
>         at java.io.FileOutputStream.<init>(FileOutputStream.java:131)
>         at org.apache.cocoon.core.deployment.DeploymentUtil.deploy(DeploymentUtil.java:74)
>         at org.apache.cocoon.core.deployment.DeploymentUtil.deployBlockResources(DeploymentUtil.java:104)
>         at org.apache.cocoon.core.deployment.DeploymentUtil.deploy(DeploymentUtil.java:114)
>         at org.apache.cocoon.core.container.spring.SettingsBeanFactoryPostProcessor.init(SettingsBeanFactoryPostProcessor.java:64)


I am trying to fix it now.

-- 
Leszek Gawron                                    CTO at MobileBox Ltd.


Re: [2.2] Runtime deployment

Posted by Leszek Gawron <lg...@mobilebox.pl>.
Leszek Gawron wrote:
> Giacomo Pati wrote:
>> Class org.apache.cocoon.maven.deployer.monolithic.DevelopmentBlock has
>> no such attribute: sitemapAdditionsConfPath in template context
>> [anonymous anonymous]
>> java.lang.NoSuchFieldException: sitemapAdditionsConfPath
>>         at java.lang.Class.getField(Class.java:1507)
>>         at
>> org.antlr.stringtemplate.language.ASTExpr.getObjectProperty(ASTExpr.java:328) 
>>
>> ...
>>         at
>> org.apache.cocoon.maven.deployer.monolithic.MonolithicCocoonDeployer.writeStringTemplateToFile(MonolithicCocoonDeployer.java:216) 
>>
>>
>> I havn't see the remove of the isSitemapAdditionsConfPath method from
>> the DevelopmentBlock class. If I remove the
>>
>>
>> $if(devblock.sitemapAdditionsConfPath)$
>>   <include dir="$devblock.sitemapAdditionsConfPath$" pattern="*.xmap"/>
>> $endif$
>>
>> part from the
>> tools/cocoon-block-deployer/cocoon-deployer-plugin/src/main/resources/org/apache/cocoon/maven/deployer/monolithic/WEB-INF/cocoon/cocoon.xconf 
>>
>> (dunno whether this is still needed but I guess not anymore).
> 
> you're right - this is not needed. I have removed the entry but the 
> deployer still needs fixing - I see it tries to load the config files 
> the old way from src/main/resources/META-INF/cocoon:

There is a major flaw in locally testing a development block: 
classloading. Deploying a dvelopment block is different from standard 
procedure. None of the resources are copied to webapp directory. They 
are referenced from source.

We are reading now spring/properties configuration directly from 
classpath. The problem is that block's classpath resources are being 
mounted with reloading class loader using target/classes folder.

The mount is being created at block's sitemap level. This is what causes 
the problem:

- core will not pick up spring/properties/avalon files now
- even if we mount the files directly from source it will not do much 
good because core will not be able to find classes for beans defined in 
block/META-INF/cocoon/spring/*.xml

The only scenario that works now is when the devlelopment block has some 
COB-INF resources and does not contribute any classes to core. In other 
words any spring/avalon context is contributed at 
COB-INF/config/{spring|avalon} level)

This is not the fault of latest changes (it just made some problems more 
visible).

We somehow have to make cocoon see development block classes at root 
classloader level. Any clues?

-- 
Leszek Gawron                                    CTO at MobileBox Ltd.


Re: [2.2] Runtime deployment

Posted by Carsten Ziegeler <cz...@apache.org>.
Leszek Gawron wrote:
> Not waiting for answers to my post I have removed the support for 
> WEB-INF/cocoon/* completely. It's not needed anymore. See 
> http://svn.apache.org/viewvc?view=rev&rev=471167 for changes.
:) You're really quick! You're absolutely right that we don't need these
directories anymore, the only drawback I see right now is the "META-INF"
in the directory path, but I think we can live with that.

> 
>> After mkdir target/project-0.1.0-SNAPSHOT/WEB-INF/cocoon/avalon I get
>>
>> Embedded error: Unable to initialize Avalon component with role
>> org.apache.cocoon.Processor; nested exception is
>> org.apache.avalon.framework.configuration.ConfigurationException: Cannot
>> resolve sitemap.xmap
>> Component with 'org.apache.excalibur.source.SourceFactory/*' is not
>> defined in this service manager. (Key='AvalonServiceManager')
> 
> <.../>
> 
>> I actually have no clue sincce when a lookup with a .../* has been
>> allowed. Anybody esle (Carsten?)
The "*" is the name of the component, there should be a component
definition for this source factory. It's the default source factory
handling the all jdk protocols (file, http etc.)

Carsten

-- 
Carsten Ziegeler - Chief Architect
http://www.s-und-n.de
http://www.osoco.org/weblogs/rael/

Re: [2.2] Runtime deployment

Posted by Leszek Gawron <lg...@mobilebox.pl>.
Giacomo Pati wrote:
> Class org.apache.cocoon.maven.deployer.monolithic.DevelopmentBlock has
> no such attribute: sitemapAdditionsConfPath in template context
> [anonymous anonymous]
> java.lang.NoSuchFieldException: sitemapAdditionsConfPath
>         at java.lang.Class.getField(Class.java:1507)
>         at
> org.antlr.stringtemplate.language.ASTExpr.getObjectProperty(ASTExpr.java:328)
> ...
>         at
> org.apache.cocoon.maven.deployer.monolithic.MonolithicCocoonDeployer.writeStringTemplateToFile(MonolithicCocoonDeployer.java:216)
> 
> I havn't see the remove of the isSitemapAdditionsConfPath method from
> the DevelopmentBlock class. If I remove the
> 
> 
> $if(devblock.sitemapAdditionsConfPath)$
>   <include dir="$devblock.sitemapAdditionsConfPath$" pattern="*.xmap"/>
> $endif$
> 
> part from the
> tools/cocoon-block-deployer/cocoon-deployer-plugin/src/main/resources/org/apache/cocoon/maven/deployer/monolithic/WEB-INF/cocoon/cocoon.xconf
> (dunno whether this is still needed but I guess not anymore).

you're right - this is not needed. I have removed the entry but the 
deployer still needs fixing - I see it tries to load the config files 
the old way from src/main/resources/META-INF/cocoon:

>         springConfPath = checkDir(new File(localPath, RESOURCES_DIR + "META-INF/cocoon/spring"));
>         xconfConfPath = checkDir(new File(localPath, RESOURCES_DIR + "META-INF/cocoon/avalon"));
>         xPatchPath = checkDir(new File(localPath, RESOURCES_DIR + "META-INF/xpatch"));
>         targetClassesPath = checkDir(new File(localPath, "target/classes"));
>         cobInfPath = checkDir(new File(localPath, RESOURCES_DIR + "COB-INF"));
>         propsPath = checkDir(new File(localPath, RESOURCES_DIR + "META-INF/cocoon/properties"));

and this will definitely lead to loading those files twice (once from 
this dir, second one from classpath).

I will try to fix this today (already rushing the clock). Stay tuned :)

> 2. running
> 
> Now jetty6:run failes with
> 
> Embedded error: Cannot invoke listener
> org.springframework.web.context.ContextLoaderListener@157bf4c
> Directory 'context://WEB-INF/cocoon/avalon' does not exist
> (jar:file:/home/giacomo/svn/projects/project/target/project-0.1.0-SNAPSHOT/WEB-INF/cocoon/lib/cocoon-core-2.2.0-M2-SNAPSHOT.jar!/org/apache/cocoon/cocoon.xconf:41:69).
> 
> Seems the avalon directory is required (we have to make it optional!)
Not waiting for answers to my post I have removed the support for 
WEB-INF/cocoon/* completely. It's not needed anymore. See 
http://svn.apache.org/viewvc?view=rev&rev=471167 for changes.

If there's anyone who needs the support for WEB-INF/cocoon (though I 
clearly see no reason because one can use 
WEB-INF/classes/META-INF/cocoon instead) then the change is in one 
commit - easily reversible.

> 
> After mkdir target/project-0.1.0-SNAPSHOT/WEB-INF/cocoon/avalon I get
> 
> Embedded error: Unable to initialize Avalon component with role
> org.apache.cocoon.Processor; nested exception is
> org.apache.avalon.framework.configuration.ConfigurationException: Cannot
> resolve sitemap.xmap
> Component with 'org.apache.excalibur.source.SourceFactory/*' is not
> defined in this service manager. (Key='AvalonServiceManager')

<.../>

> I actually have no clue sincce when a lookup with a .../* has been
> allowed. Anybody esle (Carsten?)
This one does not happen for me. I have tested two of my current 
projects - both start up fine.

-- 
Leszek Gawron                                    CTO at MobileBox Ltd.


Re: [2.2] Runtime deployment

Posted by Giacomo Pati <gi...@apache.org>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1



Carsten Ziegeler wrote:
> With the help from Leszek we now have a Cocoon version in trunk which
> does not need any deployment plugin. This means you can just drop the
> jar files into WEB-INF/lib and are done! So it doesn't matter if you're
> using Maven, Ant or some other strange tool :)
> All you need is the main Spring applicationContext.xml with our two
> elements for setting up Cocoon and the Avalon bridge.
> 
> So, what has changed?
> We now load all configuration files directly from within the jar files,
> so all files in META-INF/cocoon/avalon, META-INF/cocoon/spring and
> META-INF/cocoon/properties are applied at runtime without the need to
> extract these files.
> 
> Currently on startup of Cocoon, all COB-INF directories are extracted to
> {webapp-directory}/blocks/{block-name}.
> 
> What is missing?
> 1. With the changes from above, Cocoon does not run as an unexpanded war
> file anymore. So I think we should extract the COB-INF directory into
> the temporary directory and mount the blocks from there. This should be
> very simple to change.
> 2. We should check on startup if we need to extract a COB-INF directory
> again. If anyone has a good idea how to check this without too much work
> would be great.
> 3. Update to our deployer plugins (and perhaps archetypes) - we changed
> some directory names and obviously the deployment has changed. So we
> should check if all our plugins, development procedures, archetypes etc.
> are still working. I just tested the core-webapp.

I've quick checked a Cocoon Block (mvn -X clean install jetty6:run). I
got the following failure:

1. building/deploying

Class org.apache.cocoon.maven.deployer.monolithic.DevelopmentBlock has
no such attribute: sitemapAdditionsConfPath in template context
[anonymous anonymous]
java.lang.NoSuchFieldException: sitemapAdditionsConfPath
        at java.lang.Class.getField(Class.java:1507)
        at
org.antlr.stringtemplate.language.ASTExpr.getObjectProperty(ASTExpr.java:328)
...
        at
org.apache.cocoon.maven.deployer.monolithic.MonolithicCocoonDeployer.writeStringTemplateToFile(MonolithicCocoonDeployer.java:216)

I havn't see the remove of the isSitemapAdditionsConfPath method from
the DevelopmentBlock class. If I remove the


$if(devblock.sitemapAdditionsConfPath)$
  <include dir="$devblock.sitemapAdditionsConfPath$" pattern="*.xmap"/>
$endif$

part from the
tools/cocoon-block-deployer/cocoon-deployer-plugin/src/main/resources/org/apache/cocoon/maven/deployer/monolithic/WEB-INF/cocoon/cocoon.xconf
(dunno whether this is still needed but I guess not anymore).


2. running

Now jetty6:run failes with

Embedded error: Cannot invoke listener
org.springframework.web.context.ContextLoaderListener@157bf4c
Directory 'context://WEB-INF/cocoon/avalon' does not exist
(jar:file:/home/giacomo/svn/projects/project/target/project-0.1.0-SNAPSHOT/WEB-INF/cocoon/lib/cocoon-core-2.2.0-M2-SNAPSHOT.jar!/org/apache/cocoon/cocoon.xconf:41:69).

Seems the avalon directory is required (we have to make it optional!)

After mkdir target/project-0.1.0-SNAPSHOT/WEB-INF/cocoon/avalon I get

Embedded error: Unable to initialize Avalon component with role
org.apache.cocoon.Processor; nested exception is
org.apache.avalon.framework.configuration.ConfigurationException: Cannot
resolve sitemap.xmap
Component with 'org.apache.excalibur.source.SourceFactory/*' is not
defined in this service manager. (Key='AvalonServiceManager')
[INFO]
- ------------------------------------------------------------------------
[DEBUG] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Failure
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:559)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:488)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:458)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:306)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:273)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:140)
        at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:322)
        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
        at org.apache.maven.cli.MavenCli.main(MavenCli.java:256)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:585)
        at
org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
        at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
        at
org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
        at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.plugin.MojoExecutionException: Failure
        at
org.mortbay.jetty.plugin.AbstractJettyMojo.startJetty(AbstractJettyMojo.java:296)
        at
org.mortbay.jetty.plugin.AbstractJettyMojo.execute(AbstractJettyMojo.java:242)
        at
org.mortbay.jetty.plugin.AbstractJettyRunMojo.execute(AbstractJettyRunMojo.java:122)
        at
org.mortbay.jetty.plugin.Jetty6RunMojo.execute(Jetty6RunMojo.java:160)
        at
org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:412)
        at
org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:534)
        ... 16 more
Caused by: org.springframework.beans.factory.BeanCreationException:
Unable to initialize Avalon component with role
org.apache.cocoon.Processor; nested exception is
org.apache.avalon.framework.configuration.ConfigurationException: Cannot
resolve sitemap.xmap
        at
org.apache.cocoon.core.container.spring.avalon.AvalonBeanPostProcessor.postProcessBeforeInitialization(AvalonBeanPostProcessor.java:247)
        at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyBeanPostProcessorsBeforeInitialization(AbstractAutowireCapableBeanFactory.java:297)
        at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1025)
        at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:420)
        at
org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:245)
        at
org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:141)
        at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:242)
        at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:156)
        at
org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:642)
        at
org.apache.cocoon.servlet.RequestProcessor.<init>(RequestProcessor.java:99)
        at
org.apache.cocoon.servlet.SitemapServlet.init(SitemapServlet.java:49)
        at javax.servlet.GenericServlet.init(GenericServlet.java:283)
        at
org.apache.cocoon.bootstrap.servlet.ShieldingServlet.init(ShieldingServlet.java:92)
        at
org.mortbay.jetty.servlet.ServletHolder.initServlet(ServletHolder.java:377)
        at
org.mortbay.jetty.servlet.ServletHolder.doStart(ServletHolder.java:234)
        at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:37)
        at
org.mortbay.jetty.servlet.ServletHandler.initialize(ServletHandler.java:565)
        at
org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:961)
        at
org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:341)
        at
org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:367)
        at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:37)
        at
org.mortbay.jetty.handler.HandlerCollection.doStart(HandlerCollection.java:101)
        at org.mortbay.jetty.Server.doStart(Server.java:235)
        at
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:37)
        at
org.mortbay.jetty.plugin.Jetty6PluginServer.start(Jetty6PluginServer.java:114)
        at
org.mortbay.jetty.plugin.AbstractJettyMojo.startJetty(AbstractJettyMojo.java:285)
        ... 21 more
Caused by:
org.apache.avalon.framework.configuration.ConfigurationException: Cannot
resolve sitemap.xmap
        at
org.apache.cocoon.components.treeprocessor.TreeProcessor.configure(TreeProcessor.java:215)
        at
org.apache.avalon.framework.container.ContainerUtil.configure(ContainerUtil.java:201)
        at
org.apache.cocoon.core.container.spring.avalon.AvalonBeanPostProcessor.postProcessBeforeInitialization(AvalonBeanPostProcessor.java:236)
        ... 46 more
Caused by: org.apache.excalibur.source.SourceException: Unable to select
source factory for sitemap.xmap
        at
org.apache.cocoon.components.source.CocoonSourceResolver.resolveURI(CocoonSourceResolver.java:168)
        at
org.apache.cocoon.components.source.CocoonSourceResolver.resolveURI(CocoonSourceResolver.java:182)
        at
org.apache.cocoon.components.treeprocessor.TreeProcessor.configure(TreeProcessor.java:213)
        ... 48 more
Caused by: org.apache.cocoon.ProcessingException: Unable to lookup
source factory for scheme: *
        at
org.apache.cocoon.components.source.CocoonSourceResolver.getSourceFactory(CocoonSourceResolver.java:228)
        at
org.apache.cocoon.components.source.CocoonSourceResolver.resolveURI(CocoonSourceResolver.java:161)
        ... 50 more
Caused by: org.apache.avalon.framework.service.ServiceException:
Component with 'org.apache.excalibur.source.SourceFactory/*' is not
defined in this service manager. (Key='AvalonServiceManager')
        at
org.apache.cocoon.core.container.spring.avalon.AvalonServiceManager.lookup(AvalonServiceManager.java:57)
        at
org.apache.cocoon.components.source.CocoonSourceResolver.getSourceFactory(CocoonSourceResolver.java:226)
        ... 51 more

I actually have no clue sincce when a lookup with a .../* has been
allowed. Anybody esle (Carsten?)

Ciao

- --
Giacomo Pati
Otego AG, Switzerland - http://www.otego.com
Orixo, the XML business alliance - http://www.orixo.com

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (GNU/Linux)

iD8DBQFFTGgMLNdJvZjjVZARAnUhAJ0ew1DKsHRXIEV2A4h06RVpIwiY5ACgm+pD
3Mz1D0NpgRvwzqaWhA4ov0A=
=AIND
-----END PGP SIGNATURE-----

Re: [2.2] Runtime deployment

Posted by Daniel Fagerstrom <da...@nada.kth.se>.
Jorg Heymans skrev:
> 
> Daniel Fagerstrom wrote:
> 
>>
>> We could use the artifactId from the 
>> META-INF/maven/org.apache.cocoon/cocoon-block-name/pom.properties file.
> 
> pom.properties is included by default, but it's inclusion can be 
> disabled. For this I think the manifest entry would be a better option 
> here.

Agree

>> Maven also sometimes (?) creates some field in the manifest file that 
>> could be used e.g.:
>>
>> Manifest-Version: 1.0
>> Archiver-Version: Plexus Archiver
>> Created-By: Apache Maven
>> Built-By: maven
>> Build-Jdk: 1.4.2_06
>> Extension-Name: cocoon-batik-impl
>> Specification-Title:
>> Specification-Vendor: The Apache Software Foundation
>> Implementation-Vendor: The Apache Software Foundation
>> Implementation-Title: cocoon-batik-impl
>> Implementation-Version: 1.0.0-SNAPSHOT
>>
>> I doesn't create such manifest files all the time though. The jars 
>> created when I compile locally with Maven 2.0.4 looks like:
>>
>> Manifest-Version: 1.0
>> Archiver-Version: Plexus Archiver
>> Created-By: Apache Maven
>> Built-By: Daniel Fagerstrom
>> Build-Jdk: 1.5.0_06
> 
> The generated default manifest is different for artifacts produced using 
> mvn deploy/release versus those produced using mvn install.

OK

>> One possibility would to have a block specific manifest entry with the 
>> block name:
>>
>> Cocoon-Block-Name: cocoon-batik-impl
> 
> Yup, just include this in the root pom:
> 
> <plugin>
>   <groupId>org.apache.maven.plugins</groupId>
>   <artifactId>maven-jar-plugin</artifactId>
>   <version>2.1</version>
>   <configuration>
>     <archive>
>       <manifestEntries>
>         <Cocoon-Block-Name>${pom.artifactId}</Cocoon-Block-Name>
>       </manifestEntries>
>     </archive>
>   </configuration>
> </plugin>

So, the conclusion this far is that we cannot use jar file name or 
information that Maven happen to generate anyway for getting the block 
name. We have to add the block name ourselves i some way.

Having the block name in the manifest is convenient as it is easy to 
read from jars and it is fairly easy to set up in a POM as Jorg showed.

A possible drawback is that Maven generated manifest info might be hsrd 
to use during development in a IDE. Especially for Eclipse it might be a 
problem to use the manifest file as Eclipse AFAIU requires the manifest 
to be in the root of the project.

Another solution that is somewhat less convenient but might work better 
with IDEs, would be to put the block name in a block property file, 
COB-INF/block.properties e.g.

/Daniel


Re: [2.2] Runtime deployment

Posted by Jorg Heymans <jh...@apache.org>.
Daniel Fagerstrom wrote:

> 
> We could use the artifactId from the 
> META-INF/maven/org.apache.cocoon/cocoon-block-name/pom.properties file.

pom.properties is included by default, but it's inclusion can be 
disabled. For this I think the manifest entry would be a better option 
here.

> 
> Maven also sometimes (?) creates some field in the manifest file that 
> could be used e.g.:
> 
> Manifest-Version: 1.0
> Archiver-Version: Plexus Archiver
> Created-By: Apache Maven
> Built-By: maven
> Build-Jdk: 1.4.2_06
> Extension-Name: cocoon-batik-impl
> Specification-Title:
> Specification-Vendor: The Apache Software Foundation
> Implementation-Vendor: The Apache Software Foundation
> Implementation-Title: cocoon-batik-impl
> Implementation-Version: 1.0.0-SNAPSHOT
> 
> I doesn't create such manifest files all the time though. The jars 
> created when I compile locally with Maven 2.0.4 looks like:
> 
> Manifest-Version: 1.0
> Archiver-Version: Plexus Archiver
> Created-By: Apache Maven
> Built-By: Daniel Fagerstrom
> Build-Jdk: 1.5.0_06

The generated default manifest is different for artifacts produced using 
mvn deploy/release versus those produced using mvn install.

> One possibility would to have a block specific manifest entry with the 
> block name:
> 
> Cocoon-Block-Name: cocoon-batik-impl

Yup, just include this in the root pom:

<plugin>
   <groupId>org.apache.maven.plugins</groupId>
   <artifactId>maven-jar-plugin</artifactId>
   <version>2.1</version>
   <configuration>
     <archive>
       <manifestEntries>
         <Cocoon-Block-Name>${pom.artifactId}</Cocoon-Block-Name>
       </manifestEntries>
     </archive>
   </configuration>
</plugin>


HTH
Jorg


Re: [2.2] Runtime deployment

Posted by Daniel Fagerstrom <da...@nada.kth.se>.
Carsten Ziegeler skrev:
> Leszek Gawron wrote:
>>> What is missing?
>>> 1. With the changes from above, Cocoon does not run as an unexpanded war
>>> file anymore. So I think we should extract the COB-INF directory into
>>> the temporary directory and mount the blocks from there. This should be
>>> very simple to change.
>> apart from one thing, how do I do that?:
>>> <map:match pattern="mobile/**">
>>>     <map:mount uri-prefix="mobile" src="blocks/geminismart-server-mobile/"/>
>>> </map:match>
>>> <map:match pattern="central/**">
>>>     <map:mount uri-prefix="central" src="blocks/geminismart-server-central/"/>
>>> </map:match>
>>> <map:match pattern="**">
>>>     <map:mount uri-prefix="" src="blocks/mobilebox-webapp-commons/"/>
>>> </map:match>
>> when I get block files unpacked to some temporary directory which 
>> location can change any time.
>>
> We could provide our own protocol "temp:" which is resolved to the
> temporary directory, so you can use
> "temp://blocks/geminismart-server-mobile/" for example.

I would prefer blockcontext:/geminismart-server-mobile/ or 
blockcontext:geminismart-server-mobile/ as the COB-INF directory in a 
block has the same role as a resource directory as the top level 
directory for a webapp.

An open question is how to find the block name. I doubt that version 
numbering is systematic enough to make it possible to strip it away from 
the block name for the file name of the block jar.

We could use the artifactId from the 
META-INF/maven/org.apache.cocoon/cocoon-block-name/pom.properties file.

Maven also sometimes (?) creates some field in the manifest file that 
could be used e.g.:

Manifest-Version: 1.0
Archiver-Version: Plexus Archiver
Created-By: Apache Maven
Built-By: maven
Build-Jdk: 1.4.2_06
Extension-Name: cocoon-batik-impl
Specification-Title:
Specification-Vendor: The Apache Software Foundation
Implementation-Vendor: The Apache Software Foundation
Implementation-Title: cocoon-batik-impl
Implementation-Version: 1.0.0-SNAPSHOT

I doesn't create such manifest files all the time though. The jars 
created when I compile locally with Maven 2.0.4 looks like:

Manifest-Version: 1.0
Archiver-Version: Plexus Archiver
Created-By: Apache Maven
Built-By: Daniel Fagerstrom
Build-Jdk: 1.5.0_06

One possibility would to have a block specific manifest entry with the 
block name:

Cocoon-Block-Name: cocoon-batik-impl

/Daniel


Re: [2.2] Runtime deployment

Posted by Leszek Gawron <lg...@mobilebox.pl>.
Carsten Ziegeler wrote:
> Leszek Gawron wrote:
>>> What is missing?
>>> 1. With the changes from above, Cocoon does not run as an unexpanded war
>>> file anymore. So I think we should extract the COB-INF directory into
>>> the temporary directory and mount the blocks from there. This should be
>>> very simple to change.
>> apart from one thing, how do I do that?:
>>> <map:match pattern="mobile/**">
>>>     <map:mount uri-prefix="mobile" src="blocks/geminismart-server-mobile/"/>
>>> </map:match>
>>> <map:match pattern="central/**">
>>>     <map:mount uri-prefix="central" src="blocks/geminismart-server-central/"/>
>>> </map:match>
>>> <map:match pattern="**">
>>>     <map:mount uri-prefix="" src="blocks/mobilebox-webapp-commons/"/>
>>> </map:match>
>> when I get block files unpacked to some temporary directory which 
>> location can change any time.
>>
> We could provide our own protocol "temp:" which is resolved to the
> temporary directory, so you can use
> "temp://blocks/geminismart-server-mobile/" for example.
> 
>>> 2. We should check on startup if we need to extract a COB-INF directory
>>> again. If anyone has a good idea how to check this without too much work
>>> would be great.
>> wouldn't it be sufficient if we checked for blocks/block-name directory 
>> existence?
> Hm, it depends - this assumes that an artifact during development never
> changes. But for example if you're using "1.0-SNAPSHOT" the content will
> change during development but the block-name will not. My first idea was
> to put the jar size in the temp directory as well and only extract if
> the size has changed. (I'm not sure if the size is a reachable
> information though).
If your development block changes most of the time you will do a mvn 
clean, ant clean or analogous operation anyway...

-- 
Leszek Gawron                                    CTO at MobileBox Ltd.


Re: [2.2] Runtime deployment

Posted by Alexander Klimetschek <al...@mindquarry.com>.
Carsten Ziegeler schrieb:
> Hm, it depends - this assumes that an artifact during development never
> changes. But for example if you're using "1.0-SNAPSHOT" the content will
> change during development but the block-name will not. My first idea was
> to put the jar size in the temp directory as well and only extract if
> the size has changed. (I'm not sure if the size is a reachable
> information though).

What about the file last modified attribute? It should be easy to 
compare the last modified date of the jar with the last modified date of 
the temp directory where the jar is extracted to (when each jar has its 
own directory).

Alex

-- 
Alexander Klimetschek
http://www.mindquarry.com


Re: [2.2] Runtime deployment

Posted by Carsten Ziegeler <cz...@apache.org>.
Leszek Gawron wrote:
>> What is missing?
>> 1. With the changes from above, Cocoon does not run as an unexpanded war
>> file anymore. So I think we should extract the COB-INF directory into
>> the temporary directory and mount the blocks from there. This should be
>> very simple to change.
> 
> apart from one thing, how do I do that?:
>> <map:match pattern="mobile/**">
>>     <map:mount uri-prefix="mobile" src="blocks/geminismart-server-mobile/"/>
>> </map:match>
>> <map:match pattern="central/**">
>>     <map:mount uri-prefix="central" src="blocks/geminismart-server-central/"/>
>> </map:match>
>> <map:match pattern="**">
>>     <map:mount uri-prefix="" src="blocks/mobilebox-webapp-commons/"/>
>> </map:match>
> 
> when I get block files unpacked to some temporary directory which 
> location can change any time.
> 
We could provide our own protocol "temp:" which is resolved to the
temporary directory, so you can use
"temp://blocks/geminismart-server-mobile/" for example.

>> 2. We should check on startup if we need to extract a COB-INF directory
>> again. If anyone has a good idea how to check this without too much work
>> would be great.
> 
> wouldn't it be sufficient if we checked for blocks/block-name directory 
> existence?
Hm, it depends - this assumes that an artifact during development never
changes. But for example if you're using "1.0-SNAPSHOT" the content will
change during development but the block-name will not. My first idea was
to put the jar size in the temp directory as well and only extract if
the size has changed. (I'm not sure if the size is a reachable
information though).

Carsten
-- 
Carsten Ziegeler - Chief Architect
http://www.s-und-n.de
http://www.osoco.org/weblogs/rael/

Re: [2.2] Runtime deployment

Posted by Leszek Gawron <lg...@mobilebox.pl>.
Leszek Gawron wrote:
> Carsten Ziegeler wrote:
>> With the help from Leszek we now have a Cocoon version in trunk which
> 
> which was rather small and of questionable quality, thanks for the 
> credit tough :)
> 
>> does not need any deployment plugin. This means you can just drop the
>> jar files into WEB-INF/lib and are done! So it doesn't matter if you're
>> using Maven, Ant or some other strange tool :)
>> All you need is the main Spring applicationContext.xml with our two
>> elements for setting up Cocoon and the Avalon bridge.
> 
>>
>> So, what has changed?
>> We now load all configuration files directly from within the jar files,
>> so all files in META-INF/cocoon/avalon, META-INF/cocoon/spring and
>> META-INF/cocoon/properties are applied at runtime without the need to
>> extract these files.
> 
> do we need to load configuration files from WEB-INF/cocoon/*? After all 
> if one wants to have configuration unpack it may be done using 
> WEB-INF/classes/META-INF/cocoon/*. Same result. No duplication.
> 
> CocoonPropertyOverrideConfigurer could be then simplified. We could drop 
> scanClassPath and just provide a 'location' attribute which is 
> classpath*:/META-INF/properties for core and ./config/properties for 
> blocks.
> 
> So we could remove:
   <!--+
       | Include all configuration files ending with ".xconf"
       | from the xconf directory.
       +-->
   <include dir="context://WEB-INF/cocoon/avalon" pattern="*.xconf"/>
and this from cocoon.xconf

-- 
Leszek Gawron                                    CTO at MobileBox Ltd.


Re: [2.2] Runtime deployment

Posted by Leszek Gawron <lg...@mobilebox.pl>.
Carsten Ziegeler wrote:
> With the help from Leszek we now have a Cocoon version in trunk which

which was rather small and of questionable quality, thanks for the 
credit tough :)

> does not need any deployment plugin. This means you can just drop the
> jar files into WEB-INF/lib and are done! So it doesn't matter if you're
> using Maven, Ant or some other strange tool :)
> All you need is the main Spring applicationContext.xml with our two
> elements for setting up Cocoon and the Avalon bridge.

> 
> So, what has changed?
> We now load all configuration files directly from within the jar files,
> so all files in META-INF/cocoon/avalon, META-INF/cocoon/spring and
> META-INF/cocoon/properties are applied at runtime without the need to
> extract these files.

do we need to load configuration files from WEB-INF/cocoon/*? After all 
if one wants to have configuration unpack it may be done using 
WEB-INF/classes/META-INF/cocoon/*. Same result. No duplication.

CocoonPropertyOverrideConfigurer could be then simplified. We could drop 
scanClassPath and just provide a 'location' attribute which is 
classpath*:/META-INF/properties for core and ./config/properties for 
blocks.

So we could remove:
CocoonPropertyOverrideConfigurer.java:110-115
>         if ( this.scanClassPath ) {
>             ResourceUtils.readProperties("classpath*:META-INF/cocoon/spring", mergedProps, this.resourceLoader,
>                     this.logger);
>             ResourceUtils.readProperties("classpath*:META-INF/cocoon/spring/" + mode, mergedProps,
>                     this.resourceLoader, this.logger);
>         }

SettingsElementParser.java:78-82
>         try {
>             this.handleBeanInclude(parserContext, null, Constants.DEFAULT_SPRING_BLOCK_CONFIGURATION_LOCATION, "*.xml", true);
>         } catch (Exception e) {
>             throw new BeanDefinitionStoreException("Unable to read spring configurations from " + Constants.DEFAULT_SPRING_BLOCK_CONFIGURATION_LOCATION, e);
>         }

SettingsBeanFactoryPostProcessor.java:188-196 (2 includes instead of 4)
>         // now read all properties from the properties directory
>         ResourceUtils.readProperties("classpath*:META-INF/cocoon/properties", properties, this.getResourceLoader(), this.logger);
>         // read all properties from the mode dependent directory
>         ResourceUtils.readProperties("classpath*:META-INF/cocoon/properties/" + mode, properties, this.getResourceLoader(), this.logger);
> 
>         // now read all properties from the properties directory
>         ResourceUtils.readProperties("/WEB-INF/cocoon/properties", properties, this.getResourceLoader(), this.logger);
>         // read all properties from the mode dependent directory
>         ResourceUtils.readProperties("/WEB-INF/cocoon/properties/" + mode, properties, this.getResourceLoader(), this.logger);

> 
> Currently on startup of Cocoon, all COB-INF directories are extracted to
> {webapp-directory}/blocks/{block-name}.
> 
> What is missing?
> 1. With the changes from above, Cocoon does not run as an unexpanded war
> file anymore. So I think we should extract the COB-INF directory into
> the temporary directory and mount the blocks from there. This should be
> very simple to change.

apart from one thing, how do I do that?:
> <map:match pattern="mobile/**">
>     <map:mount uri-prefix="mobile" src="blocks/geminismart-server-mobile/"/>
> </map:match>
> <map:match pattern="central/**">
>     <map:mount uri-prefix="central" src="blocks/geminismart-server-central/"/>
> </map:match>
> <map:match pattern="**">
>     <map:mount uri-prefix="" src="blocks/mobilebox-webapp-commons/"/>
> </map:match>

when I get block files unpacked to some temporary directory which 
location can change any time.

> 2. We should check on startup if we need to extract a COB-INF directory
> again. If anyone has a good idea how to check this without too much work
> would be great.

wouldn't it be sufficient if we checked for blocks/block-name directory 
existence?

> 3. Update to our deployer plugins (and perhaps archetypes) - we changed
> some directory names and obviously the deployment has changed. So we
> should check if all our plugins, development procedures, archetypes etc.
> are still working. I just tested the core-webapp.

Next few hours I will be trying to get all my 2.2 projects up and 
running again.

> 
> Once we have solved these three issues we should release a RC-1 asap.
+1

-- 
Leszek Gawron                                    CTO at MobileBox Ltd.


Re: [2.2] Runtime deployment

Posted by Daniel Fagerstrom <da...@nada.kth.se>.
Leszek Gawron skrev:
...
> The amount of mocking (and additional work to mimic the actual webapp) 
> makes me think that it would probably be much easier if I just set up a 
> jetty server programmatically and interface cocoon using commons http 
> client.

I have found minimal mock setups for servlets quite useful for setting 
up functional tests while I developed earlier versions of the blocks fw 
(before the switch to Spring). It is simpler to follow what happens if 
you don't have the extra complexity of socket communication etc.

But for a replacement of the CLI a Jetty server together with a http 
client with some command line tool might be a good solution.

/Daniel


Re: [2.2] Runtime deployment

Posted by Leszek Gawron <lg...@mobilebox.pl>.
Daniel Fagerstrom wrote:
> Leszek Gawron skrev:
>> Daniel Fagerstrom wrote:
>>> Might be that it will not that easy to create a mock servlet context 
>>> that contain exactly what is needed for creating beans in a 
>>> XmlWebApplicationContext. In my experience getting the different 
>>> context used within Cocoon is never easy. But I can assure you that 
>>> creating a mock servlet context is a much simpler solution to the 
>>> problem that you want to solve than refactoring Cocoon so that it 
>>> doesn't depend on having a servlet context available.
>>>
>>> We should of course provide a mock servlet context so that users 
>>> doesn't need to implement one themselves.
>>>
>>> For the particular problem you get, I would need to see what the 
>>> malformed URL looks like to have any clue about what goes wrong.
>>
>> It was my mistake in ServetContext.getResource().
>>
>> Seems I have a running cocoon with no servlet container:
> 
> Cool!
> 
>> Now if somebody could show me how to build a pipeline...
> 
> If you mean building a pipeline in Java it is not as easy as one would 
> like, see http://marc.theaimsgroup.com/?t=116133031100001&r=1&w=2 for a 
> recent discussion about the topic.
> 
> It is easier to build the pipeline in a sitemap and call the 
> SitemapServlet.
> 
> What you need to do is that create and init the SitemapServlet. For the 
> initialization you need a mock servlet configuration that "contains" to 
> your mock servlet context. You need to set the mock servlet context 
> attribute WebApplicationContext.ROOT_WEB_APPLICATION_CONTEXT_ATTRIBUTE 
> to contain the web application context to make the sitemap servlet to work.
> 
> Then you need a mock request and response object for being able to call 
> the service method of the servlet. Here you can reuse o.a.c.blocks.util. 
> BlockCallHttpServletRequest and BlockCallHttpServletResponse, from the 
> cocoon-blocks-fw-impl. There is nothing block fw specific in them and we 
> might want to rename them an move them to some servlet util package. You 
> can find an example of how to use the mentioned request and response 
> objects in o.a.c.blocks.BlockConnection.

The amount of mocking (and additional work to mimic the actual webapp) 
makes me think that it would probably be much easier if I just set up a 
jetty server programmatically and interface cocoon using commons http 
client.

The test code I created is probably sufficient to use any cocoon 
component (parser, source resolver etc.) in business services.
-- 
Leszek Gawron                                    CTO at MobileBox Ltd.


Re: [2.2] Runtime deployment

Posted by Daniel Fagerstrom <da...@nada.kth.se>.
Leszek Gawron skrev:
> Daniel Fagerstrom wrote:
>> Might be that it will not that easy to create a mock servlet context 
>> that contain exactly what is needed for creating beans in a 
>> XmlWebApplicationContext. In my experience getting the different 
>> context used within Cocoon is never easy. But I can assure you that 
>> creating a mock servlet context is a much simpler solution to the 
>> problem that you want to solve than refactoring Cocoon so that it 
>> doesn't depend on having a servlet context available.
>>
>> We should of course provide a mock servlet context so that users 
>> doesn't need to implement one themselves.
>>
>> For the particular problem you get, I would need to see what the 
>> malformed URL looks like to have any clue about what goes wrong.
> 
> It was my mistake in ServetContext.getResource().
> 
> Seems I have a running cocoon with no servlet container:

Cool!

> Now if somebody could show me how to build a pipeline...

If you mean building a pipeline in Java it is not as easy as one would 
like, see http://marc.theaimsgroup.com/?t=116133031100001&r=1&w=2 for a 
recent discussion about the topic.

It is easier to build the pipeline in a sitemap and call the SitemapServlet.

What you need to do is that create and init the SitemapServlet. For the 
initialization you need a mock servlet configuration that "contains" to 
your mock servlet context. You need to set the mock servlet context 
attribute WebApplicationContext.ROOT_WEB_APPLICATION_CONTEXT_ATTRIBUTE 
to contain the web application context to make the sitemap servlet to work.

Then you need a mock request and response object for being able to call 
the service method of the servlet. Here you can reuse o.a.c.blocks.util. 
BlockCallHttpServletRequest and BlockCallHttpServletResponse, from the 
cocoon-blocks-fw-impl. There is nothing block fw specific in them and we 
might want to rename them an move them to some servlet util package. You 
can find an example of how to use the mentioned request and response 
objects in o.a.c.blocks.BlockConnection.

/Daniel


Re: [2.2] Runtime deployment

Posted by Leszek Gawron <lg...@mobilebox.pl>.
Daniel Fagerstrom wrote:
> Might be that it will not that easy to create a mock servlet context 
> that contain exactly what is needed for creating beans in a 
> XmlWebApplicationContext. In my experience getting the different context 
> used within Cocoon is never easy. But I can assure you that creating a 
> mock servlet context is a much simpler solution to the problem that you 
> want to solve than refactoring Cocoon so that it doesn't depend on 
> having a servlet context available.
> 
> We should of course provide a mock servlet context so that users doesn't 
> need to implement one themselves.
> 
> For the particular problem you get, I would need to see what the 
> malformed URL looks like to have any clue about what goes wrong.

It was my mistake in ServetContext.getResource().

Seems I have a running cocoon with no servlet container:
> public class Test {
> 	public static class EmptyEnumeration implements Enumeration {
> 		public boolean hasMoreElements() {
> 			return false;
> 		}
> 
> 		public Object nextElement() {
> 			return null;
> 		}
> 	}
> 
> 	public static final Enumeration	EMPTY_ENUMERATION	= new EmptyEnumeration();
> 
> 	public static class MockServletContext implements ServletContext {
> 		private static final Log	logger	= LogFactory.getLog( ServletContext.class );
> 
> 		public Object getAttribute( String name ) {
> 			if ( name.equals( "javax.servlet.context.tempdir" ) )
> 				return new File( "target" );
> 			return null;
> 		}
> 
> 		public Enumeration getAttributeNames() {
> 			return EMPTY_ENUMERATION;
> 		}
> 
> 		public ServletContext getContext( String path ) {
> 			return null;
> 		}
> 
> 		public String getInitParameter( String name ) {
> 			return null;
> 		}
> 
> 		public Enumeration getInitParameterNames() {
> 			return EMPTY_ENUMERATION;
> 		}
> 
> 		public int getMajorVersion() {
> 			return 2;
> 		}
> 
> 		public String getMimeType( String file ) {
> 			return null;
> 		}
> 
> 		public int getMinorVersion() {
> 			return 4;
> 		}
> 
> 		public RequestDispatcher getNamedDispatcher( String name ) {
> 			return null;
> 		}
> 
> 		public String getRealPath( String path ) {
> 			return null;
> 		}
> 
> 		public RequestDispatcher getRequestDispatcher( String path ) {
> 			return null;
> 		}
> 
> 		public URL getResource( String path ) throws MalformedURLException {
> 			String p = path;
> 			if ( p.startsWith( "/" ) )
> 				p = path.substring( 1 );
> 
> 			logger.info( "getResource: " + p );
> 			return new File( p ).toURL();
> 		}
> 
> 		public InputStream getResourceAsStream( String path ) {
> 			try {
> 				URL url = getResource( path );
> 				if ( url == null )
> 					return null;
> 				return url.openStream();
> 			} catch ( Exception e ) {
> 				logger.debug( e );
> 				return null;
> 			}
> 		}
> 
> 		public Set getResourcePaths( String path ) {
> 			// TODO Auto-generated method stub
> 			return null;
> 		}
> 
> 		public String getServerInfo() {
> 			return "mock";
> 		}
> 
> 		public Servlet getServlet( String name ) throws ServletException {
> 			return null;
> 		}
> 
> 		public String getServletContextName() {
> 			return null;
> 		}
> 
> 		public Enumeration getServletNames() {
> 			return EMPTY_ENUMERATION;
> 		}
> 
> 		public Enumeration getServlets() {
> 			return EMPTY_ENUMERATION;
> 		}
> 
> 		public void log( String msg ) {
> 			logger.info( msg );
> 		}
> 
> 		public void log( Exception ex, String text ) {
> 			log(	text,
> 					ex );
> 		}
> 
> 		public void log( String text, Throwable ex ) {
> 			logger.error(	text,
> 							ex );
> 		}
> 
> 		public void removeAttribute( String name ) {
> 		}
> 
> 		public void setAttribute( String name, Object value ) {
> 		}
> 	}
> 
> 	public static void main( String[] args ) {
> 		StopWatch watch = new StopWatch();
> 		watch.start();
> 		ServletContext servletContext = new MockServletContext();
> 		ConfigurableWebApplicationContext context = new XmlWebApplicationContext();
> 		context.setServletContext( servletContext );
> 		context.setConfigLocations( new String[]{ "applicationContext.xml" } );
> 		context.refresh();
> 		context.close();
> 		watch.stop();
> 		System.out.println( "running time: " + watch.toString() );
> 	}
> }

Now if somebody could show me how to build a pipeline...

-- 
Leszek Gawron                                    CTO at MobileBox Ltd.


Re: [2.2] Runtime deployment

Posted by Daniel Fagerstrom <da...@nada.kth.se>.
Leszek Gawron skrev:
> Daniel Fagerstrom wrote:
>> Leszek Gawron skrev:
>>> Joerg Heinicke wrote:
>>>> On 03.11.2006 23:17, Carsten Ziegeler wrote:
>>>>> With the help from Leszek we now have a Cocoon version in trunk which
>>>>> does not need any deployment plugin. This means you can just drop the
>>>>> jar files into WEB-INF/lib and are done! So it doesn't matter if 
>>>>> you're
>>>>> using Maven, Ant or some other strange tool :)
>>>>> All you need is the main Spring applicationContext.xml with our two
>>>>> elements for setting up Cocoon and the Avalon bridge.
>>>>
>>>> Thanks very much for your efforts. I highly appreciate everything 
>>>> easing the usage of Cocoon.
>>>>
>>>>> Once we have solved these three issues we should release a RC-1 asap.
>>>>
>>>> +1
>>> I still would like 2 things resolved (maybe not directly fixed but at 
>>> least addressed somehow):
>>> - running cocoon without servlet context
>>
>> The far easiest way to achieve this is to create a mock servlet 
>> context. Only a handful of methods needs implementation that require a 
>> non null answer.
> 
> Looks it's not that easy after all. My current implementation:

Might be that it will not that easy to create a mock servlet context 
that contain exactly what is needed for creating beans in a 
XmlWebApplicationContext. In my experience getting the different context 
used within Cocoon is never easy. But I can assure you that creating a 
mock servlet context is a much simpler solution to the problem that you 
want to solve than refactoring Cocoon so that it doesn't depend on 
having a servlet context available.

We should of course provide a mock servlet context so that users doesn't 
need to implement one themselves.

For the particular problem you get, I would need to see what the 
malformed URL looks like to have any clue about what goes wrong.

/Daniel

Re: [2.2] Runtime deployment

Posted by Leszek Gawron <lg...@mobilebox.pl>.
Daniel Fagerstrom wrote:
> Leszek Gawron skrev:
>> Joerg Heinicke wrote:
>>> On 03.11.2006 23:17, Carsten Ziegeler wrote:
>>>> With the help from Leszek we now have a Cocoon version in trunk which
>>>> does not need any deployment plugin. This means you can just drop the
>>>> jar files into WEB-INF/lib and are done! So it doesn't matter if you're
>>>> using Maven, Ant or some other strange tool :)
>>>> All you need is the main Spring applicationContext.xml with our two
>>>> elements for setting up Cocoon and the Avalon bridge.
>>>
>>> Thanks very much for your efforts. I highly appreciate everything 
>>> easing the usage of Cocoon.
>>>
>>>> Once we have solved these three issues we should release a RC-1 asap.
>>>
>>> +1
>> I still would like 2 things resolved (maybe not directly fixed but at 
>> least addressed somehow):
>> - running cocoon without servlet context
> 
> The far easiest way to achieve this is to create a mock servlet context. 
> Only a handful of methods needs implementation that require a non null 
> answer.

Looks it's not that easy after all. My current implementation:

> public class Test {
> 	public static class EmptyEnumeration implements Enumeration {
> 		public boolean hasMoreElements() {
> 			return false;
> 		}
> 
> 		public Object nextElement() {
> 			return null;
> 		}
> 	}
> 
> 	public static final Enumeration	EMPTY_ENUMERATION	= new EmptyEnumeration();
> 
> 	public static class MockServletContext implements ServletContext {
> 		private static final Log	logger	= LogFactory.getLog( ServletContext.class );
> 
> 		public Object getAttribute( String name ) {
> 			if ( name.equals( "javax.servlet.context.tempdir" ) )
> 				return new File( "target" );
> 			return null;
> 		}
> 
> 		public Enumeration getAttributeNames() {
> 			return EMPTY_ENUMERATION;
> 		}
> 
> 		public ServletContext getContext( String path ) {
> 			return null;
> 		}
> 
> 		public String getInitParameter( String name ) {
> 			return null;
> 		}
> 
> 		public Enumeration getInitParameterNames() {
> 			return EMPTY_ENUMERATION;
> 		}
> 
> 		public int getMajorVersion() {
> 			return 2;
> 		}
> 
> 		public String getMimeType( String file ) {
> 			return null;
> 		}
> 
> 		public int getMinorVersion() {
> 			return 4;
> 		}
> 
> 		public RequestDispatcher getNamedDispatcher( String name ) {
> 			return null;
> 		}
> 
> 		public String getRealPath( String path ) {
> 			return null;
> 		}
> 
> 		public RequestDispatcher getRequestDispatcher( String path ) {
> 			return null;
> 		}
> 
> 		public URL getResource( String path ) throws MalformedURLException {
> 			File parent = new File( "." );
> 			return new File( parent, path ).toURL();
> 		}
> 
> 		public InputStream getResourceAsStream( String path ) {
> 			try {
> 				URL url = getResource( path );
> 				if ( url == null )
> 					return null;
> 				return url.openStream();
> 			} catch ( Exception e ) {
> 				logger.debug( e );
> 				return null;
> 			}
> 		}
> 
> 		public Set getResourcePaths( String path ) {
> 			// TODO Auto-generated method stub
> 			return null;
> 		}
> 
> 		public String getServerInfo() {
> 			return "mock";
> 		}
> 
> 		public Servlet getServlet( String name ) throws ServletException {
> 			return null;
> 		}
> 
> 		public String getServletContextName() {
> 			return null;
> 		}
> 
> 		public Enumeration getServletNames() {
> 			return EMPTY_ENUMERATION;
> 		}
> 
> 		public Enumeration getServlets() {
> 			return EMPTY_ENUMERATION;
> 		}
> 
> 		public void log( String msg ) {
> 			logger.info( msg );
> 		}
> 
> 		public void log( Exception ex, String text ) {
> 			log(	text,
> 					ex );
> 		}
> 
> 		public void log( String text, Throwable ex ) {
> 			logger.error(	text,
> 							ex );
> 		}
> 
> 		public void removeAttribute( String name ) {
> 		}
> 
> 		public void setAttribute( String name, Object value ) {
> 		}
> 	}
> 
> 	public static void main( String[] args ) {
> 		ServletContext servletContext = new MockServletContext();
> 		ConfigurableWebApplicationContext context = new XmlWebApplicationContext();
> 		context.setServletContext( servletContext );
> 		context.setConfigLocations( new String[]{ "applicationContext.xml" } );
> 		context.refresh();
> 	}
> }

throws the following:
> INFO  (2006-11-04) 16:16.16:313 [org.springframework.beans.factory.xml.XmlBeanDefinitionReader]  Loading XML bean definitions from URL [file:C:/dev/projects/viessmann-pi/server/core/src/main/resources/META-INF/cocoon/spring/acegi-authentication.xml]
> INFO  (2006-11-04) 16:16.16:423 [org.springframework.beans.factory.xml.XmlBeanDefinitionReader]  Loading XML bean definitions from URL [file:C:/dev/projects/viessmann-pi/server/core/src/main/resources/META-INF/cocoon/spring/acegi-web.xml]
> INFO  (2006-11-04) 16:16.16:454 [org.springframework.beans.factory.xml.XmlBeanDefinitionReader]  Loading XML bean definitions from URL [file:C:/dev/projects/viessmann-pi/server/core/src/main/resources/META-INF/cocoon/spring/acegi.xml]
> INFO  (2006-11-04) 16:16.16:579 [org.springframework.beans.factory.xml.XmlBeanDefinitionReader]  Loading XML bean definitions from URL [jar:file:/C:/Documents%20and%20Settings/lgawron/.m2/repository/org/apache/cocoon/cocoon-core/2.2.0-M2-SNAPSHOT/cocoon-core-2.2.0-M2-SNAPSHOT.jar!/META-INF/cocoon/spring/cocoon-core-applicationContext.xml]
> INFO  (2006-11-04) 16:16.16:626 [org.springframework.beans.factory.xml.XmlBeanDefinitionReader]  Loading XML bean definitions from URL [file:C:/dev/projects/viessmann-pi/server/core/src/main/resources/META-INF/cocoon/spring/core-services.xml]
> INFO  (2006-11-04) 16:16.16:688 [org.springframework.beans.factory.xml.XmlBeanDefinitionReader]  Loading XML bean definitions from URL [file:C:/dev/projects/viessmann-pi/server/core/src/main/resources/META-INF/cocoon/spring/core.xml]
> INFO  (2006-11-04) 16:16.16:829 [org.springframework.beans.factory.xml.XmlBeanDefinitionReader]  Loading XML bean definitions from URL [file:C:/dev/projects/viessmann-pi/server/pi-api/src/main/resources/META-INF/cocoon/spring/pi-api.xml]
> INFO  (2006-11-04) 16:16.17:720 [org.springframework.web.context.support.XmlWebApplicationContext]  Bean factory for application context [Root WebApplicationContext]: org.springframework.beans.factory.support.DefaultListableBeanFactory defining beans [org.apache.cocoon.configuration.Settings,org.apache.cocoon.core.container.spring.CocoonPropertyOverrideConfigurer,javax.servlet.ServletContext,userDetailsService,filterChainProxy,httpSessionContextIntegrationFilter,basicProcessingFilter,basicProcessingFilterEntryPoint,exceptionTranslationFilter,filterSecurityInterceptor,roleVoter,accessDecisionManager,testingAuthenticationProvider,daoAuthenticationProvider,authenticationManager,org.apache.cocoon.processing.ProcessInfoProvider,investmentDao,partnerDao,regionDao,userDao,investmentService,partnerService,regionService,userService,org.springframework.beans.factory.annotation.RequiredAnnotationBeanPostProcessor,dataSource,sessionFactory,baseHibernateDao,transactionManager,org.sprin
gframework.aop.config.internalAutoProxyCreator,org.springframework.transaction.interceptor.TransactionAttributeSourceAdvisor,xmlRequestApple,storeInvestmentApple,investmentParser,org.apache.avalon.framework.context.Context,org.apache.avalon.framework.service.ServiceManager,org.apache.avalon.framework.logger.Logger,org.apache.cocoon.serialization.Serializer/htmlPooled,org.apache.cocoon.serialization.Serializer/html,org.apache.cocoon.acting.Action/session-state,org.apache.cocoon.acting.Action/session-validator,org.apache.cocoon.generation.Generator/directoryPooled,org.apache.cocoon.generation.Generator/directory,org.apache.cocoon.generation.Generator/imagedirectoryPooled,org.apache.cocoon.generation.Generator/imagedirectory,org.apache.cocoon.transformation.Transformer/<gatherer>Pooled,org.apache.cocoon.transformation.Transformer/<gatherer>,org.apache.cocoon.components.flow.Interpreter/service-apples,org.apache.cocoon.components.modules.input.InputModule/request,org.apache.cocoo
n.components.modules.input.InputModule/flow-attribute,org.apache.cocoon.selection.Selector/exception,org.apache.cocoon.reading.ReaderSelector,org.apache.excalibur.store.Store,org.apache.cocoon.acting.Action/set-header,org.apache.cocoon.components.pipeline.ProcessingPipeline/caching-pointPooled,org.apache.cocoon.components.pipeline.ProcessingPipeline/caching-point,org.apache.excalibur.xml.xslt.XSLTProcessorPooled,org.apache.excalibur.xml.xslt.XSLTProcessor,org.apache.excalibur.xml.dom.DOMSerializer,org.apache.cocoon.serialization.Serializer/sxdPooled,org.apache.cocoon.serialization.Serializer/sxd,org.apache.cocoon.selection.Selector/header,org.apache.cocoon.components.modules.input.InputModule/nullinput,org.apache.cocoon.generation.Generator/jxPooled,org.apache.cocoon.generation.Generator/jx,org.apache.cocoon.components.pipeline.ProcessingPipelineSelector,org.apache.cocoon.components.modules.input.InputModule/mapmeta,org.apache.cocoon.classloader.reloading.Monitor,org.apache.c
ocoon.transformation.Transformer/filterPooled,org.apache.cocoon.transformation.Transformer/filter,org.apache.cocoon.components.modules.output.OutputModule/request-attr,org.apache.cocoon.components.flow.InterpreterSelector,org.apache.excalibur.source.SourceResolver,org.apache.excalibur.source.SourceFactory/cocoon,org.apache.cocoon.components.modules.output.OutputModule/session-attr,org.apache.cocoon.transformation.Transformer/cincludePooled,org.apache.cocoon.transformation.Transformer/cinclude,org.apache.cocoon.serialization.Serializer/xmlPooled,org.apache.cocoon.serialization.Serializer/xml,org.apache.cocoon.acting.Action/resource-exists,org.apache.cocoon.matching.Matcher/parameter,org.apache.cocoon.components.modules.input.InputModule/raw-request-param,org.apache.cocoon.template.script.ScriptManager,org.apache.cocoon.serialization.Serializer/xhtml11Pooled,org.apache.cocoon.serialization.Serializer/xhtml11,org.apache.cocoon.matching.Matcher/cookie,org.apache.cocoon.selection.
Selector/session-attribute,org.apache.cocoon.generation.Generator/requestPooled,org.apache.cocoon.generation.Generator/request,org.apache.cocoon.transformation.Transformer/includePooled,org.apache.cocoon.transformation.Transformer/include,org.apache.cocoon.matching.MatcherSelector,org.apache.cocoon.components.expression.ExpressionFactory,org.apache.cocoon.matching.Matcher/locale,org.apache.cocoon.components.flow.Interpreter/javascript,org.apache.excalibur.xml.xpath.XPathProcessor,org.apache.cocoon.selection.Selector/request-attribute,org.apache.cocoon.reading.Reader/imagePooled,org.apache.cocoon.reading.Reader/image,org.apache.cocoon.matching.Matcher/sessionstate,org.apache.cocoon.components.thread.RunnableManager,org.apache.cocoon.generation.GeneratorSelector,org.apache.cocoon.transformation.Transformer/xalanPooled,org.apache.cocoon.transformation.Transformer/xalan,org.apache.cocoon.components.modules.input.InputModule/request-scoped-attr,org.apache.cocoon.components.modules
.input.InputModule/url-decode,org.apache.cocoon.selection.Selector/resource-exists,org.apache.excalibur.source.SourceFactory/*,org.apache.cocoon.acting.ActionSelector,org.apache.cocoon.components.modules.input.InputModule/global,org.apache.cocoon.classloader.ClassLoaderFactory,org.apache.cocoon.i18n.BundleFactory,org.apache.cocoon.components.notification.NotifyingBuilderPooled,org.apache.cocoon.components.notification.NotifyingBuilder,org.apache.cocoon.serialization.Serializer/xhtmlPooled,org.apache.cocoon.serialization.Serializer/xhtml,org.apache.cocoon.components.modules.input.InputModule/flow-attr,org.apache.cocoon.components.expression.ExpressionCompilerSelector,org.apache.cocoon.components.flow.Interpreter/apples,org.apache.cocoon.transformation.Transformer/write-sourcePooled,org.apache.cocoon.transformation.Transformer/write-source,org.apache.cocoon.components.pipeline.ProcessingPipeline/expiresPooled,org.apache.cocoon.components.pipeline.ProcessingPipeline/expires,org.
apache.cocoon.components.modules.input.InputModule/request-param,org.apache.cocoon.transformation.Transformer/jpathPooled,org.apache.cocoon.transformation.Transformer/jpath,org.apache.cocoon.matching.Matcher/request-parameter,org.apache.cocoon.components.modules.input.InputModule/session-attr,org.apache.excalibur.source.SourceFactorySelector,org.apache.cocoon.components.treeprocessor.TreeBuilder/sitemap-1.0Pooled,org.apache.cocoon.components.treeprocessor.TreeBuilder/sitemap-1.0,org.apache.cocoon.matching.Matcher/referer-match,org.apache.cocoon.serialization.Serializer/zipPooled,org.apache.cocoon.serialization.Serializer/zip,org.apache.cocoon.acting.Action/session-invalidator,org.apache.cocoon.components.modules.input.InputModuleSelector,org.apache.cocoon.transformation.Transformer/paginatePooled,org.apache.cocoon.transformation.Transformer/paginate,org.apache.cocoon.transformation.Transformer/encodeURLPooled,org.apache.cocoon.transformation.Transformer/encodeURL,org.apache.c
ocoon.transformation.Transformer/readDOMsessionPooled,org.apache.cocoon.transformation.Transformer/readDOMsession,org.apache.cocoon.components.expression.ExpressionCompiler/jxpath,org.apache.cocoon.components.expression.ExpressionCompiler/jexl,org.apache.cocoon.generation.Generator/<aggregator>Pooled,org.apache.cocoon.generation.Generator/<aggregator>,org.apache.cocoon.transformation.Transformer/xsltPooled,org.apache.cocoon.transformation.Transformer/xslt,org.apache.cocoon.transformation.Transformer/xincludePooled,org.apache.cocoon.transformation.Transformer/xinclude,org.apache.excalibur.xml.dom.DOMParserPooled,org.apache.excalibur.xml.dom.DOMParser,org.apache.cocoon.components.modules.input.InputModule/naming,org.apache.cocoon.template.expression.StringTemplateParser,org.apache.cocoon.serialization.Serializer/textPooled,org.apache.cocoon.serialization.Serializer/text,org.apache.cocoon.components.modules.input.InputModule/chain,org.apache.cocoon.components.modules.input.Input
Module/date,org.apache.excalibur.store.StoreJanitor,org.apache.cocoon.transformation.TransformerSelector,org.apache.cocoon.template.expression.StringTemplateParser/jxtg,org.apache.cocoon.generation.Generator/mp3directoryPooled,org.apache.cocoon.generation.Generator/mp3directory,org.apache.cocoon.serialization.Serializer/sxwPooled,org.apache.cocoon.serialization.Serializer/sxw,org.apache.cocoon.components.modules.input.InputModule/xmlmeta,org.apache.cocoon.components.modules.input.InputModule/datemeta,org.apache.cocoon.generation.Generator/filePooled,org.apache.cocoon.generation.Generator/file,org.apache.cocoon.acting.Action/session-isvalid,org.apache.cocoon.transformation.Transformer/jxPooled,org.apache.cocoon.transformation.Transformer/jx,org.apache.cocoon.transformation.helpers.IncludeCacheManager,org.apache.cocoon.serialization.SerializerSelector,org.apache.cocoon.selection.Selector/request-method,org.apache.cocoon.components.modules.input.InputModule/digest,org.apache.coc
oon.acting.Action/request,org.apache.cocoon.components.modules.input.InputModule/url-encode,org.apache.cocoon.selection.Selector/host,org.apache.cocoon.components.modules.input.InputModule/constant,org.apache.cocoon.transformation.Transformer/logPooled,org.apache.cocoon.transformation.Transformer/log,org.apache.excalibur.xml.xslt.XSLTProcessor/xalanPooled,org.apache.excalibur.xml.xslt.XSLTProcessor/xalan,org.apache.excalibur.source.SourceFactory/module,org.apache.cocoon.matching.Matcher/wildcard,org.apache.cocoon.components.modules.input.InputModule/simplemap,org.apache.cocoon.caching.Cache,org.apache.excalibur.store.Store/TransientStore,org.apache.cocoon.template.expression.StringTemplateParser/default,org.apache.cocoon.generation.Generator/notifyingPooled,org.apache.cocoon.generation.Generator/notifying,org.apache.cocoon.matching.Matcher/mount-table,org.apache.cocoon.components.modules.input.InputModule/locate,org.apache.cocoon.Processor,org.apache.cocoon.serialization.Seri
alizer/wmlPooled,org.apache.cocoon.serialization.Serializer/wml,org.apache.cocoon.serialization.Serializer/svgxmlPooled,org.apache.cocoon.serialization.Serializer/svgxml,org.apache.cocoon.template.expression.StringTemplateParserSelector,org.apache.cocoon.transformation.Transformer/xsltcPooled,org.apache.cocoon.transformation.Transformer/xsltc,org.apache.cocoon.generation.Generator/<notifier>Pooled,org.apache.cocoon.generation.Generator/<notifier>,org.apache.cocoon.components.modules.input.InputModule/cocoon-properties,org.apache.excalibur.source.SourceFactory/zip,org.apache.cocoon.components.pipeline.ProcessingPipeline/noncachingPooled,org.apache.cocoon.components.pipeline.ProcessingPipeline/noncaching,org.apache.cocoon.components.modules.input.InputModule/session,org.apache.cocoon.generation.Generator/statusPooled,org.apache.cocoon.generation.Generator/status,org.apache.cocoon.generation.Generator/exceptionPooled,org.apache.cocoon.generation.Generator/exception,org.apache.ex
calibur.source.SourceFactory/context,org.apache.cocoon.components.persistence.RequestDataStore,org.apache.cocoon.serialization.Serializer/linksPooled,org.apache.cocoon.serialization.Serializer/links,org.apache.cocoon.acting.Action/form-validator,org.apache.cocoon.serialization.Serializer/sxcPooled,org.apache.cocoon.serialization.Serializer/sxc,org.apache.cocoon.generation.Generator/streamPooled,org.apache.cocoon.generation.Generator/stream,org.apache.excalibur.xml.xslt.XSLTProcessor/xsltcPooled,org.apache.excalibur.xml.xslt.XSLTProcessor/xsltc,org.apache.cocoon.components.modules.input.InputModule/cookie,org.apache.cocoon.reading.Reader/resourcePooled,org.apache.cocoon.reading.Reader/resource,org.apache.cocoon.transformation.Transformer/<translator>Pooled,org.apache.cocoon.transformation.Transformer/<translator>,org.apache.cocoon.components.modules.input.InputModule/request-header,org.apache.cocoon.components.modules.input.InputModule/realpath,org.apache.cocoon.classloader.Cl
assLoaderFactory/reloading,org.apache.cocoon.selection.Selector/request-parameter,org.apache.cocoon.generation.Generator/xpathdirectoryPooled,org.apache.cocoon.generation.Generator/xpathdirectory,org.apache.cocoon.components.expression.ExpressionCompiler/js,org.apache.cocoon.acting.Action/clear-persistent-store,org.apache.cocoon.components.modules.input.InputModule/environment-attr,org.apache.cocoon.acting.Action/locale,org.apache.excalibur.source.SourceFactory/resource,org.apache.cocoon.transformation.Transformer/writeDOMsessionPooled,org.apache.cocoon.transformation.Transformer/writeDOMsession,org.apache.excalibur.xml.sax.SAXParserPooled,org.apache.excalibur.xml.sax.SAXParser,org.apache.cocoon.selection.Selector/parameter,org.apache.cocoon.matching.Matcher/header,org.apache.cocoon.components.modules.output.OutputModuleSelector,org.apache.cocoon.components.pipeline.ProcessingPipeline/cachingPooled,org.apache.cocoon.components.pipeline.ProcessingPipeline/caching,org.apache.co
coon.selection.Selector/simple,org.apache.cocoon.components.modules.input.InputModule/request-attr,org.apache.excalibur.source.SourceFactory/empty,org.apache.excalibur.xml.EntityResolver,org.apache.cocoon.components.expression.ExpressionCompiler/default,org.apache.cocoon.serialization.Serializer/sxiPooled,org.apache.cocoon.serialization.Serializer/sxi,org.apache.cocoon.components.modules.output.OutputModule/request-attr-map,org.apache.cocoon.components.modules.input.InputModule/random,org.apache.cocoon.components.modules.input.InputModule/flow-continuation,org.apache.cocoon.serialization.Serializer/chtmlPooled,org.apache.cocoon.serialization.Serializer/chtml,org.apache.cocoon.acting.Action/req-params,org.apache.cocoon.components.modules.input.InputModule/jxpath,org.apache.cocoon.components.modules.input.InputModule/contextpath,org.apache.cocoon.template.script.InstructionFactory,org.apache.excalibur.source.SourceFactory/file,org.apache.excalibur.xmlizer.XMLizer,org.apache.exc
alibur.source.SourceFactory/upload,org.apache.cocoon.acting.Action/clear-cache,org.apache.cocoon.selection.SelectorSelector,org.apache.excalibur.source.SourceFactory/xmodule,org.apache.cocoon.matching.Matcher/regexp,org.apache.cocoon.components.flow.ContinuationsManager,org.apache.cocoon.components.modules.input.InputModule/baselink,org.apache.cocoon.selection.Selector/browser,org.apache.cocoon.components.modules.input.InputModule/system-property,org.apache.cocoon.serialization.Serializer/vrmlPooled,org.apache.cocoon.serialization.Serializer/vrml,org.apache.cocoon.generation.Generator/virtualPooled,org.apache.cocoon.generation.Generator/virtual,org.apache.cocoon.components.treeprocessor.ProcessorComponentInfo,org.apache.cocoon.core.container.spring.avalon.ConfigurationInfo,org.apache.cocoon.core.container.spring.avalon.AvalonBeanPostProcessor]; root of BeanFactory hierarchy
> INFO  (2006-11-04) 16:16.17:751 [org.springframework.web.context.support.XmlWebApplicationContext]  283 beans defined in application context [Root WebApplicationContext]
> INFO  (2006-11-04) 16:16.18:032 [javax.servlet.ServletContext]  Apache Cocoon 2.2.0-M2-SNAPSHOT is running in mode: prod
> INFO  (2006-11-04) 16:16.18:220 [org.springframework.web.context.support.XmlWebApplicationContext]  Bean 'org.springframework.beans.factory.annotation.RequiredAnnotationBeanPostProcessor' is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
> INFO  (2006-11-04) 16:16.18:220 [org.springframework.aop.framework.DefaultAopProxyFactory]  CGLIB2 available: proxyTargetClass feature enabled
> INFO  (2006-11-04) 16:16.18:251 [org.springframework.web.context.support.XmlWebApplicationContext]  Bean 'org.springframework.aop.config.internalAutoProxyCreator' is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
> INFO  (2006-11-04) 16:16.18:282 [org.springframework.beans.factory.support.DefaultListableBeanFactory]  Destroying singletons in {org.springframework.beans.factory.support.DefaultListableBeanFactory defining beans [org.apache.cocoon.configuration.Settings,org.apache.cocoon.core.container.spring.CocoonPropertyOverrideConfigurer,javax.servlet.ServletContext,userDetailsService,filterChainProxy,httpSessionContextIntegrationFilter,basicProcessingFilter,basicProcessingFilterEntryPoint,exceptionTranslationFilter,filterSecurityInterceptor,roleVoter,accessDecisionManager,testingAuthenticationProvider,daoAuthenticationProvider,authenticationManager,org.apache.cocoon.processing.ProcessInfoProvider,investmentDao,partnerDao,regionDao,userDao,investmentService,partnerService,regionService,userService,org.springframework.beans.factory.annotation.RequiredAnnotationBeanPostProcessor,dataSource,sessionFactory,baseHibernateDao,transactionManager,org.springframework.aop.config.internalAutoPro
xyCreator,org.springframework.transaction.interceptor.TransactionAttributeSourceAdvisor,xmlRequestApple,storeInvestmentApple,investmentParser,org.apache.avalon.framework.context.Context,org.apache.avalon.framework.service.ServiceManager,org.apache.avalon.framework.logger.Logger,org.apache.cocoon.serialization.Serializer/htmlPooled,org.apache.cocoon.serialization.Serializer/html,org.apache.cocoon.acting.Action/session-state,org.apache.cocoon.acting.Action/session-validator,org.apache.cocoon.generation.Generator/directoryPooled,org.apache.cocoon.generation.Generator/directory,org.apache.cocoon.generation.Generator/imagedirectoryPooled,org.apache.cocoon.generation.Generator/imagedirectory,org.apache.cocoon.transformation.Transformer/<gatherer>Pooled,org.apache.cocoon.transformation.Transformer/<gatherer>,org.apache.cocoon.components.flow.Interpreter/service-apples,org.apache.cocoon.components.modules.input.InputModule/request,org.apache.cocoon.components.modules.input.InputModul
e/flow-attribute,org.apache.cocoon.selection.Selector/exception,org.apache.cocoon.reading.ReaderSelector,org.apache.excalibur.store.Store,org.apache.cocoon.acting.Action/set-header,org.apache.cocoon.components.pipeline.ProcessingPipeline/caching-pointPooled,org.apache.cocoon.components.pipeline.ProcessingPipeline/caching-point,org.apache.excalibur.xml.xslt.XSLTProcessorPooled,org.apache.excalibur.xml.xslt.XSLTProcessor,org.apache.excalibur.xml.dom.DOMSerializer,org.apache.cocoon.serialization.Serializer/sxdPooled,org.apache.cocoon.serialization.Serializer/sxd,org.apache.cocoon.selection.Selector/header,org.apache.cocoon.components.modules.input.InputModule/nullinput,org.apache.cocoon.generation.Generator/jxPooled,org.apache.cocoon.generation.Generator/jx,org.apache.cocoon.components.pipeline.ProcessingPipelineSelector,org.apache.cocoon.components.modules.input.InputModule/mapmeta,org.apache.cocoon.classloader.reloading.Monitor,org.apache.cocoon.transformation.Transformer/filt
erPooled,org.apache.cocoon.transformation.Transformer/filter,org.apache.cocoon.components.modules.output.OutputModule/request-attr,org.apache.cocoon.components.flow.InterpreterSelector,org.apache.excalibur.source.SourceResolver,org.apache.excalibur.source.SourceFactory/cocoon,org.apache.cocoon.components.modules.output.OutputModule/session-attr,org.apache.cocoon.transformation.Transformer/cincludePooled,org.apache.cocoon.transformation.Transformer/cinclude,org.apache.cocoon.serialization.Serializer/xmlPooled,org.apache.cocoon.serialization.Serializer/xml,org.apache.cocoon.acting.Action/resource-exists,org.apache.cocoon.matching.Matcher/parameter,org.apache.cocoon.components.modules.input.InputModule/raw-request-param,org.apache.cocoon.template.script.ScriptManager,org.apache.cocoon.serialization.Serializer/xhtml11Pooled,org.apache.cocoon.serialization.Serializer/xhtml11,org.apache.cocoon.matching.Matcher/cookie,org.apache.cocoon.selection.Selector/session-attribute,org.apache
.cocoon.generation.Generator/requestPooled,org.apache.cocoon.generation.Generator/request,org.apache.cocoon.transformation.Transformer/includePooled,org.apache.cocoon.transformation.Transformer/include,org.apache.cocoon.matching.MatcherSelector,org.apache.cocoon.components.expression.ExpressionFactory,org.apache.cocoon.matching.Matcher/locale,org.apache.cocoon.components.flow.Interpreter/javascript,org.apache.excalibur.xml.xpath.XPathProcessor,org.apache.cocoon.selection.Selector/request-attribute,org.apache.cocoon.reading.Reader/imagePooled,org.apache.cocoon.reading.Reader/image,org.apache.cocoon.matching.Matcher/sessionstate,org.apache.cocoon.components.thread.RunnableManager,org.apache.cocoon.generation.GeneratorSelector,org.apache.cocoon.transformation.Transformer/xalanPooled,org.apache.cocoon.transformation.Transformer/xalan,org.apache.cocoon.components.modules.input.InputModule/request-scoped-attr,org.apache.cocoon.components.modules.input.InputModule/url-decode,org.apa
che.cocoon.selection.Selector/resource-exists,org.apache.excalibur.source.SourceFactory/*,org.apache.cocoon.acting.ActionSelector,org.apache.cocoon.components.modules.input.InputModule/global,org.apache.cocoon.classloader.ClassLoaderFactory,org.apache.cocoon.i18n.BundleFactory,org.apache.cocoon.components.notification.NotifyingBuilderPooled,org.apache.cocoon.components.notification.NotifyingBuilder,org.apache.cocoon.serialization.Serializer/xhtmlPooled,org.apache.cocoon.serialization.Serializer/xhtml,org.apache.cocoon.components.modules.input.InputModule/flow-attr,org.apache.cocoon.components.expression.ExpressionCompilerSelector,org.apache.cocoon.components.flow.Interpreter/apples,org.apache.cocoon.transformation.Transformer/write-sourcePooled,org.apache.cocoon.transformation.Transformer/write-source,org.apache.cocoon.components.pipeline.ProcessingPipeline/expiresPooled,org.apache.cocoon.components.pipeline.ProcessingPipeline/expires,org.apache.cocoon.components.modules.inpu
t.InputModule/request-param,org.apache.cocoon.transformation.Transformer/jpathPooled,org.apache.cocoon.transformation.Transformer/jpath,org.apache.cocoon.matching.Matcher/request-parameter,org.apache.cocoon.components.modules.input.InputModule/session-attr,org.apache.excalibur.source.SourceFactorySelector,org.apache.cocoon.components.treeprocessor.TreeBuilder/sitemap-1.0Pooled,org.apache.cocoon.components.treeprocessor.TreeBuilder/sitemap-1.0,org.apache.cocoon.matching.Matcher/referer-match,org.apache.cocoon.serialization.Serializer/zipPooled,org.apache.cocoon.serialization.Serializer/zip,org.apache.cocoon.acting.Action/session-invalidator,org.apache.cocoon.components.modules.input.InputModuleSelector,org.apache.cocoon.transformation.Transformer/paginatePooled,org.apache.cocoon.transformation.Transformer/paginate,org.apache.cocoon.transformation.Transformer/encodeURLPooled,org.apache.cocoon.transformation.Transformer/encodeURL,org.apache.cocoon.transformation.Transformer/read
DOMsessionPooled,org.apache.cocoon.transformation.Transformer/readDOMsession,org.apache.cocoon.components.expression.ExpressionCompiler/jxpath,org.apache.cocoon.components.expression.ExpressionCompiler/jexl,org.apache.cocoon.generation.Generator/<aggregator>Pooled,org.apache.cocoon.generation.Generator/<aggregator>,org.apache.cocoon.transformation.Transformer/xsltPooled,org.apache.cocoon.transformation.Transformer/xslt,org.apache.cocoon.transformation.Transformer/xincludePooled,org.apache.cocoon.transformation.Transformer/xinclude,org.apache.excalibur.xml.dom.DOMParserPooled,org.apache.excalibur.xml.dom.DOMParser,org.apache.cocoon.components.modules.input.InputModule/naming,org.apache.cocoon.template.expression.StringTemplateParser,org.apache.cocoon.serialization.Serializer/textPooled,org.apache.cocoon.serialization.Serializer/text,org.apache.cocoon.components.modules.input.InputModule/chain,org.apache.cocoon.components.modules.input.InputModule/date,org.apache.excalibur.stor
e.StoreJanitor,org.apache.cocoon.transformation.TransformerSelector,org.apache.cocoon.template.expression.StringTemplateParser/jxtg,org.apache.cocoon.generation.Generator/mp3directoryPooled,org.apache.cocoon.generation.Generator/mp3directory,org.apache.cocoon.serialization.Serializer/sxwPooled,org.apache.cocoon.serialization.Serializer/sxw,org.apache.cocoon.components.modules.input.InputModule/xmlmeta,org.apache.cocoon.components.modules.input.InputModule/datemeta,org.apache.cocoon.generation.Generator/filePooled,org.apache.cocoon.generation.Generator/file,org.apache.cocoon.acting.Action/session-isvalid,org.apache.cocoon.transformation.Transformer/jxPooled,org.apache.cocoon.transformation.Transformer/jx,org.apache.cocoon.transformation.helpers.IncludeCacheManager,org.apache.cocoon.serialization.SerializerSelector,org.apache.cocoon.selection.Selector/request-method,org.apache.cocoon.components.modules.input.InputModule/digest,org.apache.cocoon.acting.Action/request,org.apache.
cocoon.components.modules.input.InputModule/url-encode,org.apache.cocoon.selection.Selector/host,org.apache.cocoon.components.modules.input.InputModule/constant,org.apache.cocoon.transformation.Transformer/logPooled,org.apache.cocoon.transformation.Transformer/log,org.apache.excalibur.xml.xslt.XSLTProcessor/xalanPooled,org.apache.excalibur.xml.xslt.XSLTProcessor/xalan,org.apache.excalibur.source.SourceFactory/module,org.apache.cocoon.matching.Matcher/wildcard,org.apache.cocoon.components.modules.input.InputModule/simplemap,org.apache.cocoon.caching.Cache,org.apache.excalibur.store.Store/TransientStore,org.apache.cocoon.template.expression.StringTemplateParser/default,org.apache.cocoon.generation.Generator/notifyingPooled,org.apache.cocoon.generation.Generator/notifying,org.apache.cocoon.matching.Matcher/mount-table,org.apache.cocoon.components.modules.input.InputModule/locate,org.apache.cocoon.Processor,org.apache.cocoon.serialization.Serializer/wmlPooled,org.apache.cocoon.se
rialization.Serializer/wml,org.apache.cocoon.serialization.Serializer/svgxmlPooled,org.apache.cocoon.serialization.Serializer/svgxml,org.apache.cocoon.template.expression.StringTemplateParserSelector,org.apache.cocoon.transformation.Transformer/xsltcPooled,org.apache.cocoon.transformation.Transformer/xsltc,org.apache.cocoon.generation.Generator/<notifier>Pooled,org.apache.cocoon.generation.Generator/<notifier>,org.apache.cocoon.components.modules.input.InputModule/cocoon-properties,org.apache.excalibur.source.SourceFactory/zip,org.apache.cocoon.components.pipeline.ProcessingPipeline/noncachingPooled,org.apache.cocoon.components.pipeline.ProcessingPipeline/noncaching,org.apache.cocoon.components.modules.input.InputModule/session,org.apache.cocoon.generation.Generator/statusPooled,org.apache.cocoon.generation.Generator/status,org.apache.cocoon.generation.Generator/exceptionPooled,org.apache.cocoon.generation.Generator/exception,org.apache.excalibur.source.SourceFactory/context,
org.apache.cocoon.components.persistence.RequestDataStore,org.apache.cocoon.serialization.Serializer/linksPooled,org.apache.cocoon.serialization.Serializer/links,org.apache.cocoon.acting.Action/form-validator,org.apache.cocoon.serialization.Serializer/sxcPooled,org.apache.cocoon.serialization.Serializer/sxc,org.apache.cocoon.generation.Generator/streamPooled,org.apache.cocoon.generation.Generator/stream,org.apache.excalibur.xml.xslt.XSLTProcessor/xsltcPooled,org.apache.excalibur.xml.xslt.XSLTProcessor/xsltc,org.apache.cocoon.components.modules.input.InputModule/cookie,org.apache.cocoon.reading.Reader/resourcePooled,org.apache.cocoon.reading.Reader/resource,org.apache.cocoon.transformation.Transformer/<translator>Pooled,org.apache.cocoon.transformation.Transformer/<translator>,org.apache.cocoon.components.modules.input.InputModule/request-header,org.apache.cocoon.components.modules.input.InputModule/realpath,org.apache.cocoon.classloader.ClassLoaderFactory/reloading,org.apache
.cocoon.selection.Selector/request-parameter,org.apache.cocoon.generation.Generator/xpathdirectoryPooled,org.apache.cocoon.generation.Generator/xpathdirectory,org.apache.cocoon.components.expression.ExpressionCompiler/js,org.apache.cocoon.acting.Action/clear-persistent-store,org.apache.cocoon.components.modules.input.InputModule/environment-attr,org.apache.cocoon.acting.Action/locale,org.apache.excalibur.source.SourceFactory/resource,org.apache.cocoon.transformation.Transformer/writeDOMsessionPooled,org.apache.cocoon.transformation.Transformer/writeDOMsession,org.apache.excalibur.xml.sax.SAXParserPooled,org.apache.excalibur.xml.sax.SAXParser,org.apache.cocoon.selection.Selector/parameter,org.apache.cocoon.matching.Matcher/header,org.apache.cocoon.components.modules.output.OutputModuleSelector,org.apache.cocoon.components.pipeline.ProcessingPipeline/cachingPooled,org.apache.cocoon.components.pipeline.ProcessingPipeline/caching,org.apache.cocoon.selection.Selector/simple,org.ap
ache.cocoon.components.modules.input.InputModule/request-attr,org.apache.excalibur.source.SourceFactory/empty,org.apache.excalibur.xml.EntityResolver,org.apache.cocoon.components.expression.ExpressionCompiler/default,org.apache.cocoon.serialization.Serializer/sxiPooled,org.apache.cocoon.serialization.Serializer/sxi,org.apache.cocoon.components.modules.output.OutputModule/request-attr-map,org.apache.cocoon.components.modules.input.InputModule/random,org.apache.cocoon.components.modules.input.InputModule/flow-continuation,org.apache.cocoon.serialization.Serializer/chtmlPooled,org.apache.cocoon.serialization.Serializer/chtml,org.apache.cocoon.acting.Action/req-params,org.apache.cocoon.components.modules.input.InputModule/jxpath,org.apache.cocoon.components.modules.input.InputModule/contextpath,org.apache.cocoon.template.script.InstructionFactory,org.apache.excalibur.source.SourceFactory/file,org.apache.excalibur.xmlizer.XMLizer,org.apache.excalibur.source.SourceFactory/upload,or
g.apache.cocoon.acting.Action/clear-cache,org.apache.cocoon.selection.SelectorSelector,org.apache.excalibur.source.SourceFactory/xmodule,org.apache.cocoon.matching.Matcher/regexp,org.apache.cocoon.components.flow.ContinuationsManager,org.apache.cocoon.components.modules.input.InputModule/baselink,org.apache.cocoon.selection.Selector/browser,org.apache.cocoon.components.modules.input.InputModule/system-property,org.apache.cocoon.serialization.Serializer/vrmlPooled,org.apache.cocoon.serialization.Serializer/vrml,org.apache.cocoon.generation.Generator/virtualPooled,org.apache.cocoon.generation.Generator/virtual,org.apache.cocoon.components.treeprocessor.ProcessorComponentInfo,org.apache.cocoon.core.container.spring.avalon.ConfigurationInfo,org.apache.cocoon.core.container.spring.avalon.AvalonBeanPostProcessor]; root of BeanFactory hierarchy}
> Exception in thread "main" org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.apache.cocoon.core.container.spring.avalon.AvalonBeanPostProcessor': Cannot resolve reference to bean 'org.apache.avalon.framework.logger.Logger' while setting bean property 'logger'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.apache.avalon.framework.logger.Logger': Invocation of init method failed; nested exception is java.net.MalformedURLException
> Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.apache.avalon.framework.logger.Logger': Invocation of init method failed; nested exception is java.net.MalformedURLException
> Caused by: java.net.MalformedURLException
> 	at java.net.URL.<init>(URL.java:601)
> 	at java.net.URL.<init>(URL.java:464)
> 	at java.net.URL.<init>(URL.java:413)
> 	at org.apache.xerces.impl.XMLEntityManager.setupCurrentEntity(Unknown Source)
> 	at org.apache.xerces.impl.XMLVersionDetector.determineDocVersion(Unknown Source)
> 	at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
> 	at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
> 	at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
> 	at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
> 	at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
> 	at org.apache.avalon.framework.configuration.DefaultConfigurationBuilder.build(DefaultConfigurationBuilder.java:254)
> 	at org.apache.avalon.framework.configuration.DefaultConfigurationBuilder.build(DefaultConfigurationBuilder.java:202)
> 	at org.apache.cocoon.core.container.spring.avalon.AvalonLoggerFactoryBean.init(AvalonLoggerFactoryBean.java:94)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> 	at java.lang.reflect.Method.invoke(Method.java:585)
> 	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeCustomInitMethod(AbstractAutowireCapableBeanFactory.java:1104)
> 	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1066)
> 	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1029)
> 	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:420)
> 	at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:245)
> 	at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:141)
> 	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:242)
> 	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:156)
> 	at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:246)
> 	at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:128)
> 	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:955)
> 	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:729)
> 	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:416)
> 	at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:245)
> 	at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:141)
> 	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:242)
> 	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:156)
> 	at org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeansOfType(DefaultListableBeanFactory.java:238)
> 	at org.springframework.context.support.AbstractApplicationContext.getBeansOfType(AbstractApplicationContext.java:697)
> 	at org.springframework.context.support.AbstractApplicationContext.registerBeanPostProcessors(AbstractApplicationContext.java:441)
> 	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:333)
> 	at org.springframework.web.context.support.AbstractRefreshableWebApplicationContext.refresh(AbstractRefreshableWebApplicationContext.java:156)
> 	at com.mobilebox.viessmann.pi.server.Test.main(Test.java:172)

-- 
Leszek Gawron                                    CTO at MobileBox Ltd.


Re: [2.2] Runtime deployment

Posted by Daniel Fagerstrom <da...@nada.kth.se>.
Leszek Gawron skrev:
> Joerg Heinicke wrote:
>> On 03.11.2006 23:17, Carsten Ziegeler wrote:
>>> With the help from Leszek we now have a Cocoon version in trunk which
>>> does not need any deployment plugin. This means you can just drop the
>>> jar files into WEB-INF/lib and are done! So it doesn't matter if you're
>>> using Maven, Ant or some other strange tool :)
>>> All you need is the main Spring applicationContext.xml with our two
>>> elements for setting up Cocoon and the Avalon bridge.
>>
>> Thanks very much for your efforts. I highly appreciate everything 
>> easing the usage of Cocoon.
>>
>>> Once we have solved these three issues we should release a RC-1 asap.
>>
>> +1
> I still would like 2 things resolved (maybe not directly fixed but at 
> least addressed somehow):
> - running cocoon without servlet context

The far easiest way to achieve this is to create a mock servlet context. 
Only a handful of methods needs implementation that require a non null 
answer.

/Daniel


Re: [2.2] Runtime deployment

Posted by Leszek Gawron <lg...@mobilebox.pl>.
Joerg Heinicke wrote:
> On 03.11.2006 23:17, Carsten Ziegeler wrote:
>> With the help from Leszek we now have a Cocoon version in trunk which
>> does not need any deployment plugin. This means you can just drop the
>> jar files into WEB-INF/lib and are done! So it doesn't matter if you're
>> using Maven, Ant or some other strange tool :)
>> All you need is the main Spring applicationContext.xml with our two
>> elements for setting up Cocoon and the Avalon bridge.
> 
> Thanks very much for your efforts. I highly appreciate everything easing 
> the usage of Cocoon.
> 
>> Once we have solved these three issues we should release a RC-1 asap.
> 
> +1
I still would like 2 things resolved (maybe not directly fixed but at 
least addressed somehow):
- running cocoon without servlet context
- fixing cocoon deployer classloading issues

-- 
Leszek Gawron                                    CTO at MobileBox Ltd.


Re: [2.2] Runtime deployment

Posted by Joerg Heinicke <jo...@gmx.de>.
On 03.11.2006 23:17, Carsten Ziegeler wrote:
> With the help from Leszek we now have a Cocoon version in trunk which
> does not need any deployment plugin. This means you can just drop the
> jar files into WEB-INF/lib and are done! So it doesn't matter if you're
> using Maven, Ant or some other strange tool :)
> All you need is the main Spring applicationContext.xml with our two
> elements for setting up Cocoon and the Avalon bridge.

Thanks very much for your efforts. I highly appreciate everything easing 
the usage of Cocoon.

> Once we have solved these three issues we should release a RC-1 asap.

+1

Jörg