Uploaded image for project: 'WildFly'
  1. WildFly
  2. WFLY-2612

The CLI should support property substitution for names of elements and not only for parameters

    • Icon: Feature Request Feature Request
    • Resolution: Duplicate
    • Icon: Minor Minor
    • None
    • 8.0.0.Beta1
    • CLI
    • None

      My customer is using client side substitution in the CLI
      jboss-cli.xml:
      <resolve-parameter-values>true</resolve-parameter-values>

      This works fine for example with:

      /subsystem=datasources/data-source=oracleDS:add(connection-url=jdbc:oracle:thin:@server:1521:ora1, jndi-name=java:/jboss/${name}, driver-name=oracle)

      The "name" is provided in a property file at the command line for jboss-cli.sh

      This request is to extend this behaviour to allow for example:

      /subsystem=datasources/data-source=${datasourcename}:add(connection-url=jdbc:oracle:thin:@server:1521:ora1, jndi-name=java:/jboss/${name}, driver-name=oracle)

      In other words, have the actual element name be substituted as well based on a property value

      We know the easy workaround is to use bash embedded cli script, so the ${datasourcename} can be provided by a bash variable but it would be nice if the CLI could do that.

              olubyans@redhat.com Alexey Loubyansky
              tfonteyn Tom Fonteyne (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: