On Aug 17, 2009, at 11:13 PM, Gurkan Erdogdu wrote:
Hi David,
Firstly, thanks for answering.
As you specified we currently boot OpenWebBeans as a servlet context
listener to get all OWB classes and to create OWB specific beans.
For each
class, we ask OpenEJB whether it is an EJB related class or not. If
it is
not an EJB class, we define OWB "*Managed Bean*" instance, if it is we
create "*EJB Bean*" instance.
Nice.
OWB beans are used for creating actual object instances whenever
they are
injected into some other beans. OWB container finds which bean it
injects
using type safe algorithm. (In below example, it tries to find OWB
Managed
Bean with "*API Type*" PaymentProcessor and "*Binding Type*" is
@Payment)
For Example;
class Person{
@Payment PaymentProcessor processor;
}
I was really asking how you implemented the scanning. I.e. the code
details rather than the spec details.
A link the scanning code will work too.
We could probably boot you a lot sooner so you can participate more
closely in deployment.
Tomcat calls our context listener after deployment, so we are able
to use
EJB integration. So there is no problem for deployment ordering
We do need to scan those classes at deploy time to ensure all the
resources they need are created, added to JNDI, etc. by the time the
app starts. So we will need to find a way to boot you a bit sooner.
Do you have a link to the listener?
-David