"alesj" wrote : "adrian(a)jboss.org" wrote :
| | Stages (1) and (2) are optional if they already exist
| |
| | 1) Create a MutableMetaData for this scope
| | 2) Create a kernel (or maybe just a kernel controller) for this scope and add it
to
| | the MutableMetaData, the kernel's parent would come from any kernel in the
| | parent's scope or the default kernel if there is no such thing
| | 3) Deploy the bean(s) into that scoped kernel
| |
|
| Where to plug-in these stages?
| Since I need to know bean annotations before I deploy bean into the controller
(BeanMetaDataDeployer, AbstractKernelDeployer), but currently they are realized in
DescribeAction.
| Or should I do my own scope-annotation lookup just before I do the deployment into
controller?
I think that what we should really do is have a notion of ScopeKey in the
BeanMetaData[Factory] and the ControllerContext.
I've avoided adding it so far until we've sorted out the usecases for the
metadata, but it is definitely something that should be there.
If it is not specified, you would just use the deault rules from the
annotations or failing that ScopeKey.DEFAULT_SCOPE
I think we really need to discuss the use cases for how the metadata works.
I don't have a problem with you prototyping something so we have
something to "play with'. But the only way we are really going to workout
what the api should look like is by going through examples on
how we expect this feature to be used.
I'll start a seperate thread on one example I was thinking about over the weekend.
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4015003#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...