You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@qpid.apache.org by "JAkub Scholz (JIRA)" <ji...@apache.org> on 2012/08/20 19:27:38 UTC

[jira] [Created] (QPID-4238) Virtual hosts or queues with dots in their names do not work

JAkub Scholz created QPID-4238:
----------------------------------

             Summary: Virtual hosts or queues with dots in their names do not work
                 Key: QPID-4238
                 URL: https://issues.apache.org/jira/browse/QPID-4238
             Project: Qpid
          Issue Type: Bug
          Components: Java Broker
    Affects Versions: 0.19
            Reporter: JAkub Scholz
             Fix For: 0.19


The latest version of the Qpid Java broker seems to have a problem with the virtual hosts and queues containing a dot in their name. This is related to the way the virtualhosts.xml configuration file is designed. When a queue is defined, the <queue> tag contains only the <name> tag with the queue name and a tag named after the queue which contains additional details. E.g.

<queue>
    <name>queue.with.dot.in.the.name</name>
    <queue.with.dot.in.the.name>
        <durable>true</durable>
    </queue.with.dot.in.the.name>
</queue>

Unfortunately the dots are also used as special characters when working with the configuration file - they are used as delimiters in the XML hierarchy. In order to use them in the tag names, they need to be escaped with additional dot (i.e. queue..with..dot..in..the..name instead of queue.with.dot.in.the.name - http://commons.apache.org/configuration/userguide-1.2/howto_xml.html). This escaping doesn't seem to be currently done on the broker. As a result, the dots cannot be used in virtual host names or in queue names, which might be unfortunate for some users.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org


[jira] [Commented] (QPID-4238) Virtual hosts or queues with dots in their names do not work

Posted by "JAkub Scholz (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/QPID-4238?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13447032#comment-13447032 ] 

JAkub Scholz commented on QPID-4238:
------------------------------------

Thanks Robbie ...
                
> Virtual hosts or queues with dots in their names do not work
> ------------------------------------------------------------
>
>                 Key: QPID-4238
>                 URL: https://issues.apache.org/jira/browse/QPID-4238
>             Project: Qpid
>          Issue Type: Bug
>          Components: Java Broker
>    Affects Versions: 0.19
>            Reporter: JAkub Scholz
>            Assignee: Robbie Gemmell
>             Fix For: 0.19
>
>         Attachments: QPID-4238.patch, QPID-4238-tests.patch
>
>
> The latest version of the Qpid Java broker seems to have a problem with the virtual hosts and queues containing a dot in their name. This is related to the way the virtualhosts.xml configuration file is designed. When a queue is defined, the <queue> tag contains only the <name> tag with the queue name and a tag named after the queue which contains additional details. E.g.
> <queue>
>     <name>queue.with.dot.in.the.name</name>
>     <queue.with.dot.in.the.name>
>         <durable>true</durable>
>     </queue.with.dot.in.the.name>
> </queue>
> Unfortunately the dots are also used as special characters when working with the configuration file - they are used as delimiters in the XML hierarchy. In order to use them in the tag names, they need to be escaped with additional dot (i.e. queue..with..dot..in..the..name instead of queue.with.dot.in.the.name - http://commons.apache.org/configuration/userguide-1.2/howto_xml.html). This escaping doesn't seem to be currently done on the broker. As a result, the dots cannot be used in virtual host names or in queue names, which might be unfortunate for some users.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org


[jira] [Commented] (QPID-4238) Virtual hosts or queues with dots in their names do not work

Posted by "Keith Wall (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/QPID-4238?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13439083#comment-13439083 ] 

Keith Wall commented on QPID-4238:
----------------------------------

Hi Jakub

I see no problem with this patch.  The dot is legal in both queue names and virtual hostnames from a AMQP 0.8..0-10 perspective, so I can see no reason why you should not be able to specify these names in the config file too.  I do however think the patch would benefit from the additional of a unit test.  I would look at adding a test to ServerConfigurationTest and/or VirtualHostConfigurationTest.

Be aware that we are planning to remove the config.xml and virtualhost.xml files from the Broker at some point in the near future.  It is envisaged that all configuration will be stored in the store, and all objects (including virtualhosts) will be created/destroyed via the management interfaces.


                
> Virtual hosts or queues with dots in their names do not work
> ------------------------------------------------------------
>
>                 Key: QPID-4238
>                 URL: https://issues.apache.org/jira/browse/QPID-4238
>             Project: Qpid
>          Issue Type: Bug
>          Components: Java Broker
>    Affects Versions: 0.19
>            Reporter: JAkub Scholz
>             Fix For: 0.19
>
>         Attachments: QPID-4238.patch
>
>
> The latest version of the Qpid Java broker seems to have a problem with the virtual hosts and queues containing a dot in their name. This is related to the way the virtualhosts.xml configuration file is designed. When a queue is defined, the <queue> tag contains only the <name> tag with the queue name and a tag named after the queue which contains additional details. E.g.
> <queue>
>     <name>queue.with.dot.in.the.name</name>
>     <queue.with.dot.in.the.name>
>         <durable>true</durable>
>     </queue.with.dot.in.the.name>
> </queue>
> Unfortunately the dots are also used as special characters when working with the configuration file - they are used as delimiters in the XML hierarchy. In order to use them in the tag names, they need to be escaped with additional dot (i.e. queue..with..dot..in..the..name instead of queue.with.dot.in.the.name - http://commons.apache.org/configuration/userguide-1.2/howto_xml.html). This escaping doesn't seem to be currently done on the broker. As a result, the dots cannot be used in virtual host names or in queue names, which might be unfortunate for some users.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org


[jira] [Resolved] (QPID-4238) Virtual hosts or queues with dots in their names do not work

Posted by "Robbie Gemmell (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/QPID-4238?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Robbie Gemmell resolved QPID-4238.
----------------------------------

    Resolution: Fixed
      Assignee: Robbie Gemmell

Patches applied (sorry about the delay) after some trivial whitespace fixes.
                
> Virtual hosts or queues with dots in their names do not work
> ------------------------------------------------------------
>
>                 Key: QPID-4238
>                 URL: https://issues.apache.org/jira/browse/QPID-4238
>             Project: Qpid
>          Issue Type: Bug
>          Components: Java Broker
>    Affects Versions: 0.19
>            Reporter: JAkub Scholz
>            Assignee: Robbie Gemmell
>             Fix For: 0.19
>
>         Attachments: QPID-4238.patch, QPID-4238-tests.patch
>
>
> The latest version of the Qpid Java broker seems to have a problem with the virtual hosts and queues containing a dot in their name. This is related to the way the virtualhosts.xml configuration file is designed. When a queue is defined, the <queue> tag contains only the <name> tag with the queue name and a tag named after the queue which contains additional details. E.g.
> <queue>
>     <name>queue.with.dot.in.the.name</name>
>     <queue.with.dot.in.the.name>
>         <durable>true</durable>
>     </queue.with.dot.in.the.name>
> </queue>
> Unfortunately the dots are also used as special characters when working with the configuration file - they are used as delimiters in the XML hierarchy. In order to use them in the tag names, they need to be escaped with additional dot (i.e. queue..with..dot..in..the..name instead of queue.with.dot.in.the.name - http://commons.apache.org/configuration/userguide-1.2/howto_xml.html). This escaping doesn't seem to be currently done on the broker. As a result, the dots cannot be used in virtual host names or in queue names, which might be unfortunate for some users.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org


[jira] [Updated] (QPID-4238) Virtual hosts or queues with dots in their names do not work

Posted by "JAkub Scholz (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/QPID-4238?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

JAkub Scholz updated QPID-4238:
-------------------------------

    Attachment: QPID-4238.patch

Attached patch adds new escapeTagName method to the class ConfigurationPlugin and uses this method to escape the dots when loading the virtual hosts and the queues in ServerConfiguration and QueueConfiguration classes. Please let me know in case there should be something changed in the patch.
                
> Virtual hosts or queues with dots in their names do not work
> ------------------------------------------------------------
>
>                 Key: QPID-4238
>                 URL: https://issues.apache.org/jira/browse/QPID-4238
>             Project: Qpid
>          Issue Type: Bug
>          Components: Java Broker
>    Affects Versions: 0.19
>            Reporter: JAkub Scholz
>             Fix For: 0.19
>
>         Attachments: QPID-4238.patch
>
>
> The latest version of the Qpid Java broker seems to have a problem with the virtual hosts and queues containing a dot in their name. This is related to the way the virtualhosts.xml configuration file is designed. When a queue is defined, the <queue> tag contains only the <name> tag with the queue name and a tag named after the queue which contains additional details. E.g.
> <queue>
>     <name>queue.with.dot.in.the.name</name>
>     <queue.with.dot.in.the.name>
>         <durable>true</durable>
>     </queue.with.dot.in.the.name>
> </queue>
> Unfortunately the dots are also used as special characters when working with the configuration file - they are used as delimiters in the XML hierarchy. In order to use them in the tag names, they need to be escaped with additional dot (i.e. queue..with..dot..in..the..name instead of queue.with.dot.in.the.name - http://commons.apache.org/configuration/userguide-1.2/howto_xml.html). This escaping doesn't seem to be currently done on the broker. As a result, the dots cannot be used in virtual host names or in queue names, which might be unfortunate for some users.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org


[jira] [Commented] (QPID-4238) Virtual hosts or queues with dots in their names do not work

Posted by "JAkub Scholz (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/QPID-4238?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13439105#comment-13439105 ] 

JAkub Scholz commented on QPID-4238:
------------------------------------

Hi Robbie, Keith,

I was trying to replicate existing AMQP configuration which is using the dots in queue names (originally based on the C++ broker). Since I was not familiar with all the different configuration interfaces for the broker and needed the dots I fixed it for the XML file. I have to admit I had a look at the unit tests but they looked to me more complicated then the actual fix, so I decided to take a short cut and skip them :-o. I will try to find some time today/tomorrow to have a second look at them.

It is good to know about the planned changes in the management interfaces, I will try to avoid the XML configuration in our long term plans.

Regards
Jakub
                
> Virtual hosts or queues with dots in their names do not work
> ------------------------------------------------------------
>
>                 Key: QPID-4238
>                 URL: https://issues.apache.org/jira/browse/QPID-4238
>             Project: Qpid
>          Issue Type: Bug
>          Components: Java Broker
>    Affects Versions: 0.19
>            Reporter: JAkub Scholz
>             Fix For: 0.19
>
>         Attachments: QPID-4238.patch
>
>
> The latest version of the Qpid Java broker seems to have a problem with the virtual hosts and queues containing a dot in their name. This is related to the way the virtualhosts.xml configuration file is designed. When a queue is defined, the <queue> tag contains only the <name> tag with the queue name and a tag named after the queue which contains additional details. E.g.
> <queue>
>     <name>queue.with.dot.in.the.name</name>
>     <queue.with.dot.in.the.name>
>         <durable>true</durable>
>     </queue.with.dot.in.the.name>
> </queue>
> Unfortunately the dots are also used as special characters when working with the configuration file - they are used as delimiters in the XML hierarchy. In order to use them in the tag names, they need to be escaped with additional dot (i.e. queue..with..dot..in..the..name instead of queue.with.dot.in.the.name - http://commons.apache.org/configuration/userguide-1.2/howto_xml.html). This escaping doesn't seem to be currently done on the broker. As a result, the dots cannot be used in virtual host names or in queue names, which might be unfortunate for some users.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org


[jira] [Commented] (QPID-4238) Virtual hosts or queues with dots in their names do not work

Posted by "Robbie Gemmell (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/QPID-4238?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13439086#comment-13439086 ] 

Robbie Gemmell commented on QPID-4238:
--------------------------------------

Outstanding cross-post :)
                
> Virtual hosts or queues with dots in their names do not work
> ------------------------------------------------------------
>
>                 Key: QPID-4238
>                 URL: https://issues.apache.org/jira/browse/QPID-4238
>             Project: Qpid
>          Issue Type: Bug
>          Components: Java Broker
>    Affects Versions: 0.19
>            Reporter: JAkub Scholz
>             Fix For: 0.19
>
>         Attachments: QPID-4238.patch
>
>
> The latest version of the Qpid Java broker seems to have a problem with the virtual hosts and queues containing a dot in their name. This is related to the way the virtualhosts.xml configuration file is designed. When a queue is defined, the <queue> tag contains only the <name> tag with the queue name and a tag named after the queue which contains additional details. E.g.
> <queue>
>     <name>queue.with.dot.in.the.name</name>
>     <queue.with.dot.in.the.name>
>         <durable>true</durable>
>     </queue.with.dot.in.the.name>
> </queue>
> Unfortunately the dots are also used as special characters when working with the configuration file - they are used as delimiters in the XML hierarchy. In order to use them in the tag names, they need to be escaped with additional dot (i.e. queue..with..dot..in..the..name instead of queue.with.dot.in.the.name - http://commons.apache.org/configuration/userguide-1.2/howto_xml.html). This escaping doesn't seem to be currently done on the broker. As a result, the dots cannot be used in virtual host names or in queue names, which might be unfortunate for some users.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org


[jira] [Commented] (QPID-4238) Virtual hosts or queues with dots in their names do not work

Posted by "JAkub Scholz (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/QPID-4238?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13439375#comment-13439375 ] 

JAkub Scholz commented on QPID-4238:
------------------------------------

Hi Keith,

I prepared two tests - one for queue names and one for virtual hosts name. The way I tested it is that I add a new queue/host with a configuration (max delivery count / message store) detail contained in the tag with queue/host name. Then I check that the property was correctly loaded. It may not be the best approach, but it definitely fails without my patch and succeeds with the patch.

Regards
Jakub
                
> Virtual hosts or queues with dots in their names do not work
> ------------------------------------------------------------
>
>                 Key: QPID-4238
>                 URL: https://issues.apache.org/jira/browse/QPID-4238
>             Project: Qpid
>          Issue Type: Bug
>          Components: Java Broker
>    Affects Versions: 0.19
>            Reporter: JAkub Scholz
>             Fix For: 0.19
>
>         Attachments: QPID-4238.patch
>
>
> The latest version of the Qpid Java broker seems to have a problem with the virtual hosts and queues containing a dot in their name. This is related to the way the virtualhosts.xml configuration file is designed. When a queue is defined, the <queue> tag contains only the <name> tag with the queue name and a tag named after the queue which contains additional details. E.g.
> <queue>
>     <name>queue.with.dot.in.the.name</name>
>     <queue.with.dot.in.the.name>
>         <durable>true</durable>
>     </queue.with.dot.in.the.name>
> </queue>
> Unfortunately the dots are also used as special characters when working with the configuration file - they are used as delimiters in the XML hierarchy. In order to use them in the tag names, they need to be escaped with additional dot (i.e. queue..with..dot..in..the..name instead of queue.with.dot.in.the.name - http://commons.apache.org/configuration/userguide-1.2/howto_xml.html). This escaping doesn't seem to be currently done on the broker. As a result, the dots cannot be used in virtual host names or in queue names, which might be unfortunate for some users.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org


[jira] [Updated] (QPID-4238) Virtual hosts or queues with dots in their names do not work

Posted by "JAkub Scholz (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/QPID-4238?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

JAkub Scholz updated QPID-4238:
-------------------------------

    Attachment: QPID-4238-tests.patch
    
> Virtual hosts or queues with dots in their names do not work
> ------------------------------------------------------------
>
>                 Key: QPID-4238
>                 URL: https://issues.apache.org/jira/browse/QPID-4238
>             Project: Qpid
>          Issue Type: Bug
>          Components: Java Broker
>    Affects Versions: 0.19
>            Reporter: JAkub Scholz
>             Fix For: 0.19
>
>         Attachments: QPID-4238.patch, QPID-4238-tests.patch
>
>
> The latest version of the Qpid Java broker seems to have a problem with the virtual hosts and queues containing a dot in their name. This is related to the way the virtualhosts.xml configuration file is designed. When a queue is defined, the <queue> tag contains only the <name> tag with the queue name and a tag named after the queue which contains additional details. E.g.
> <queue>
>     <name>queue.with.dot.in.the.name</name>
>     <queue.with.dot.in.the.name>
>         <durable>true</durable>
>     </queue.with.dot.in.the.name>
> </queue>
> Unfortunately the dots are also used as special characters when working with the configuration file - they are used as delimiters in the XML hierarchy. In order to use them in the tag names, they need to be escaped with additional dot (i.e. queue..with..dot..in..the..name instead of queue.with.dot.in.the.name - http://commons.apache.org/configuration/userguide-1.2/howto_xml.html). This escaping doesn't seem to be currently done on the broker. As a result, the dots cannot be used in virtual host names or in queue names, which might be unfortunate for some users.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org


[jira] [Commented] (QPID-4238) Virtual hosts or queues with dots in their names do not work

Posted by "Robbie Gemmell (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/QPID-4238?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13439081#comment-13439081 ] 

Robbie Gemmell commented on QPID-4238:
--------------------------------------

Hi Jakub,

I must admit to us having known about this defect for a while. It is as you have noticed related to the Commons Configuration usage, and as such is linked to the xml config files rather than an inherant limitation of the broker. Although I can't admit to having tried it (our users dont tend to use dots so it has never become a priority) the JMX/HTTP interfaces shouldnt present any such restriction (but obviously cant currently create virtualhosts...though it is coming).

We will take a look at the patch later in the week probably (a bit swamped at the moment, hence the 11pm reply) and apply it if all seems well. It's probably worth me mentioning that we are currently undertaking a long term project to rework the broker management and configuration, including removal of the XML configuration hopefully for 0.20, so this was getting resolved one way or the other, but thank you for the patch in the meantime :)
                
> Virtual hosts or queues with dots in their names do not work
> ------------------------------------------------------------
>
>                 Key: QPID-4238
>                 URL: https://issues.apache.org/jira/browse/QPID-4238
>             Project: Qpid
>          Issue Type: Bug
>          Components: Java Broker
>    Affects Versions: 0.19
>            Reporter: JAkub Scholz
>             Fix For: 0.19
>
>         Attachments: QPID-4238.patch
>
>
> The latest version of the Qpid Java broker seems to have a problem with the virtual hosts and queues containing a dot in their name. This is related to the way the virtualhosts.xml configuration file is designed. When a queue is defined, the <queue> tag contains only the <name> tag with the queue name and a tag named after the queue which contains additional details. E.g.
> <queue>
>     <name>queue.with.dot.in.the.name</name>
>     <queue.with.dot.in.the.name>
>         <durable>true</durable>
>     </queue.with.dot.in.the.name>
> </queue>
> Unfortunately the dots are also used as special characters when working with the configuration file - they are used as delimiters in the XML hierarchy. In order to use them in the tag names, they need to be escaped with additional dot (i.e. queue..with..dot..in..the..name instead of queue.with.dot.in.the.name - http://commons.apache.org/configuration/userguide-1.2/howto_xml.html). This escaping doesn't seem to be currently done on the broker. As a result, the dots cannot be used in virtual host names or in queue names, which might be unfortunate for some users.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@qpid.apache.org
For additional commands, e-mail: dev-help@qpid.apache.org