+++ This bug was initially created as a clone of Bug #1020510 +++ Description of problem: Method "handle" from class "CommandContext" does not parse special characters like "ô" properly. This is related to https://bugzilla.redhat.com/show_bug.cgi?id=1017264. Version-Release number of selected component (if applicable): Was testing on jboss-as-dist-7.3.0.Final-redhat-6.zip But I think also applicable to jboss-as-dist-7.2.0.Final-redhat-8.zip How reproducible: Always Steps to Reproduce: 1. Start up standalone server ./standalone.sh 2. Initialize CommandContext through CommandContextFactory 3. Connect CommandContext through controller via method connectController() 4. Run your command via handle method Ex. String line = "data-source add --name=jbpmDS --jndi-name=java:jboss/datasources/jbpmDS --driver-name=h2 --user-name=soa --password=\"soa\" --connection-url=\"jdbc:h2:file:${jboss.server.data.dir}/ô/h2/soa;mvcc=true\""; context.handle(line); Actual results: Request contains jdbc:h2:file:${jboss.server.data.dir}/?/h2/soa;mvcc=true Expected results: Request to contain jdbc:h2:file:${jboss.server.data.dir}/ô/h2/soa;mvcc=true Additional info: Seems like in file: GenericTypeOperationHandler.java Within method: ModelNode buildRequest(CommandContext ctx) Around line below: ModelNode nodeValue = arg.getValueConverter().fromString(ctx, valueString); Transforms valueString of valueString = jdbc:h2:file:${jboss.server.data.dir}/ô/h2/soa;mvcc=true into nodeValue = "jdbc:h2:file:${jboss.server.data.dir}/?/h2/soa;mvcc=true" This causes .xml file to contain "?" rather than the special character "ô" This is related to https://bugzilla.redhat.com/show_bug.cgi?id=1019782 --- Additional comment from Alexey Loubyansky on 2013-11-08 06:11:46 EST --- AFAICS, it's in the jboss-dmr ModelNode.fromString(str) parser. If you try data-source add --name=jbpmDS --jndi-name=java:jboss/datasources/jbpmDS --driver-name=h2 --user-name=soa --password=\"soa\" --connection-url=jdbc:h2:file:${jboss.server.data.dir}/ô/h2/soa;mvcc=true i.e. w/o quotes then it'll be parsed by the CLI parser and it'll work. Every value is first parsed with the DMR parser if that fails then the CLI is trying its own parser. Usually, a (simple) quoted string will be parsed by the DMR parser successfully and the result will used for the operation request. --- Additional comment from Alexey Loubyansky on 2013-11-19 11:02:49 EST --- And this was fixed as https://issues.jboss.org/browse/DMR-8. --- Additional comment from Alexey Loubyansky on 2013-11-19 11:26:59 EST --- (In reply to Alexey Loubyansky from comment #2) > And this was fixed as https://issues.jboss.org/browse/DMR-8. Actually, that issue is a bit different and targets more JSON strings. To make sure this issue is covered I created https://issues.jboss.org/browse/DMR-10 --- Additional comment from Miles Tjandrawidjaja on 2013-11-26 12:17:46 EST --- I have tried without quotes for the --connection url. Result: <connection-url>true</connection-url> Expected: <connection-url>jdbc:h2:file:${jboss.server.data.dir}/ô/h2/soa;mvcc=true</connection-url> With Quotes ================ String line = "data-source add --name=jbpmDS --jndi-name=java:jboss/datasources/jbpmDS --driver-name=h2 --user-name=soa --password=\"soa\" --connection-url=\"jdbc:h2:file:${jboss.server.data.dir}/ô/h2/soa;mvcc=true\""; ================ <datasource jndi-name="java:jboss/datasources/jbpmDS" pool-name="jbpmDS" enabled="false"> <connection-url>jdbc:h2:file:${jboss.server.data.dir}/?/h2/soa;mvcc=true</connection-url> <driver>h2</driver> <security> <user-name>soa</user-name> <password>soa</password> </security> </datasource> Without Quotes ================ String line = "data-source add --name=jbpmDS --jndi-name=java:jboss/datasources/jbpmDS --driver-name=h2 --user-name=soa --password=\"soa\" --connection-url=jdbc:h2:file:${jboss.server.data.dir}/ô/h2/soa;mvcc=true"; ================ <datasource jndi-name="java:jboss/datasources/jbpmDS" pool-name="jbpmDS" enabled="false"> <connection-url>true</connection-url> <driver>h2</driver> <security> <user-name>soa</user-name> <password>soa</password> </security> </datasource>