On Jun 28, 2008, at 2:10 PM, David Blevins wrote:
When we add that functionality we'll want to make an option on the
container to control how long a calling thread should wait till
timeout occurs and a ConcurrentAccessTimeoutException is thrown.
Any thoughts on what the default timeout should be? Couple seconds,
couple minutes, infinite?
Maybe make it the same as transaction timeout.
The spec group hasn't determined what the related xml is for
declaring bean vs container concurrency management, so we'll have to
make something up. Same goes for how to specify the "concurrency
attribute" of a bean's methods. Any ideas on what the xml should
look like?
I'd try to keep it similar to what is used in XML for persistence-type
and transaction-type.
<concurrent>Bean</concurrency>
<concurrent>Container</concurrency>
As for the method level xml... I've never been a fan of the assembly
descriptor section because it separates important meta-data from the
bean declaration, but what's done is done. I'd add a container-
concurrency section to the assembly-descriptor like this:
<container-concurrency>
<method>
<ejb-name>SomeEJB</ejb-name>
<method-name>*</method-name>
</method>
<concurrency-attribute>ReadOnly</concurrency-attribute>
</container-concurrency>
-----------------------------------
STARTUP
-----------------------------------
- @Startup
Right now, the instances are created lazily when you first look them
up. Startup could be easily supported by just instantiating the
bean when the Container's deploy(DeploymentInfo) method is called.
We could add an option on the container so people can control which
they'd like to do by default. Any thoughts on what the default
default should be? I.e. first access (lazy) or at startup?
Do we want to do this at all? FWIU, @Startup only applies to
@Singleton beans, which means that all beans will be "new" code, so if
a user wants all their beans to be @Startup, they simply add the
annotation.
On the other hand, if you look at the Spring docs (http://static.springframework.org/spring/docs/2.5.x/reference/beans.html#beans-factory-lazy-init
), all Singleton beans are started eagerly on startup.
Regardless of the default, we may want to go with names that are
spring friendly like "lazy-init".
Again the spec group hasn't determined the ejb-jar.xml xml for
specifying if the singleton bean should be loaded on startup. Any
ideas?
In the singleton declaration:
<lazy-init>true</lazy-init>
-----------------------------------
ORDERING
-----------------------------------
- @DependsOn(String[])
Right now, we just load the beans in the order they are declared in
the ejb-jar.xml or discovered in the jar. The @DependsOn allows you
to list the ejbs that should be loaded before the bean in question.
You can list beans by ejb-name.
There are no real configurable options for this functionality that I
see.
Again the spec group hasn't determined the ejb-jar.xml xml for
specifying if the "@DependsOn" data in the deployment descriptor.
Any ideas?
In the singleton declaration:
<depends-on>MyBean</depends-on>
<depends-on>MyOtherBean</depends-on>
Note: no wrapper element.
-dain