You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Vadim Gritsenko <va...@reverycodes.com> on 2007/12/06 18:08:42 UTC

cocoon-webapp failure

Hi guys,

There is a failure when trying to start latest cocoon-webapp:

ERROR [main] (ContextLoader.java:206) - Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error  
creating bean with name  
'org.apache.cocoon.components.source.helpers.DelaySourceRefresher'  
defined in URL [jar:file:/Users/vgritsenko/.m2/repository/org/apache/ 
cocoon/cocoon-core/2.2.0-RC3-SNAPSHOT/cocoon-core-2.2.0-RC3- 
SNAPSHOT.jar!/META-INF/cocoon/spring/cocoon-core-caching-source.xml]:  
Cannot resolve reference to bean  
'org.apache.cocoon.thread.RunnableManager' while setting bean property  
'runnableManager'; nested exception is  
org.springframework.beans.factory.BeanCreationException: Error  
creating bean with name 'org.apache.cocoon.thread.RunnableManager'  
defined in URL [jar:file:/Users/vgritsenko/.m2/repository/org/apache/ 
cocoon/cocoon-thread-impl/1.0.0-RC3-SNAPSHOT/cocoon-thread-impl-1.0.0- 
RC3-SNAPSHOT.jar!/META-INF/cocoon/spring/cocoon-thread-impl.xml]:  
Invocation of init method failed; nested exception is  
org.springframework.beans.factory.BeanDefinitionStoreException: Error  
registering bean with name  
'org.apache.cocoon.portal.om.CopletAdapter.cocoon' defined in URL  
[jar:file:/Users/vgritsenko/Projects/Apache/cocoon/core/cocoon-webapp/ 
target/cocoon-webapp/WEB-INF/lib/cocoon-portal-sitemap-1.0.0- 
SNAPSHOT.jar!/META-INF/cocoon/spring/cocoon-portal-sitemap- 
components.xml]: Could not resolve parent bean definition  
'org.apache.cocoon.portal.coplet.adapter.impl.AbstractCopletAdapter';  
nested exception is  
org.springframework.beans.factory.NoSuchBeanDefinitionException: No  
bean named  
'org.apache.cocoon.portal.coplet.adapter.impl.AbstractCopletAdapter'  
is defined
         at  
org 
.springframework 
.beans 
.factory 
.support 
.BeanDefinitionValueResolver 
.resolveReference(BeanDefinitionValueResolver.java:274)

Seems to be somehow related to portal beans. Can somebody take a look?

Thanks,
Vadim


Re: cocoon-webapp failure

Posted by Vadim Gritsenko <va...@reverycodes.com>.
On Dec 7, 2007, at 3:58 AM, Jeroen Reijn wrote:

> No need to rush Carsten.

Actually there is a reason to rush... or at least to hurry a bit:

   http://cocoon.zones.apache.org/demos/trunk/

Vadim

RE: cocoon-webapp failure

Posted by Jeroen Reijn <j....@hippo.nl>.
No need to rush Carsten. 
I was just under the impression that it was fixed for Vadim, therefore
my question :-)

Thanks anyway!

Gr.

Jeroen



-----Original Message-----
From: Carsten Ziegeler [mailto:cziegeler@apache.org] 
Sent: Friday, December 07, 2007 9:01 AM
To: dev@cocoon.apache.org
Subject: Re: cocoon-webapp failure

Vadim Gritsenko wrote:
> On Dec 6, 2007, at 6:43 PM, Jeroen Reijn wrote:
> 
>> Vadim,
>>
>> did the update work for you? I'm still having problems even after
>> clearing my m2 repository.
>>
>> org.springframework.beans.factory.NoSuchBeanDefinitionException: No
bean
>> named
>> 'org.apache.cocoon.portal.coplet.adapter.impl.AbstractCopletAdapter'
is
>> defined
> 
> I found a fix for this... Only to discover that
> 'org.apache.cocoon.portal.PortalService' is not defined anywhere...
> Still not working.
> 
As I said, there are some things not finished, but I'll look at them in
the next days.

Carsten

-- 
Carsten Ziegeler
cziegeler@apache.org

Re: cocoon-webapp failure

Posted by Carsten Ziegeler <cz...@apache.org>.
Vadim Gritsenko wrote:
> On Dec 6, 2007, at 6:43 PM, Jeroen Reijn wrote:
> 
>> Vadim,
>>
>> did the update work for you? I'm still having problems even after
>> clearing my m2 repository.
>>
>> org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean
>> named
>> 'org.apache.cocoon.portal.coplet.adapter.impl.AbstractCopletAdapter' is
>> defined
> 
> I found a fix for this... Only to discover that
> 'org.apache.cocoon.portal.PortalService' is not defined anywhere...
> Still not working.
> 
As I said, there are some things not finished, but I'll look at them in
the next days.

Carsten

-- 
Carsten Ziegeler
cziegeler@apache.org

Re: cocoon-webapp failure

Posted by Vadim Gritsenko <va...@reverycodes.com>.
On Dec 6, 2007, at 6:43 PM, Jeroen Reijn wrote:

> Vadim,
>
> did the update work for you? I'm still having problems even after
> clearing my m2 repository.
>
> org.springframework.beans.factory.NoSuchBeanDefinitionException: No  
> bean
> named
> 'org.apache.cocoon.portal.coplet.adapter.impl.AbstractCopletAdapter'  
> is
> defined

I found a fix for this... Only to discover that  
'org.apache.cocoon.portal.PortalService' is not defined anywhere...  
Still not working.

Vadim

Re: cocoon-webapp failure

Posted by Jeroen Reijn <j....@hippo.nl>.
Vadim,

did the update work for you? I'm still having problems even after
clearing my m2 repository.

org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean
named
'org.apache.cocoon.portal.coplet.adapter.impl.AbstractCopletAdapter' is
defined

Regards,

Jeroen



On Thu, 2007-12-06 at 16:19 -0500, Vadim Gritsenko wrote:
> On Dec 6, 2007, at 12:21 PM, Carsten Ziegeler wrote:
> 
> > Vadim Gritsenko wrote
> >>
> >>
> >> Seems to be somehow related to portal beans. Can somebody take a  
> >> look?
> >>
> > I think I just fixed this one - however the current state of the  
> > portal
> > is very fragile and I don't expect it to work properly.
> 
> Thanks for quick fix! btw why bean is named  
> "org.apache.cocoon.portal.om.CopletAdapter.cocoon" and not  
> "org.apache.cocoon.portal.om.CopletAdapter/cocoon"?
> 
> Vadim

Re: Spring bean names

Posted by Carsten Ziegeler <cz...@apache.org>.
Vadim Gritsenko schrieb:
> On Dec 7, 2007, at 1:08 PM, Carsten Ziegeler wrote:
> 
>> The [Spring Configurator's bean] map uses the interface to search for
>> all beans of this
>> interface. Then the interface name is used as a prefix to find the
>> selector hint (key). So if a bean for interface "foo.Bar" is found and
>> has the bean name "foo.Bar.x" , the bean is registered with "x" in the
>> map. If the name is "foo.Bar/y", it's registered with "y" in the map.
> 
> Ok, good to know.
> 
> But what would happen if bean's name is not prefixed with the interface
> name? So bean is named just 'baz' but it implements 'foo.Bar' interface?
> 
Then "baz" is used as the key. The algorithm first checks if the name starts
with the interface name. If so, it removes this prefix. If not it uses
the name as the key.
In addition the bean itself can define the bean through a property I think.

So, as always: everything is possible :)

Carsten


-- 
Carsten Ziegeler
cziegeler@apache.org

Re: Spring bean names

Posted by Vadim Gritsenko <va...@reverycodes.com>.
On Dec 7, 2007, at 1:08 PM, Carsten Ziegeler wrote:

> The [Spring Configurator's bean] map uses the interface to search  
> for all beans of this
> interface. Then the interface name is used as a prefix to find the
> selector hint (key). So if a bean for interface "foo.Bar" is found and
> has the bean name "foo.Bar.x" , the bean is registered with "x" in the
> map. If the name is "foo.Bar/y", it's registered with "y" in the map.

Ok, good to know.

But what would happen if bean's name is not prefixed with the  
interface name? So bean is named just 'baz' but it implements  
'foo.Bar' interface?

Vadim

Re: Spring bean names

Posted by Carsten Ziegeler <cz...@apache.org>.
Vadim Gritsenko wrote:
>>
>> It's not really a problem. You can't use "/" in id attributes. That
>> was the reason why <bean name=""/> was introduced because Spring
>> webflow needed a way to put URIs into bean ids.
> 
> But we are talking about name attribute? Is there a problem with it too?
> 
No, I don't think so - now I think I remember - I used the "id"
attribute at some point of time (therefore the dot) and later on I found
out about the name attribute.

> 
>>>> it doesn't matter as these components are
>>>> accessed through our spring configurator bean map and this bean map
>>>> checks for boths versions.
>>> Did not know this; I thought only '/' is allowed.
>>
>> The "/" is used if an Avalon selector is mimicked. If you access
>> Spring beans using the Spring Configurator's bean map, the name
>> doesn't matter because the selection is done based on the interface name.
> 
> So Carsten was wrong above? It does not rely on syntax but interface name?
> 
Both :) The map uses the interface to search for all beans of this
interface. Then the interface name is used as a prefix to find the
selector hint (key). So if a bean for interface "foo.Bar" is found and
has the bean name "foo.Bar.x" , the bean is registered with "x" in the
map. If the name is "foo.Bar/y", it's registered with "y" in the map.

Carsten

-- 
Carsten Ziegeler
cziegeler@apache.org

Re: Spring bean names

Posted by Reinhard Poetz <re...@apache.org>.
Vadim Gritsenko wrote:
> On Dec 7, 2007, at 9:25 AM, Reinhard Poetz wrote:
> 
>> Vadim Gritsenko wrote:
>>> On Dec 7, 2007, at 2:59 AM, Carsten Ziegeler wrote:
>>>> Vadim Gritsenko wrote:
>>>>>
>>>>> Thanks for quick fix! btw why bean is named
>>>>> "org.apache.cocoon.portal.om.CopletAdapter.cocoon" and not
>>>>> "org.apache.cocoon.portal.om.CopletAdapter/cocoon"?
>>>>>
>>>> Good question - to be honest, I don't know :)
>>>> I think there were some problems with using a "/" in Spring bean names
>>> Hmm... That's bad.
>>
>> It's not really a problem. You can't use "/" in id attributes. That 
>> was the reason why <bean name=""/> was introduced because Spring 
>> webflow needed a way to put URIs into bean ids.
> 
> But we are talking about name attribute? Is there a problem with it too?

No. The name attribute is of type xsd:string, which allows "/" as value. The id 
attribute is of type xsd:id which doesn't.

-- 
Reinhard Pötz                            Managing Director, {Indoqa} GmbH
                           http://www.indoqa.com/en/people/reinhard.poetz/

Member of the Apache Software Foundation
Apache Cocoon Committer, PMC member, PMC Chair        reinhard@apache.org
_________________________________________________________________________

Re: Spring bean names

Posted by Vadim Gritsenko <va...@reverycodes.com>.
On Dec 7, 2007, at 9:25 AM, Reinhard Poetz wrote:

> Vadim Gritsenko wrote:
>> On Dec 7, 2007, at 2:59 AM, Carsten Ziegeler wrote:
>>> Vadim Gritsenko wrote:
>>>>
>>>> Thanks for quick fix! btw why bean is named
>>>> "org.apache.cocoon.portal.om.CopletAdapter.cocoon" and not
>>>> "org.apache.cocoon.portal.om.CopletAdapter/cocoon"?
>>>>
>>> Good question - to be honest, I don't know :)
>>> I think there were some problems with using a "/" in Spring bean  
>>> names
>> Hmm... That's bad.
>
> It's not really a problem. You can't use "/" in id attributes. That  
> was the reason why <bean name=""/> was introduced because Spring  
> webflow needed a way to put URIs into bean ids.

But we are talking about name attribute? Is there a problem with it too?


>>> it doesn't matter as these components are
>>> accessed through our spring configurator bean map and this bean map
>>> checks for boths versions.
>> Did not know this; I thought only '/' is allowed.
>
> The "/" is used if an Avalon selector is mimicked. If you access  
> Spring beans using the Spring Configurator's bean map, the name  
> doesn't matter because the selection is done based on the interface  
> name.

So Carsten was wrong above? It does not rely on syntax but interface  
name?

Vadim

Spring bean names

Posted by Reinhard Poetz <re...@apache.org>.
Vadim Gritsenko wrote:
> On Dec 7, 2007, at 2:59 AM, Carsten Ziegeler wrote:
> 
>> Vadim Gritsenko wrote:
>>>
>>> Thanks for quick fix! btw why bean is named
>>> "org.apache.cocoon.portal.om.CopletAdapter.cocoon" and not
>>> "org.apache.cocoon.portal.om.CopletAdapter/cocoon"?
>>>
>> Good question - to be honest, I don't know :)
>> I think there were some problems with using a "/" in Spring bean names
> 
> Hmm... That's bad.

It's not really a problem. You can't use "/" in id attributes. That was the 
reason why <bean name=""/> was introduced because Spring webflow needed a way to 
put URIs into bean ids.

>> and I saw that I used a "." already in other configurations for the
>> portal. I guess in the end, it doesn't matter as these components are
>> accessed through our spring configurator bean map and this bean map
>> checks for boths versions.
> 
> Did not know this; I thought only '/' is allowed.

The "/" is used if an Avalon selector is mimicked. If you access Spring beans 
using the Spring Configurator's bean map, the name doesn't matter because the 
selection is done based on the interface name.

-- 
Reinhard Pötz                            Managing Director, {Indoqa} GmbH
                           http://www.indoqa.com/en/people/reinhard.poetz/

Member of the Apache Software Foundation
Apache Cocoon Committer, PMC member, PMC Chair        reinhard@apache.org
_________________________________________________________________________

Re: cocoon-webapp failure

Posted by Vadim Gritsenko <va...@reverycodes.com>.
On Dec 7, 2007, at 2:59 AM, Carsten Ziegeler wrote:

> Vadim Gritsenko wrote:
>>
>> Thanks for quick fix! btw why bean is named
>> "org.apache.cocoon.portal.om.CopletAdapter.cocoon" and not
>> "org.apache.cocoon.portal.om.CopletAdapter/cocoon"?
>>
> Good question - to be honest, I don't know :)
> I think there were some problems with using a "/" in Spring bean names

Hmm... That's bad.


> and I saw that I used a "." already in other configurations for the
> portal. I guess in the end, it doesn't matter as these components are
> accessed through our spring configurator bean map and this bean map
> checks for boths versions.

Did not know this; I thought only '/' is allowed.

Thanks,
Vadim

Re: cocoon-webapp failure

Posted by Carsten Ziegeler <cz...@apache.org>.
Vadim Gritsenko wrote:
> On Dec 6, 2007, at 12:21 PM, Carsten Ziegeler wrote:
> 
>> Vadim Gritsenko wrote
>>>
>>>
>>> Seems to be somehow related to portal beans. Can somebody take a look?
>>>
>> I think I just fixed this one - however the current state of the portal
>> is very fragile and I don't expect it to work properly.
> 
> Thanks for quick fix! btw why bean is named
> "org.apache.cocoon.portal.om.CopletAdapter.cocoon" and not
> "org.apache.cocoon.portal.om.CopletAdapter/cocoon"?
> 
Good question - to be honest, I don't know :)
I think there were some problems with using a "/" in Spring bean names
and I saw that I used a "." already in other configurations for the
portal. I guess in the end, it doesn't matter as these components are
accessed through our spring configurator bean map and this bean map
checks for boths versions.

Carsten

-- 
Carsten Ziegeler
cziegeler@apache.org

Re: cocoon-webapp failure

Posted by Vadim Gritsenko <va...@reverycodes.com>.
On Dec 6, 2007, at 12:21 PM, Carsten Ziegeler wrote:

> Vadim Gritsenko wrote
>>
>>
>> Seems to be somehow related to portal beans. Can somebody take a  
>> look?
>>
> I think I just fixed this one - however the current state of the  
> portal
> is very fragile and I don't expect it to work properly.

Thanks for quick fix! btw why bean is named  
"org.apache.cocoon.portal.om.CopletAdapter.cocoon" and not  
"org.apache.cocoon.portal.om.CopletAdapter/cocoon"?

Vadim

Re: cocoon-webapp failure

Posted by Carsten Ziegeler <cz...@apache.org>.
Vadim Gritsenko wrote
> 
> 
> Seems to be somehow related to portal beans. Can somebody take a look?
> 
I think I just fixed this one - however the current state of the portal
is very fragile and I don't expect it to work properly.

Carsten

-- 
Carsten Ziegeler
cziegeler@apache.org