Paul's correct -- in 1.1, SpringBeanRouter only looks at the aliases.   
Spring doesn't consider the name to be an alias unless there's also an  
id.  In 1.2, SpringBeanRouter will consider the bean's primary  
identifier in addition to the aliases.

Rhett

On Apr 24, 2009, at 10:07 AM, Paul Austin wrote:

> Give you bean an id in addition to the name. I think there was a bug  
> in the 1.1.x series which required there to be an id.
>
> <bean name="/services" id="services" ....
>
> Paul
>
>
> On Fri, Apr 24, 2009 at 1:43 AM, Stephane Nicoll <stephane.nic...@gmail.com 
> > wrote:
> Hi,
>
> I am trying to use the spring based config in 1.1.4 with Spring  
> 2.5.6 and I just can't get it working.
>
> My Application adds additional filters, one of them being my main  
> router as a SpringBeanRouter class.
>
> I have a set of resources and restlet defined in the same  
> application context file and I can see through the debugger they are  
> loaded and discovered by the Spring Bean router.
>
> In the 'postProcessBeanFactory' method of the SpringBeanRouter, the  
> resolveUri always returns null because the aliases returned by the  
> factory is an empty String. I honestly don't get it!
>
> Here's is one entry in my spring config file
>
>  <bean name="/services" autowire="byName" scope="prototype"           
> class="com.foo.service.ServicesResource">
>        <property name="context" ref="restletContext"/>
>    </bean>
>
> ---------
>
> Any idea? Is the autowire byName mandatory?
>
> Is there a sample somewhere?
>
> Thanks,
> Stéphane
>
> ------------------------------------------------------
> http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=1888396
>

------------------------------------------------------
http://restlet.tigris.org/ds/viewMessage.do?dsForumId=4447&dsMessageId=1894008

Reply via email to