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

Allow InputStep.id to start with a lowercase letter

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      As per this change, the id of an input step must start with a capital letter. Fine enough for computed IDs, but very confusing for an explicitly specified ID.

      The reasoning was so that getDynamic would not be ambiguous. But I think this would be fixed more easily by deprecating getDynamic, using getExecution, and making this code append execution/ to the base URL.

        Attachments

          Issue Links

            Activity

            jglick Jesse Glick created issue -
            jglick Jesse Glick made changes -
            Field Original Value New Value
            Link This issue is related to JENKINS-26224 [ JENKINS-26224 ]
            jglick Jesse Glick made changes -
            Epic Link JENKINS-35394 [ 171187 ]
            rtyler R. Tyler Croy made changes -
            Workflow JNJira [ 170642 ] JNJira + In-Review [ 183986 ]
            abayer Andrew Bayer made changes -
            Component/s pipeline-general [ 21692 ]
            abayer Andrew Bayer made changes -
            Component/s workflow-plugin [ 18820 ]
            jglick Jesse Glick made changes -
            Component/s pipeline-input-step-plugin [ 21708 ]
            Component/s pipeline [ 21692 ]
            Hide
            leflamm C Flamm added a comment -

            Currently (v2.36) it's possible to define an input with a lower case id, but if you later want to provide the input via Rest you have to spell the id with a capital first letter.

            ...
                stage ('main') {
                    input(id: 'foofoo', message: 'Moo?')
                }
            ...
            

            id used as defined doesn't work.

            $ curl -X POST http://localhost:8080/job/pipe1/16/input/foofoo/proceedEmpty
            <html>
            <head>
            <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
            <title>Error 404 Not Found</title>
            </head>
            <body><h2>HTTP ERROR 404</h2>
            <p>Problem accessing /job/pipe1/16/input/foofoo/proceedEmpty. Reason:
            <pre>    Not Found</pre></p><hr><i><small>Powered by Jetty://</small></i><hr/>
            
            </body>
            </html>
            

            Capitalized id works fine.

            $ curl -X POST http://localhost:8080/job/pipe1/16/input/Foofoo/proceedEmpty
            
            Show
            leflamm C Flamm added a comment - Currently (v2.36) it's possible to define an input with a lower case id , but if you later want to provide the input via Rest you have to spell the id with a capital first letter. ... stage ('main') { input(id: 'foofoo', message: 'Moo?') } ... id used as defined doesn't work. $ curl -X POST http://localhost:8080/job/pipe1/16/input/foofoo/proceedEmpty <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <title>Error 404 Not Found</title> </head> <body><h2>HTTP ERROR 404</h2> <p>Problem accessing /job/pipe1/16/input/foofoo/proceedEmpty. Reason: <pre> Not Found</pre></p><hr><i><small>Powered by Jetty://</small></i><hr/> </body> </html> Capitalized id works fine. $ curl -X POST http://localhost:8080/job/pipe1/16/input/Foofoo/proceedEmpty
            jamesdumay James Dumay made changes -
            Labels cloudbees-internal-pipeline
            cloudbees CloudBees Inc. made changes -
            Remote Link This issue links to "CloudBees Internal CD-31 (Web Link)" [ 19135 ]
            vivek Vivek Pandey made changes -
            Labels cloudbees-internal-pipeline cloudbees-internal-pipeline triaged-2018-11

              People

              • Assignee:
                jglick Jesse Glick
                Reporter:
                jglick Jesse Glick
              • Votes:
                1 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated: