Re: Override AssertSource

2014-01-31 Thread Thiago H de Paula Figueiredo
On Fri, 31 Jan 2014 16:29:28 -0200, Dimitris Zenios wrote: Create the assetSource inside bind method then inject it inside the contributeSerrviceOverride and instead of addInstance use plain add Or just decorate the service instead of overriding it. The result is the same, but you avoid t

Re: Override AssertSource

2014-01-31 Thread Dimitris Zenios
Create the assetSource inside bind method then inject it inside the contributeSerrviceOverride and instead of addInstance use plain add On Fri, Jan 31, 2014 at 7:43 PM, garz wrote: > With addInstance the exception is: > > java.lang.IllegalStateException: Construction of service 'ServiceOverrid

Re: Override AssertSource

2014-01-31 Thread garz
With addInstance the exception is: java.lang.IllegalStateException: Construction of service 'ServiceOverride' has failed due to recursion: the service depends on itself in some way. Please check org.apache.tapestry5.ioc.internal.services.ServiceOverrideImpl(Map) (at ServiceOverrideImpl.java:31)

Re: Override AssertSource

2014-01-31 Thread Dusko Jovanovski
try configuration.addInstance(AssetSource.class, MyAssetSourceImpl.class); Here's the documentation for MappedConfiguration: http://tapestry.apache.org/current/apidocs/org/apache/tapestry5/ioc/MappedConfiguration.html On Fri, Jan 31, 2014 at 5:05 PM, garz wrote: > Hi all, > > i want to overrid

Override AssertSource

2014-01-31 Thread garz
Hi all, i want to override the AssetSource service. I am doing it like described in http://tapestry.apache.org/ioc-cookbook-overriding-ioc-services.html like this: @Contribute(ServiceOverride.class) public static void setupApplicationServiceOverrides( Mapp