Uploaded image for project: 'Struts 2'
  1. Struts 2
  2. WW-4698

Allow <constant/> value substitution in XML configuration

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.5.5
    • Fix Version/s: 2.5.8
    • Component/s: XML Configuration
    • Labels:
      None

      Description

      It'd super useful if it'll be possible to substitute ENV variables in struts.xml

      <constant name="struts.devMode" value="${ENV.STRUTS_DEV_MODE:false}"/>
      

        Activity

        Hide
        hudson Hudson added a comment -

        SUCCESS: Integrated in Jenkins build Struts-JDK7-master #566 (See https://builds.apache.org/job/Struts-JDK7-master/566/)
        WW-4698 Fixes test (lukaszlenart: rev 03766980d13851558d06d8bcc8520ce6f8c4d9ce)

        • (edit) core/src/test/java/com/opensymphony/xwork2/config/providers/EnvsValueSubstitutorTest.java
          WW-4698 Uses lowercase prefix (lukaszlenart: rev a1b89842c014b771702cb1e0765f8887aeca82e5)
        • (edit) core/src/test/resources/com/opensymphony/xwork2/config/providers/xwork-test-envs-substitution.xml
        Show
        hudson Hudson added a comment - SUCCESS: Integrated in Jenkins build Struts-JDK7-master #566 (See https://builds.apache.org/job/Struts-JDK7-master/566/ ) WW-4698 Fixes test (lukaszlenart: rev 03766980d13851558d06d8bcc8520ce6f8c4d9ce) (edit) core/src/test/java/com/opensymphony/xwork2/config/providers/EnvsValueSubstitutorTest.java WW-4698 Uses lowercase prefix (lukaszlenart: rev a1b89842c014b771702cb1e0765f8887aeca82e5) (edit) core/src/test/resources/com/opensymphony/xwork2/config/providers/xwork-test-envs-substitution.xml
        Hide
        jira-bot ASF subversion and git services added a comment -

        Commit a1b89842c014b771702cb1e0765f8887aeca82e5 in struts's branch refs/heads/master from Lukasz Lenart
        [ https://git-wip-us.apache.org/repos/asf?p=struts.git;h=a1b8984 ]

        WW-4698 Uses lowercase prefix

        Show
        jira-bot ASF subversion and git services added a comment - Commit a1b89842c014b771702cb1e0765f8887aeca82e5 in struts's branch refs/heads/master from Lukasz Lenart [ https://git-wip-us.apache.org/repos/asf?p=struts.git;h=a1b8984 ] WW-4698 Uses lowercase prefix
        Hide
        jira-bot ASF subversion and git services added a comment -

        Commit 03766980d13851558d06d8bcc8520ce6f8c4d9ce in struts's branch refs/heads/master from Lukasz Lenart
        [ https://git-wip-us.apache.org/repos/asf?p=struts.git;h=0376698 ]

        WW-4698 Fixes test

        Show
        jira-bot ASF subversion and git services added a comment - Commit 03766980d13851558d06d8bcc8520ce6f8c4d9ce in struts's branch refs/heads/master from Lukasz Lenart [ https://git-wip-us.apache.org/repos/asf?p=struts.git;h=0376698 ] WW-4698 Fixes test
        Hide
        hudson Hudson added a comment -

        UNSTABLE: Integrated in Jenkins build Struts-JDK7-master #565 (See https://builds.apache.org/job/Struts-JDK7-master/565/)
        WW-4698 Fixes issue with injecting substitutor (lukaszlenart: rev 1bf7de8d3799386ad777080e9bf414c0ba3c5d56)

        • (edit) core/src/main/java/com/opensymphony/xwork2/config/impl/DefaultConfiguration.java
        • (edit) core/src/main/java/com/opensymphony/xwork2/config/providers/EnvsValueSubstitutor.java
        Show
        hudson Hudson added a comment - UNSTABLE: Integrated in Jenkins build Struts-JDK7-master #565 (See https://builds.apache.org/job/Struts-JDK7-master/565/ ) WW-4698 Fixes issue with injecting substitutor (lukaszlenart: rev 1bf7de8d3799386ad777080e9bf414c0ba3c5d56) (edit) core/src/main/java/com/opensymphony/xwork2/config/impl/DefaultConfiguration.java (edit) core/src/main/java/com/opensymphony/xwork2/config/providers/EnvsValueSubstitutor.java
        Hide
        jira-bot ASF subversion and git services added a comment -

        Commit 1bf7de8d3799386ad777080e9bf414c0ba3c5d56 in struts's branch refs/heads/master from Lukasz Lenart
        [ https://git-wip-us.apache.org/repos/asf?p=struts.git;h=1bf7de8 ]

        WW-4698 Fixes issue with injecting substitutor

        Show
        jira-bot ASF subversion and git services added a comment - Commit 1bf7de8d3799386ad777080e9bf414c0ba3c5d56 in struts's branch refs/heads/master from Lukasz Lenart [ https://git-wip-us.apache.org/repos/asf?p=struts.git;h=1bf7de8 ] WW-4698 Fixes issue with injecting substitutor
        Hide
        hudson Hudson added a comment -

        SUCCESS: Integrated in Jenkins build Struts-JDK7-master #542 (See https://builds.apache.org/job/Struts-JDK7-master/542/)
        WW-4698 Implements System & ENV variables substitution (lukaszlenart: rev 8135abeca732b996f8e39eb27e59d79563dc4959)

        • (add) core/src/test/java/com/opensymphony/xwork2/config/providers/EnvsValueSubstitutorTest.java
        • (edit) core/src/test/java/com/opensymphony/xwork2/config/providers/ConfigurationTestBase.java
        • (edit) core/src/main/resources/struts-default.xml
        • (add) core/src/test/java/com/opensymphony/xwork2/config/providers/XmlConfigurationProviderEnvsSubstitutionTest.java
        • (edit) core/src/main/java/com/opensymphony/xwork2/config/providers/XWorkConfigurationProvider.java
        • (edit) core/src/main/java/com/opensymphony/xwork2/config/providers/XmlConfigurationProvider.java
        • (add) core/src/main/java/com/opensymphony/xwork2/config/providers/ValueSubstitutor.java
        • (add) core/src/test/resources/com/opensymphony/xwork2/config/providers/xwork-test-envs-substitution.xml
        • (add) core/src/main/java/com/opensymphony/xwork2/config/providers/EnvsValueSubstitutor.java
        Show
        hudson Hudson added a comment - SUCCESS: Integrated in Jenkins build Struts-JDK7-master #542 (See https://builds.apache.org/job/Struts-JDK7-master/542/ ) WW-4698 Implements System & ENV variables substitution (lukaszlenart: rev 8135abeca732b996f8e39eb27e59d79563dc4959) (add) core/src/test/java/com/opensymphony/xwork2/config/providers/EnvsValueSubstitutorTest.java (edit) core/src/test/java/com/opensymphony/xwork2/config/providers/ConfigurationTestBase.java (edit) core/src/main/resources/struts-default.xml (add) core/src/test/java/com/opensymphony/xwork2/config/providers/XmlConfigurationProviderEnvsSubstitutionTest.java (edit) core/src/main/java/com/opensymphony/xwork2/config/providers/XWorkConfigurationProvider.java (edit) core/src/main/java/com/opensymphony/xwork2/config/providers/XmlConfigurationProvider.java (add) core/src/main/java/com/opensymphony/xwork2/config/providers/ValueSubstitutor.java (add) core/src/test/resources/com/opensymphony/xwork2/config/providers/xwork-test-envs-substitution.xml (add) core/src/main/java/com/opensymphony/xwork2/config/providers/EnvsValueSubstitutor.java
        Show
        lukaszlenart Lukasz Lenart added a comment - Docs updated as well https://cwiki.apache.org/confluence/display/WW/Constant+Configuration#ConstantConfiguration-Valuesubstitution
        Hide
        lukaszlenart Lukasz Lenart added a comment -

        Done, implemented

        Show
        lukaszlenart Lukasz Lenart added a comment - Done, implemented
        Hide
        jira-bot ASF subversion and git services added a comment -

        Commit 8135abeca732b996f8e39eb27e59d79563dc4959 in struts's branch refs/heads/master from Lukasz Lenart
        [ https://git-wip-us.apache.org/repos/asf?p=struts.git;h=8135abe ]

        WW-4698 Implements System & ENV variables substitution

        Show
        jira-bot ASF subversion and git services added a comment - Commit 8135abeca732b996f8e39eb27e59d79563dc4959 in struts's branch refs/heads/master from Lukasz Lenart [ https://git-wip-us.apache.org/repos/asf?p=struts.git;h=8135abe ] WW-4698 Implements System & ENV variables substitution

          People

          • Assignee:
            lukaszlenart Lukasz Lenart
            Reporter:
            lukaszlenart Lukasz Lenart
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development