Bug 1054214

Summary: System property variables in CLI scripts are replaced in server configuration XML
Product: [JBoss] JBoss Enterprise Application Platform 6 Reporter: sgilda
Component: CLIAssignee: James Perkins <jperkins>
Status: CLOSED DUPLICATE QA Contact: Petr Kremensky <pkremens>
Severity: unspecified Docs Contact: Russell Dickenson <rdickens>
Priority: unspecified    
Version: 6.2.0CC: brian.stansberry, olubyans
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-03-05 17:35:53 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description sgilda 2014-01-16 13:22:39 UTC
Description of problem:

This problem was discovered when testing updates to the instructions for the 'jts' quickstart. To reproduce the problem:

1. Open a terminal and navigate to the root of the JBoss EAP install directory.

2. Start the server with this command:

    $ bin/standalone.sh -c standalone-full.xml -Djboss.tx.node.id=node1

3. Open a new terminal, navigate to the root of the JBoss EAP install directory, and connect to the jboss-cli:

    $ bin/jboss-cli.sh --connect

4. Run the following commands:

    /subsystem=jacorb/:write-attribute(name=transactions,value=on)
    /subsystem=jacorb:write-attribute(name=name,value=${jboss.node.name})
    /subsystem=jacorb:write-attribute(name=root-context,value=${jboss.node.name}/Naming/root)

    /subsystem=transactions/:write-attribute(name=jts,value=true)
    /subsystem=transactions/:write-attribute(name=node-identifier,value=${jboss.tx.node.id})

The commands run successfully. Stop the server and open the standalone-full.xml configuration file. You see the following in the transactions subsystem:

    <core-environment node-identifier="$">

The server was started with the argument '-Djboss.tx.node.id=node1' so the resulting configuration should be:

    <core-environment node-identifier="node1">
 
Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 sgilda 2014-01-16 13:36:08 UTC
Tom Jenkinson did some more testing.

In WildFly he said it works. His standalone.xml ended up with:

        <core-environment node-identifier="${jboss.tx.node.id}">

He tried it in EAP 6.3 (CR2) and it came out with:

      <core-environment node-identifier="$">

Comment 2 sgilda 2014-01-16 13:37:03 UTC
James, since you are looking at this, I reassigned it to you. Feel free reassign as needed.

Comment 3 sgilda 2014-01-16 13:44:37 UTC
Correction. The server was started with the argument '-Djboss.tx.node.id=node1' so the resulting configuration should be:

       <core-environment node-identifier="${jboss.tx.node.id}">

Comment 4 Alexey Loubyansky 2014-01-16 14:53:37 UTC
Yes, there was a bug in the CLI parsing system properties and leaving '$'. It's fixed.

Comment 5 sgilda 2014-01-16 16:55:55 UTC
Alexey, can you provide more information about when it was fixed and when it will be in the product? Is there another bug for this?

Comment 6 Alexey Loubyansky 2014-01-16 17:18:27 UTC
I think it was fixed as https://issues.jboss.org/browse/WFLY-2051 and the corresponding https://bugzilla.redhat.com/show_bug.cgi?id=988283

Comment 7 sgilda 2014-01-16 18:34:57 UTC
Thanks. So this sounds like a duplicate of Bug 988283.

Comment 8 James Perkins 2014-03-05 17:35:53 UTC

*** This bug has been marked as a duplicate of bug 988283 ***