users@javaee-spec.java.net

[javaee-spec users] [jsr342-experts] Re: Definitive list of pre-defined types valid for resource-env-ref?

From: Kevin Sutter <sutter_at_us.ibm.com>
Date: Thu, 24 Apr 2014 20:30:07 -0500

Hi Linda,
Thanks. I was just looking for an explicit list of types that are
supported. The Platform spec implies some of these types, and some of
them are explicitly stated as supported by the resource-env-ref (like
Validator and ValidatorFactory). But, I haven't found anything in the
Platform spec relating to the ContextService, for example. So, if we can
get this list documented either in the Common Annotations or the Platform
spec, that would be great. We're just looking for a definitive list to
help with the tooling development, without having to interrogate every
individual spec.

Thanks,
Kevin
 



From: Linda DeMichiel <linda.demichiel_at_oracle.com>
To: jsr342-experts_at_javaee-spec.java.net,
Date: 04/24/2014 01:36 PM
Subject: [jsr342-experts] Re: Definitive list of pre-defined types
valid for resource-env-ref?



Hi Kevin,

On 4/14/14 9:03 AM, Kevin Sutter wrote:
Is there a definitive list of valid pre-defined types for the
resource-env-ref? It looks like Table 2-4 in Common Annotations (JSR 250)
started such a list, but then it left it pretty open-ended at the end:
javax.resource.cci.InteractionSpec
resource-env-ref
javax.transaction.UserTransaction
resource-env-ref
Everything else
resource-env-ref


I realize we need to be flexible with this due to some managed objects
having arbitrary types. But, I'm wondering if we have a spec-defined list
of the pre-defined types that are valid for resource-env-ref? And, if
not, does it make sense to expand on this Table 2-4? Or, maybe document
it somewhere else? Thanks.

The Platform spec explicitly states that in addition to the two types
listed in the table that you cite, the following may also be specified
by means of resource-env-ref: Validator, ValidatorFactory,
ManagedExecutorService, ManagedScheduledExecutorService,
ManagedThreadFactory, ContextService, BeanManager.
A resource-env-ref may also be used to specify a JMS Destination,
although message-destination-ref is preferred for this purpose.

The Common Annotations spec section 2.3 and table 2.4 still refer to
the state as of Java EE 5, so we should update it to reflect these
additions when we next do an MR.

regards,

-Linda




----------------------------------------------------------------------------------------------------------------------------------------------------------------
Kevin Sutter
STSM, Java EE and Java Persistence API (JPA) architect
mail: sutter_at_us.ibm.com, Kevin Sutter/Rochester/IBM
http://webspherepersistence.blogspot.com/
phone: tl-553-3620 (office), 507-253-3620 (office)
http://openjpa.apache.org/