[jboss-jira] [JBoss JIRA] (WFLY-5048) CLI escapes anpersand in double-quoted strings
Alexey Loubyansky (JIRA)
issues at jboss.org
Mon Aug 3 07:56:03 EDT 2015
[ https://issues.jboss.org/browse/WFLY-5048?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13094975#comment-13094975 ]
Alexey Loubyansky commented on WFLY-5048:
-----------------------------------------
It's not the CLI who's doing that. It can also be easily reproduced with system properties, e.g.
{code}
[standalone at localhost:9990 /] /system-property=a:add(value="BURL:direct://AnotherExchange//AnotherQueue?routingkey='AnotherQueue'&durable='true'&autodelete='false'&exchangedurable='true'&exchangeautodelete='false'")
{"outcome" => "success"}
[standalone at localhost:9990 /] /system-property=a:read-attribute(name=value)
{
"outcome" => "success",
"result" => "BURL:direct://AnotherExchange//AnotherQueue?routingkey='AnotherQueue'&durable='true'&autodelete='false'&exchangedurable='true'&exchangeautodelete='false'"
}
[standalone at localhost:9990 /]
{code}
The XML will contain the value you reported but if you read it using the management API or the tools (even if you restart the server), you'll see the value as it was entered. Can you confirm this is true in your case? Why is this a problem for you?
Thanks.
> CLI escapes anpersand in double-quoted strings
> ----------------------------------------------
>
> Key: WFLY-5048
> URL: https://issues.jboss.org/browse/WFLY-5048
> Project: WildFly
> Issue Type: Bug
> Components: CLI
> Affects Versions: 8.2.0.Final
> Environment: Windows 8.1 x64, WildFly 8.2.0.Final, JDK 1.8.0.45.
> Reporter: Roman Syroeshko
> Assignee: Alexey Loubyansky
> Priority: Blocker
> Labels: BURL, CLI, Qpid, escaping
>
> I use Qpid JCA to work with AMQP message broker via JMS API. Qpid JCA is configured through Jboss CLI. Queues in Qpid are addressed using [Binding URL|https://qpid.apache.org/releases/qpid-0.32/jms-client-0-8/book/JMS-Client-0-8-Binding-URL.html]. The format uses ampersands to separate additional options.
> For example,
> BURL:direct://AnotherExchange//AnotherQueue?routingkey='AnotherQueue'&durable='true'&autodelete='false'&exchangedurable='true'&exchangeautodelete='false'
> But when I run cli-command like that:
> {code}
> ./admin-objects=AnotherQueue:add(class-name=org.apache.qpid.ra.admin.QpidQueueImpl,jndi-name=java:/comp/env/jms/AnotherQueue)
> ./admin-objects=AnotherQueue/config-properties=DestinationAddress:add(value="BURL:direct://AnotherExchange//AnotherQueue?routingkey='AnotherQueue'&durable='true'&autodelete='false'&exchangedurable='true'&exchangeautodelete='false'")
> {code}
> I get
> {code:xml}
> <admin-object class-name="org.apache.qpid.ra.admin.QpidQueueImpl" jndi-name="java:/comp/env/jms/AnotherQueue" pool-name="AnotherQueue">
> <config-property name="DestinationAddress">
> BURL:direct://AnotherExchange//AnotherQueue?routingkey='AnotherQueue'&durable='true'&autodelete='false'&exchangedurable='true'&exchangeautodelete='false'
> </config-property>
> </admin-object>
> {code}
> instead of
> {code:xml}
> <admin-object class-name="org.apache.qpid.ra.admin.QpidQueueImpl" jndi-name="java:/comp/env/jms/AnotherQueue" pool-name="AnotherQueue">
> <config-property name="DestinationAddress">
> BURL:direct://AnotherExchange//AnotherQueue?routingkey='AnotherQueue'&durable='true'&autodelete='false'&exchangedurable='true'&exchangeautodelete='false'
> </config-property>
> </admin-object>
> {code}
> It seemed to me that CLI shouldn't escape double-quoted values. Am I missing something?
> Thanks.
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)
More information about the jboss-jira
mailing list