users@glassfish.java.net

How can validate something about the message ADMVAL1071 ?

From: <glassfish_at_javadesktop.org>
Date: Thu, 11 Dec 2008 17:40:13 PST

Hello,everyone!
I've happened a problem!
In GlassFIsh v2 , the jdbc-connection-pool has two attributes.
And let's look at the two attributes :

--lazyconnectionenlistment
Specifies whether a resource to a transaction is enlisted only when a method actually uses the resource. Possible values are as follows:

false
Resources to a transaction are always enlisted and not only when a method actually uses the resource (default).

true
Resources to a transaction are enlisted only when a method actually uses the resource.

--lazyconnectionassociation
Specifies whether a physical connection should be associated with the logical connection only when the physical connection is used, and disassociated when the transaction is completed. Such association and dissociation enable the reuse of physical connections. Possible values are as follows:

false
A physical connection is associated with the logical connection even before the physical connection is used, and is not disassociated when the transaction is completed (default).

true
A physical connection is associated with the logical connection only when the physical connection is used, and disassociated when the transaction is completed. The --lazyconnectionenlistment option must also be set to true.

---------------------------------
But, when the lazyconnectionassociation is set to true, the lazyconnectionenlistment option must also be set to true.

------
>assadmin set resources.jdbc-connection-pool.SymfowarePool.lazy-connection-enlistment=true resources.jdbc-connection-pool.SymfowarePool.lazy-connection-association=true
-----
And the set command can set two attributes at the same time.
So, how should I code the validation source?
Here's the location of the source :
glassfish\admin\validator\src\java\com\sun\enterprise\config\serverbeans\validation\tests\JdbcConnectionPoolTest.java

PS:The old source only validated the property(LazyConectionAssociation and LazyConnectionEnlistment ),but in GlassFish,the two properties had been changed to attributes.So, how should I add the the validation source about the two attributes?
[Message sent by forum member 'wssmao' (wssmao)]

http://forums.java.net/jive/thread.jspa?messageID=321342