On 19 Feb 2013, at 18:08, Karl Heinz Marbaise wrote:
> Hi Robert,
> Hi Stuart,
>
> > InvocationRequest is not a Component, it is just an interface for
>> DefaultInvocationRequest.
>
> oh my lord... ;-(
>
> Thanks for enlighten me...
>
> Which means in other words to make the InvocationRequest being a component
> it's missing simply this:
>
> @Component( role = InvocationRequest.class, hint = "default" )
> public class DefaultInvocationRequest
> implements InvocationRequest
Setting aside the issue of whether DefaultInvocationRequest should really be a
component, note that @Component by default defines a singleton component. You
need to add:
instantiationStrategy = "per-lookup"
to get a new instance on every lookup, otherwise you'd always get the same
instance which would be bad if two threads wanted to populate InvocationRequest
at the same time.
> and these two lines...
>
> public interface InvocationRequest {
>
> String ROLE = InvocationRequest.class.getName();
>
> Ok...many thanks...for helping...
>
> BTW: Just for the interest is there any good reason not to make
> InvocationRequest a component ?
AFAIK InvocationRequest is just an abstraction to pass parameters, settings,
environment etc. into the Invoker rather than something with identity/lifecycle.
> So this helps me a lot...
>
> Kind regards
> Karl-Heinz Marbaise
> --
> SoftwareEntwicklung Beratung Schulung Tel.: +49 (0) 2405 / 415 893
> Dipl.Ing.(FH) Karl-Heinz Marbaise ICQ#: 135949029
> Hauptstrasse 177 USt.IdNr: DE191347579
> 52146 Würselen http://www.soebes.de
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]