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

Option for input parameters to be flattened to string

      Currently InputStepExecution.convert calls ParameterValue.getValue() and returns the value raw, under the assumption it is Serializable and sandbox-friendly.

      This is not true at least for the case of RunParameterValue. We would prefer to have the option to call buildEnvironment and return a flat Map<String,String>.

          [JENKINS-34101] Option for input parameters to be flattened to string

          Jesse Glick added a comment - - edited

          In a sense the opposite of JENKINS-27295, though that pertains to build parameters whereas this is about parameters passed to the input step.

          Jesse Glick added a comment - - edited In a sense the opposite of JENKINS-27295 , though that pertains to build parameters whereas this is about parameters passed to the input step.

          Jesse Glick added a comment -

          Should probably refuse to include PasswordParameterValue since these would neither be stored safely in program.dat (via SecretPickle) nor masked in console output. For that it is better to use withCredentials and ask for per-user credentials, or use the Mask Passwords plugin (though for that case probably structs needs to be amended to let a Secret be bound to a String so that you can create a VarPasswordPair without even temporarily storing plaintext in the program).

          Jesse Glick added a comment - Should probably refuse to include PasswordParameterValue since these would neither be stored safely in program.dat (via SecretPickle ) nor masked in console output. For that it is better to use withCredentials and ask for per-user credentials, or use the Mask Passwords plugin (though for that case probably structs needs to be amended to let a Secret be bound to a String so that you can create a VarPasswordPair without even temporarily storing plaintext in the program).

          Jesse Glick added a comment -

          See discussion in JENKINS-43814.

          Jesse Glick added a comment - See discussion in JENKINS-43814 .

            jglick Jesse Glick
            jglick Jesse Glick
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: