[GLASSFISH-19482] several issues with list-jms-resources Created: 27/Dec/12  Updated: 10/Jan/13  Resolved: 10/Jan/13

Status: Resolved
Project: glassfish
Component/s: jms
Affects Version/s: 4.0_b68_EE7MS3
Fix Version/s: 4.0_b71

Type: Bug Priority: Critical
Reporter: Anissa Lam Assignee: David Zhao
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
blocks GLASSFISH-19488 UI changes related to JMS resources Resolved


I created an admin object resources and here is what it read in domain.xml

<admin-object-resource enabled="false" res-adapter="genericra" res-type="javax.jms.Queue" description="" jndi-name="ABC" class-name="com.sun.genericra.outbound.QueueProxy"></admin-object-resource>

When i run
%asadmin list-jms-resources --restype javax.jms.Queue
Command list-jms-resources executed successfully.

ABC should not be returned since it is using "genericra" as its res-adapter.

Comment by Anissa Lam [ 27/Dec/12 ]

I have changed the summary since i found more issues with list-jms-resources command.

#1. list-jms-resources doesn't filter out Admin Object Resources thats not using jmsra adapter
This is described in previous comment.

#2. list-jms-resources returns the connection-pool name if specifying "javax.jms.TopicConnectionFactory" as the restype option.

Without specifying any restype in the option:

%asadmin list-jms-resources
Command list-jms-resources executed successfully.

But if i specify restype
%asadmin list-jms-resources --restype javax.jms.TopicConnectionFactory
Command list-jms-resources executed successfully.

It should have returned the resource name, "ABC" not the connection pool name.
Here is whats in domain.xml:

<connector-connection-pool max-pool-size="250" steady-pool-size="1" name="ABC-Connection-Pool" resource-adapter-name="jmsra" connection-definition-name="javax.jms.TopicConnectionFactory"></connector-connection-pool>
<connector-resource pool-name="ABC-Connection-Pool" jndi-name="ABC"></connector-resource>

Comment by Anissa Lam [ 28/Dec/12 ]

Another issue.

#3. When --restype is specified, the 'jmsResources' is not included in the ExtraProperties thats returned in the action report.
To reproduce, run
%asadmin create-jms-resource --restype javax.jms.Queue TEST

Now, go to browser, enter
This has the jmsResources key in the Extra Properties map (refer to no-restype-option.png attached)

try specifying the restype type:
Note that the jmsResources key is missing. (refer to restype-option.png attached)

Comment by Anissa Lam [ 28/Dec/12 ]

I just realized that we cannot do attachment to the issue.
Will send the 2 screenshot to David offline.

Comment by David Zhao [ 04/Jan/13 ]


Comment by Anissa Lam [ 07/Jan/13 ]

I have to reopen the issue for the case where no JMS resources is available.
It should not return the Children with "Nothing to list" in it.

eg list-jms-resources --restype javax.jms.TopicConnectionFactory



, {messageParameters={id=

{acceptableValues=, optional=true, defaultValue=, type=string}, resType={acceptableValues=, optional=true, defaultValue=, type=string}

}}], commandLog=[list-jms-resources --resType javax.jms.TopicConnectionFactory], jmsResources=[]}, message=, exit_code=SUCCESS, command=list-jms-resources AdminCommand, children=[{message=Nothing to list, properties={}}]}, responseBody={"message":"","command":"list-jms-resources AdminCommand","exit_code":"SUCCESS","extraProperties":{"methods":[






}}],"jmsResources":[],"commandLog":["list-jms-resources --resType javax.jms.TopicConnectionFactory"]},"children":[{"message":"Nothing to list","properties":{}}]

When console parses the data returned, there is the children, with message "Nothing to list". This should be the name of a resource if it exists.
The 'children' key should not exist if there is no children.

Please look at other list resources command, and have the list-jms-resources behave the same.

Comment by David Zhao [ 10/Jan/13 ]

Don't return "Nothing to list" for list-jms-resources, list-jmsdest and list-jms-hosts.

Generated at Fri Oct 09 21:28:07 UTC 2015 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.