Details
-
Bug
-
Resolution: Done
-
Major
-
7.1.1.Final
-
None
Description
User reported that he could not set the <factory-type> when creating a connection factory:
<connection-factory name="RemoteConnectionFactory"> <factory-type>XA_GENERIC</factory-type> <connectors> <connector-ref connector-name="netty"/> </connectors> <entries> <entry name="RemoteConnectionFactory"/> <entry name="java:jboss/exported/jms/RemoteConnectionFactory"/> </entries> <ha>true</ha> </connection-factory>
I am not sure to understand what is supposed to do this factory-type attribute...
It is not correctly described in the connection-factory description in the CLI:
[standalone@localhost:9999 /] /subsystem=messaging/hornetq-server=default/connection-factory=RemoteConnectionFactory/:read-resource-description ... "factory-type" => { "description" => "The type of connection factory. 0 = jms cf, 1 = queue cf, 2 = topic cf, 3 = xa cf, 4 = xa queue cf, 5 = xa topic cf", "type" => INT, "nillable" => false, "allowed" => [ undefined, undefined, undefined, undefined, undefined, undefined ], "access-type" => "read-only", "storage" => "runtime" }, ...
The allowed values are not properly defined (code in MessagingDescriptions.getConnectionFactory(Locale) is bogus, I'll fix it...)
I don't understand why it is defined as read only but in ConnectionFactoryAdd we try to set the factoryType based on the resolved CONNECTION_FACTORY_TYPE attribute. This attribute is not defined among the connection factory attributes and can not be set when creating a cf with the CLI.
I don't understand why the "factory-type" model node is defined twice (in CommonAttributes and in MessagingDescriptions.getConnectionFactory(Locale)). To me, these 2 attributes are the same.
I'll fix it with the expectation that it is valid for an user to set the type of connection factory (with or w/o XA, queue/topic/generic) when he adds one through configuration or the CLI. Does that sound correct?
Attachments
Issue Links
- is duplicated by
-
AS7-4418 Atrribute <factory-type> is not parsed correctly in configuration of connection-factory
- Closed