Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-25779

DescribableHelper.uninstantiate should omit default values of @DataBoundSetter fields

    Details

    • Similar Issues:

      Description

      If given a bean from a class that has at least one @DataBoundSetter, uninstantiate should create another bean using the @DataBoundConstructor and the same constructor parameters, then compare the values of the setter fields. If any are equals to the values from the "control" bean, omit them in the map.

      This would be useful for example for omitting changelog: true from git in the snippet generator.

        Attachments

          Issue Links

            Activity

            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Jesse Glick
            Path:
            CHANGES.md
            cps/src/main/java/org/jenkinsci/plugins/workflow/cps/Snippetizer.java
            cps/src/test/java/org/jenkinsci/plugins/workflow/cps/SnippetizerTest.java
            step-api/src/main/java/org/jenkinsci/plugins/workflow/structs/DescribableHelper.java
            step-api/src/test/java/org/jenkinsci/plugins/workflow/structs/DescribableHelperTest.java
            support/src/test/java/org/jenkinsci/plugins/workflow/support/steps/input/InputStepTest.java
            http://jenkins-ci.org/commit/workflow-plugin/1714a18dff390651095edd5491d0433aa38b6f71
            Log:
            Merge pull request #58 from jglick/DescribableHelper-default-JENKINS-25779

            JENKINS-25779 DescribableHelper.uninstantiate and default values

            Compare: https://github.com/jenkinsci/workflow-plugin/compare/40b9acf658a1...1714a18dff39

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jesse Glick Path: CHANGES.md cps/src/main/java/org/jenkinsci/plugins/workflow/cps/Snippetizer.java cps/src/test/java/org/jenkinsci/plugins/workflow/cps/SnippetizerTest.java step-api/src/main/java/org/jenkinsci/plugins/workflow/structs/DescribableHelper.java step-api/src/test/java/org/jenkinsci/plugins/workflow/structs/DescribableHelperTest.java support/src/test/java/org/jenkinsci/plugins/workflow/support/steps/input/InputStepTest.java http://jenkins-ci.org/commit/workflow-plugin/1714a18dff390651095edd5491d0433aa38b6f71 Log: Merge pull request #58 from jglick/DescribableHelper-default- JENKINS-25779 JENKINS-25779 DescribableHelper.uninstantiate and default values Compare: https://github.com/jenkinsci/workflow-plugin/compare/40b9acf658a1...1714a18dff39
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Jesse Glick
            Path:
            support/src/test/java/org/jenkinsci/plugins/workflow/support/steps/input/InputStepTest.java
            http://jenkins-ci.org/commit/pipeline-input-step-plugin/4546ac04a84345424dcd71140793455cdcf7a6d5
            Log:
            JENKINS-25779 Established test baseline of current behavior.
            Originally-Committed-As: 240173e89fc5da4adfc23135ba9ae4c28b9a02d1

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jesse Glick Path: support/src/test/java/org/jenkinsci/plugins/workflow/support/steps/input/InputStepTest.java http://jenkins-ci.org/commit/pipeline-input-step-plugin/4546ac04a84345424dcd71140793455cdcf7a6d5 Log: JENKINS-25779 Established test baseline of current behavior. Originally-Committed-As: 240173e89fc5da4adfc23135ba9ae4c28b9a02d1
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Jesse Glick
            Path:
            support/src/test/java/org/jenkinsci/plugins/workflow/support/steps/input/InputStepTest.java
            http://jenkins-ci.org/commit/pipeline-input-step-plugin/b884971ddde2506e0dc0713221f51dd31d4b1b8c
            Log:
            JENKINS-25779 Making DescribableHelper.uninstantiate respect non-null default values.
            Originally-Committed-As: cfe1713b5fe9e966399ad7a2d47ba86b4058ae8c

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jesse Glick Path: support/src/test/java/org/jenkinsci/plugins/workflow/support/steps/input/InputStepTest.java http://jenkins-ci.org/commit/pipeline-input-step-plugin/b884971ddde2506e0dc0713221f51dd31d4b1b8c Log: JENKINS-25779 Making DescribableHelper.uninstantiate respect non-null default values. Originally-Committed-As: cfe1713b5fe9e966399ad7a2d47ba86b4058ae8c
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Jesse Glick
            Path:
            cps/src/test/java/org/jenkinsci/plugins/workflow/cps/SnippetizerTest.java
            http://jenkins-ci.org/commit/workflow-cps-plugin/8134067bd7a24db55fbbf52c2781ab3bd4f4a16a
            Log:
            JENKINS-25779 Established test baseline of current behavior.
            Originally-Committed-As: 240173e89fc5da4adfc23135ba9ae4c28b9a02d1

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jesse Glick Path: cps/src/test/java/org/jenkinsci/plugins/workflow/cps/SnippetizerTest.java http://jenkins-ci.org/commit/workflow-cps-plugin/8134067bd7a24db55fbbf52c2781ab3bd4f4a16a Log: JENKINS-25779 Established test baseline of current behavior. Originally-Committed-As: 240173e89fc5da4adfc23135ba9ae4c28b9a02d1
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Jesse Glick
            Path:
            cps/src/test/java/org/jenkinsci/plugins/workflow/cps/SnippetizerTest.java
            http://jenkins-ci.org/commit/workflow-cps-plugin/24f91927932a7f8c5568b5a4259fb6ae75427beb
            Log:
            JENKINS-25779 Making DescribableHelper.uninstantiate respect non-null default values.
            Originally-Committed-As: cfe1713b5fe9e966399ad7a2d47ba86b4058ae8c

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jesse Glick Path: cps/src/test/java/org/jenkinsci/plugins/workflow/cps/SnippetizerTest.java http://jenkins-ci.org/commit/workflow-cps-plugin/24f91927932a7f8c5568b5a4259fb6ae75427beb Log: JENKINS-25779 Making DescribableHelper.uninstantiate respect non-null default values. Originally-Committed-As: cfe1713b5fe9e966399ad7a2d47ba86b4058ae8c

              People

              • Assignee:
                jglick Jesse Glick
                Reporter:
                jglick Jesse Glick
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: