jenkinsci/aws-sam-plugin

Intrinsic function values are split incorrectly

Closed this issue · 0 comments

Version report

Jenkins and plugins versions report:

Jenkins: 2.303.3
OS: Linux - 3.10.0-1160.31.1.el7.x86_64
---
ace-editor:1.1
analysis-model-api:10.6.0
ant:1.12
antisamy-markup-formatter:2.4
apache-httpcomponents-client-4-api:4.5.13-1.0
artifactory:3.13.2
authentication-tokens:1.4
aws-credentials:1.32
aws-java-sdk:1.12.101-300.vc09c7be9cb57
aws-java-sdk-cloudformation:1.12.101-300.vc09c7be9cb57
aws-java-sdk-codebuild:1.12.101-300.vc09c7be9cb57
aws-java-sdk-ec2:1.12.101-300.vc09c7be9cb57
aws-java-sdk-ecr:1.12.101-300.vc09c7be9cb57
aws-java-sdk-ecs:1.12.101-300.vc09c7be9cb57
aws-java-sdk-elasticbeanstalk:1.12.101-300.vc09c7be9cb57
aws-java-sdk-iam:1.12.101-300.vc09c7be9cb57
aws-java-sdk-logs:1.12.101-300.vc09c7be9cb57
aws-java-sdk-minimal:1.12.101-300.vc09c7be9cb57
aws-java-sdk-ssm:1.12.101-300.vc09c7be9cb57
aws-sam:1.2.5
blueocean:1.25.1
blueocean-autofavorite:1.2.4
blueocean-bitbucket-pipeline:1.25.1
blueocean-commons:1.25.1
blueocean-config:1.25.1
blueocean-core-js:1.25.1
blueocean-dashboard:1.25.1
blueocean-display-url:2.4.1
blueocean-events:1.25.1
blueocean-git-pipeline:1.25.1
blueocean-github-pipeline:1.25.1
blueocean-i18n:1.25.1
blueocean-jira:1.25.1
blueocean-jwt:1.25.1
blueocean-personalization:1.25.1
blueocean-pipeline-api-impl:1.25.1
blueocean-pipeline-editor:1.25.1
blueocean-pipeline-scm-api:1.25.1
blueocean-rest:1.25.1
blueocean-rest-impl:1.25.1
blueocean-web:1.25.1
bootstrap4-api:4.6.0-3
bootstrap5-api:5.1.3-1
bouncycastle-api:2.25
branch-api:2.7.0
build-timeout:1.20
caffeine-api:2.9.2-29.v717aac953ff3
checks-api:1.7.2
cloudbees-bitbucket-branch-source:2.9.11
cloudbees-folder:6.16
code-coverage-api:2.0.4
command-launcher:1.6
config-file-provider:3.8.1
copyartifact:1.46.2
credentials:2.6.1
credentials-binding:1.27
data-tables-api:1.11.3-4
display-url-api:2.3.5
docker-commons:1.17
docker-workflow:1.26
durable-task:1.39
echarts-api:5.2.2-1
email-ext:2.84
favorite:2.3.3
font-awesome-api:5.15.4-1
forensics-api:1.6.0
git:4.10.0
git-client:3.10.0
git-server:1.10
github:1.34.1
github-api:1.133
github-branch-source:2.11.3
gradle:1.37.1
handlebars:3.0.8
handy-uri-templates-2-api:2.1.8-1.0
htmlpublisher:1.27
ivy:2.1
jackson2-api:2.13.0-230.v59243c64b0a5
javadoc:1.6
jaxb:2.3.0.1
jdk-tool:1.5
jenkins-design-language:1.25.1
jira:3.6
jira-steps:1.6.0
jjwt-api:0.11.2-9.c8b45b8bb173
jquery:1.12.4-1
jquery3-api:3.6.0-2
jsch:0.1.55.2
junit:1.53
ldap:2.7
lockable-resources:2.12
mailer:1.34
mask-passwords:3.0
matrix-auth:2.6.8
matrix-project:1.19
mattermost:3.1.1
maven-plugin:3.15.1
momentjs:1.1.1
okhttp-api:4.9.2-20211102
pam-auth:1.6.1
pipeline-aws:1.43
pipeline-build-step:2.15
pipeline-github-lib:1.0
pipeline-graph-analysis:1.11
pipeline-input-step:2.12
pipeline-milestone-step:1.3.2
pipeline-model-api:1.9.2
pipeline-model-definition:1.9.2
pipeline-model-extensions:1.9.2
pipeline-rest-api:2.19
pipeline-stage-step:2.5
pipeline-stage-tags-metadata:1.9.2
pipeline-stage-view:2.19
pipeline-utility-steps:2.10.0
plain-credentials:1.7
plugin-util-api:2.5.1
popper-api:1.16.1-2
popper2-api:2.10.2-1
pubsub-light:1.16
resource-disposer:0.16
scm-api:2.6.5
script-security:1.78
snakeyaml-api:1.29.1
sonar:2.13.1
sse-gateway:1.24
ssh-credentials:1.19
ssh-slaves:1.33.0
ssh-steps:2.0.0
sshd:3.1.0
structs:1.23
timestamper:1.13
token-macro:267.vcdaea6462991
trilead-api:1.0.13
variant:1.4
warnings-ng:9.7.0
workflow-aggregator:2.6
workflow-api:2.47
workflow-basic-steps:2.24
workflow-cps:2633.v6baeedc13805
workflow-cps-global-lib:545.v7b28cce323cf
workflow-durable-task-step:2.39
workflow-job:2.42
workflow-multibranch:2.26
workflow-scm-step:2.13
workflow-step-api:2.24
workflow-support:3.8
ws-cleanup:0.39
xray-connector:2.5.1
  • What Operating System are you using (both controller, and any agents involved in the problem)?
CentOS Linux release 7.9.2009

Reproduction steps

  • create a template with nested stacks with outputs
  • reference a nested stack output with GetAtt function like !GetAtt NestedStack.Outputs.SomeOutput
  • try to deploy using sam plugin

Results

Expected result:

Stack should be created/updated (this is what sam deploy does)

Actual result:

  • SAM deployment fails with error message
com.amazonaws.waiters.WaiterUnrecoverableException: Resource never entered the desired state as it failed.
	at com.amazonaws.waiters.WaiterExecution.pollResource(WaiterExecution.java:78)
	at com.amazonaws.waiters.WaiterImpl.run(WaiterImpl.java:88)
	at com.amazonaws.jenkins.plugins.sam.service.CloudFormationService.waitForChangeSet(CloudFormationService.java:105)
Caused: com.amazonaws.jenkins.plugins.sam.model.SamPluginException: ChangeSet cannot be created
	at com.amazonaws.jenkins.plugins.sam.service.CloudFormationService.waitForChangeSet(CloudFormationService.java:111)
	at com.amazonaws.jenkins.plugins.sam.service.CloudFormationService.createChangeSet(CloudFormationService.java:66)
	at com.amazonaws.jenkins.plugins.sam.DeployBuildStep.createChangeSet(DeployBuildStep.java:113)
	at com.amazonaws.jenkins.plugins.sam.DeployBuildStep.perform(DeployBuildStep.java:84)
	at jenkins.tasks.SimpleBuildStep.perform(SimpleBuildStep.java:123)
	at org.jenkinsci.plugins.workflow.steps.CoreStep$Execution.run(CoreStep.java:100)
	at org.jenkinsci.plugins.workflow.steps.CoreStep$Execution.run(CoreStep.java:70)
	at org.jenkinsci.plugins.workflow.steps.SynchronousNonBlockingStepExecution.lambda$start$0(SynchronousNonBlockingStepExecution.java:47)
	at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
	at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
	at java.base/java.lang.Thread.run(Thread.java:834)
  • CloudFormation ChangeSet creation failed with status reason Template error: every Fn::GetAtt object requires two non-empty parameters, the resource name and the resource attribute
  • Resulting template contains invalid configuration, like Fn::GetAtt: [NestedStack, Outputs, SomeOutput]