> I presume you mean marking beans with something like
>  @Conversation(lifetime="access", name="myConversation")
> or
>  @Scope(scope="conversation.access", name="myConversation")

or
@Conversation(scope="access", name="myConversation")

>
> Yes that would be cool.
>
> It's debatable whether the annotation should be in the Spring framework or in 
> Orchestra.

I think in Orchestra we are able to get fixes in faster.
(not knowing the community / company behind Spring well)

>
> The first example is the sort of thing that might belong in Orchestra. 
> Support would then need to be implemented within orchestra for each DI 
> framework that Orchestra supports - assuming the framework provides 
> sufficient hooks to do that.
>
> The second example is more spring-specific, as it is tied to the fact that in 
> the Orchestra Spring binding, a conversation scope is actually a bean which 
> has a name eg "conversation.access".
>
> BTW, we really do need to sort out the problem of defining the 
> conversation-name and the lifetime at the same point. It is very convenient 
> for the basic case, but when multiple beans are in the same conversation then 
> they must declare the same lifetime values which is inelegant (data 
> duplication).
>
> > > And do you think it is possible to have proxy scoped bean using
> > > annotation?
> > If you use the latest Orchestra snapshot you do not have to use the
> > aop:scoped-proxy anymore. This will be done automatically by Orchestra.
> > For other proxy scoped beans, Simon tried something in this area, and as
> > far as I remember with success. Even though Spring should provide such a
> > annotation on their own, we probably can share our code if wanted. It is
> > not part of Orchestra.
>
> Yep, marking conversation-scoped beans with the aop:scoped-proxy tag is no 
> longer needed in orchestra-1.1-SNAPSHOT. We do have some old code for doing 
> that with annotations, though: it is about 20 lines.
>
> Currently the code is in com.ops.OPSJ.spring.ScopedProxy; we could share that 
> if needed although I don't think there is much point in making it part of 
> Orchestra.
>
> Regards,
> Simon
>



-- 
Matthias Wessendorf

further stuff:
blog: http://matthiaswessendorf.wordpress.com/
sessions: http://www.slideshare.net/mwessendorf
mail: matzew-at-apache-dot-org

Reply via email to