You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Lally Singh <la...@gmail.com> on 2007/03/05 21:52:22 UTC

Skipping cocoon-rcl-webapp-wrapper?

Hey all,

 I'm getting this when I build my project, which is a set of cocoon-22 blocks:
2007-03-05 15:15:20.661::WARN:  Nested in
org.springframework.beans.factory.BeanDefinitionStoreException:
Unexpected exception parsing XML document from ServletContext resource
[/WEB-INF/applicationContext.xml]; nested exception is
java.lang.NoSuchMethodError:
org.apache.avalon.framework.configuration.DefaultConfigurationBuilder.build(Ljava/io/InputStream;Ljava/lang/String;)Lorg/apache/avalon/framework/configuration/Configuration;:
java.lang.NoSuchMethodError:
org.apache.avalon.framework.configuration.DefaultConfigurationBuilder.build(Ljava/io/InputStream;Ljava/lang/String;)Lorg/apache/avalon/framework/configuration/Configuration;

And it appears (from some googlin') that a nice clean-rebuild of
cocoon should fix this up.

So, I head over to my cocoon svn trunk, do my svn update; mvn
-Dmaven.test.skip=true -Dallblocks install, and I get these:

/usr/local/svn_apache/cocoon/tools/cocoon-rcl/cocoon-rcl-webapp-wrapper/src/main/java/org/apache/cocoon/servlet/CocoonReloadingListener.java:[32,8]
cannot find symbol
symbol  : constructor ReloadingListener()
location: class org.apache.commons.jci.listeners.ReloadingListener

/usr/local/svn_apache/cocoon/tools/cocoon-rcl/cocoon-rcl-webapp-wrapper/src/main/java/org/apache/cocoon/servlet/CocoonReloadingListener.java:[36,13]
cannot find symbol
symbol  : method onFileChange(java.io.File)
location: class org.apache.commons.jci.listeners.ReloadingListener

...

Which, upon looking at javadocs for ReloadingListener, I completely
agree with.

So, unless anyone has any good ideas for making it compile properly,
is there some way to skip building cocoon-rcl-webapp-wrapper?

Thanks in advance for any help,

-ls

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: Skipping cocoon-rcl-webapp-wrapper?

Posted by Lally Singh <la...@gmail.com>.
On 3/5/07, Grzegorz Kossakowski <gr...@tuffmail.com> wrote:
> Lally Singh napisał(a):
> > Is there a similar situation with avalon-framework-impl?  Cocoon will
> > build, but as soon as I try and add hibernate/mysql to a simple block,
> > it dies.
> > org.apache.cocoon.core.container.spring.avalon.ConfigurationReader is
> > unable to find
> > org.apache.avalon.framework.configuration.DefaultConfigurationBuilder.build(InputStream,String).
> >
> There has been an issue with avalon-framework-impl some time ago [1].
> First thing I'd suggest is to remove ~/.m2/repository to be sure that
> you have not any old junk that interferes. If it not helps would be
> great if you provided some details:
> 1. How do you start your application?
> 2. How it's build and packaged?
> 3. The most important: did you created your app with block/webapp
> archetype if so, how long ago?


Wow, thanks for the quick response!  The blocks were created from the
"Your first Cocoon application using Maven 2" tutorial[1].  But, I
didn't put in the additional <repository> tags it recommended, which
suddenly solved all my problems.

If anyone's viewing this thread and had this problem, here's my setup:
I made two cocoon blocks, one for the app as a whole, and one
containing some application code, just as specified in the
tutorial[1].

I didn't put in the following parts, which should be in there:
<repositories>
  [...]
  <repository>
    <id>apache.snapshot</id>
    <name>Apache Snapshot Repository</name>
    <url>http://people.apache.org/repo/m2-snapshot-repository</url>
    <releases>
      <!-- excalibur poms are located here -->
      <enabled>true</enabled>
    </releases>
    <snapshots>
      <enabled>true</enabled>
    </snapshots>
  </repository>
  [...]
</repositories>

That solved my problem.

[1] http://cocoon.zones.apache.org/daisy/documentation/g3/1159.html

Re: Skipping cocoon-rcl-webapp-wrapper?

Posted by Grzegorz Kossakowski <gr...@tuffmail.com>.
Lally Singh napisał(a):
> Is there a similar situation with avalon-framework-impl?  Cocoon will
> build, but as soon as I try and add hibernate/mysql to a simple block,
> it dies.
> org.apache.cocoon.core.container.spring.avalon.ConfigurationReader is
> unable to find
> org.apache.avalon.framework.configuration.DefaultConfigurationBuilder.build(InputStream,String).
>
There has been an issue with avalon-framework-impl some time ago [1].
First thing I'd suggest is to remove ~/.m2/repository to be sure that
you have not any old junk that interferes. If it not helps would be
great if you provided some details:
1. How do you start your application?
2. How it's build and packaged?
3. The most important: did you created your app with block/webapp
archetype if so, how long ago?


[1] https://issues.apache.org/jira/browse/COCOON-1975

-- 
Grzegorz Kossakowski

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: Skipping cocoon-rcl-webapp-wrapper?

Posted by Reinhard Poetz <re...@apache.org>.
Lally Singh wrote:

> Is there a similar situation with avalon-framework-impl?

Make sure by using exclusions that you don't get any other Avalon or Excalibur 
dependencies than those that are coming from cocoon-core. If there are still 
wrong dependencies showing up, build by using the -X switch and look at the 
dependency graph resolution logs and find out which dependency is responsible 
and add an exclusion there.

Also be aware that commons-logging and commons-jxpath come with poms of poor 
quality. If you add them explicitly, take care of removing all unnecessary 
dependencies (see 
http://svn.apache.org/repos/asf/cocoon/trunk/core/cocoon-core/pom.xml and 
http://svn.apache.org/repos/asf/cocoon/trunk/core/cocoon-sitemap/cocoon-sitemap-impl/pom.xml)

-- 
Reinhard Pötz           Independent Consultant, Trainer & (IT)-Coach 

{Software Engineering, Open Source, Web Applications, Apache Cocoon}

                                        web(log): http://www.poetz.cc
--------------------------------------------------------------------

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Re: Skipping cocoon-rcl-webapp-wrapper?

Posted by Lally Singh <la...@gmail.com>.
On 3/5/07, Grzegorz Kossakowski <gr...@tuffmail.com> wrote:
> Lally Singh napisał(a):
> > Hey all,
> >
> >
> cocoon-rcl has been updated lately to use new api of commons-jci.
> However, commons-jci is not released yet so some snapshot version is
> being used and that causes problems. Maven finds some old snapshot with
> old api and uses it for build resulting with an error. That's the price
> for depending on the unreleased artifacts...
>
> There are two solutions:
> 1. Remove cocoon-rcl from the build if you do not need it. You'll have
> to modify some poms.
> 2. Tell Maven to use newest version by doing this:
>
> svn checkout http://svn.apache.org/repos/asf/jakarta/commons/sandbox/jci/trunk commons-jci
>
> cd commons-jci
> mvn clean install -Dmaven.test.skip=true
> Skipping test could be necessary, at least for me they do not work.
>
> After that you should build your Cocoon normally. All this mess will be
> get sort out soon. (release of jci is planned)

Wonderful, thank you.  Cocoon builds normally gain.

Is there a similar situation with avalon-framework-impl?  Cocoon will
build, but as soon as I try and add hibernate/mysql to a simple block,
it dies.
org.apache.cocoon.core.container.spring.avalon.ConfigurationReader is
unable to find
org.apache.avalon.framework.configuration.DefaultConfigurationBuilder.build(InputStream,String).

Re: Skipping cocoon-rcl-webapp-wrapper?

Posted by Grzegorz Kossakowski <gr...@tuffmail.com>.
Lally Singh napisał(a):
> Hey all,
>
> -Dmaven.test.skip=true -Dallblocks install, and I get these:
skipping tests is not necessary anymore, they should all work fine.
>
> /usr/local/svn_apache/cocoon/tools/cocoon-rcl/cocoon-rcl-webapp-wrapper/src/main/java/org/apache/cocoon/servlet/CocoonReloadingListener.java:[32,8]
>
> cannot find symbol
> symbol  : constructor ReloadingListener()
> location: class org.apache.commons.jci.listeners.ReloadingListener
>
> /usr/local/svn_apache/cocoon/tools/cocoon-rcl/cocoon-rcl-webapp-wrapper/src/main/java/org/apache/cocoon/servlet/CocoonReloadingListener.java:[36,13]
>
> cannot find symbol
> symbol  : method onFileChange(java.io.File)
> location: class org.apache.commons.jci.listeners.ReloadingListener
>
> ...
>
> Which, upon looking at javadocs for ReloadingListener, I completely
> agree with.
>
> So, unless anyone has any good ideas for making it compile properly,
> is there some way to skip building cocoon-rcl-webapp-wrapper?
>
> Thanks in advance for any help,
>
cocoon-rcl has been updated lately to use new api of commons-jci.
However, commons-jci is not released yet so some snapshot version is
being used and that causes problems. Maven finds some old snapshot with
old api and uses it for build resulting with an error. That's the price
for depending on the unreleased artifacts...

There are two solutions:
1. Remove cocoon-rcl from the build if you do not need it. You'll have
to modify some poms.
2. Tell Maven to use newest version by doing this:

svn checkout http://svn.apache.org/repos/asf/jakarta/commons/sandbox/jci/trunk commons-jci

cd commons-jci
mvn clean install -Dmaven.test.skip=true
Skipping test could be necessary, at least for me they do not work.

After that you should build your Cocoon normally. All this mess will be
get sort out soon. (release of jci is planned)

-- 
Grzegorz Kossakowski

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org