Build Chain parameter causing empty to child build

Hello,

Build Chain pipeline input parameter pass the empty value to Child job.

Stage1 (user pass input parameter) -→ Stage2 (input parameter get from Stage 1 run the job ) -→ Stage 3 (input parameter get from Stage 1 run the job and it's different job)

We have faced the experience input parameter is going on empty value to Stage2 and Stage 3

Following package we used 
import jetbrains.buildServer.configs.kotlin.v2018_2.*
import jetbrains.buildServer.configs.kotlin.v2018_2.buildSteps.script

 

Regards,

Anand

 

0
1 comment

Hi,

Build parameters defined in one build configuration are not automatically available to others. However, they can be accessed by another build configuration through a snapshot dependency or an artifact dependency.

To pass a value from a parent build to a child build, you need to use Dependency Property References, for example:

%dep.Stage1Job.outputparameter%

In the Output Parameters tab of the parent build configuration, there is a setting called “All parameters are available to other build configurations”.

When this option is enabled, all parameters defined in the parent build can be accessed by dependent configurations using the following syntax:

dep.<configuration ID>.<parameter name>

This setting is enabled by default for backward compatibility.
 

Please update your Kotlin DSL to use the %dep...% references and verify whether the parameter values are passed correctly.
 

If you still encounter issues, feel free to share a relevant snippet of your settings.kts file, and we’ll be happy to take a closer look.

0

Please sign in to leave a comment.