struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Lukasz Lenart <>
Subject Re: LocaleProvder not unique
Date Mon, 13 Mar 2017 18:08:04 GMT
2017-03-13 19:03 GMT+01:00 Christian Grobmeier <>:
> Sorry, one more thing.
> With removing the @Service annotation I delegated the instantiation of
> the Actions to Struts as the Spring component scanner will not find my
> Bean no more. Struts - to my knowledge - will somehow create the bean
> using Spring too.
> The problem to use the applicationContext outside the web environment, i
> .e. test cases.
> Wether @Service was right or not, I need to somehow tell Spring how to
> find my beans (i.e. @Component).
> I can understand Springs confusion, when it realizes every Action is a
> LocaleProvider.
> Is there any best practice?

Struts will delegate creation of any object to Spring, if Spring fails
it will fall back to Struts ObjectFactory to create the object. So as
far I know, Spring should be able create an object from a class with
default constructor implemented.

+ 48 606 323 122

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message