You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@activemq.apache.org by "Jim Beattie (JIRA)" <ji...@apache.org> on 2006/06/19 22:47:51 UTC
[jira] Created: (AMQ-761) ActiveMQConnectionFactory.setBrokerURL
does not set all connection properties corrrectly
ActiveMQConnectionFactory.setBrokerURL does not set all connection properties corrrectly
----------------------------------------------------------------------------------------
Key: AMQ-761
URL: https://issues.apache.org/activemq/browse/AMQ-761
Project: ActiveMQ
Type: Bug
Components: JMS client
Versions: 3.2.2
Environment: Windows XP, Java 1.4.1
Reporter: Jim Beattie
Attachments: UrlSetterTest.java
If I set the brokerUrl of ActiveMQConnectionFactory using setBrokerURL(), the connection factory does not reparse all of the properties from the URL. As a result, when a new connection is created, some of the properties from the URL specified during the construction of the connection factory (typically the defaults) are used instead. Attached is a unit test to demonstrate the problem.
As a minimum, the following block of code is required in setBrokerURL(). But this doesn't really fix it because properties settings from the URL used by the constructor may not be reset by this code. A structural change may be in order (e.g. just-in-time parsing of the properties).
if( brokerURL.indexOf("?")>= 0 ) {
String options = brokerURL.substring(brokerURL.indexOf("?")+1);
Map properties = URIHelper.parseQuery(options);
if (!properties.isEmpty()) {
BeanUtils.populate(this, properties);
}
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Resolved: (AMQ-761) ActiveMQConnectionFactory.setBrokerURL
does not set all connection properties corrrectly
Posted by "james strachan (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/activemq/browse/AMQ-761?page=all ]
james strachan resolved AMQ-761.
--------------------------------
Fix Version/s: 4.1.0
Resolution: Fixed
> ActiveMQConnectionFactory.setBrokerURL does not set all connection properties corrrectly
> ----------------------------------------------------------------------------------------
>
> Key: AMQ-761
> URL: https://issues.apache.org/activemq/browse/AMQ-761
> Project: ActiveMQ
> Issue Type: Bug
> Components: JMS client
> Affects Versions: 3.2.2
> Environment: Windows XP, Java 1.4.1
> Reporter: Jim Beattie
> Fix For: 4.1.0
>
> Attachments: UrlSetterTest.java
>
>
> If I set the brokerUrl of ActiveMQConnectionFactory using setBrokerURL(), the connection factory does not reparse all of the properties from the URL. As a result, when a new connection is created, some of the properties from the URL specified during the construction of the connection factory (typically the defaults) are used instead. Attached is a unit test to demonstrate the problem.
> As a minimum, the following block of code is required in setBrokerURL(). But this doesn't really fix it because properties settings from the URL used by the constructor may not be reset by this code. A structural change may be in order (e.g. just-in-time parsing of the properties).
> if( brokerURL.indexOf("?")>= 0 ) {
> String options = brokerURL.substring(brokerURL.indexOf("?")+1);
> Map properties = URIHelper.parseQuery(options);
> if (!properties.isEmpty()) {
> BeanUtils.populate(this, properties);
> }
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/activemq/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira