feat(scheduler-targets): add CodePipeline as target for scheduler#27799
feat(scheduler-targets): add CodePipeline as target for scheduler#27799mergify[bot] merged 23 commits intoaws:mainfrom
Conversation
aws-cdk-automation
left a comment
There was a problem hiding this comment.
The pull request linter has failed. See the aws-cdk-automation comment below for failure reasons. If you believe this pull request should receive an exemption, please comment and provide a justification.
A comment requesting an exemption should contain the text Exemption Request. Additionally, if clarification is needed add Clarification Request to a comment.
✅ Updated pull request passes all PRLinter validations. Dismissing previous PRLinter review.
packages/@aws-cdk/aws-scheduler-targets-alpha/lib/codepipeline-start-pipeline-execution.ts
Outdated
Show resolved
Hide resolved
I have created an issue for that: #27816 |
|
@lpizzinidev Do you think I should "fix" the What are your thoughts on that? |
|
@daschaa In my opinion, this is a bug on imported resources from ARNs, as you state in #27816 and, for the CodePipeline target, it should be fixed in this PR since it's directly related to the implementation. However, it's also good to have an issue open to keep track of the "bug", as it does affect multiple resources and some discussion might be needed to get to an ideal and consistent solution. |
|
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
3 similar comments
|
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
|
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
|
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
|
This PR has been in the MERGE CONFLICTS state for 3 weeks, and looks abandoned. To keep this PR from being closed, please continue work on it. If not, it will automatically be closed in a week. |
lpizzinidev
left a comment
There was a problem hiding this comment.
Looks good, thanks!
Just some tests following the last changes are required in my opinion.
| const stack = new cdk.Stack(new cdk.App(), 'Stack', { | ||
| env: { | ||
| region: 'eu-west-1', | ||
| account: '234567890123', | ||
| }, | ||
| }); | ||
|
|
||
| const pipeline = codepipeline.Pipeline.fromPipelineArn(stack, 'Pipeline', | ||
| 'arn:aws:codepipeline:us-east-1:123456789012:MyPipeline'); | ||
|
|
||
| expect(pipeline.env.region).toEqual('us-east-1'); | ||
| expect(pipeline.env.account).toEqual('123456789012'); |
There was a problem hiding this comment.
| const stack = new cdk.Stack(new cdk.App(), 'Stack', { | |
| env: { | |
| region: 'eu-west-1', | |
| account: '234567890123', | |
| }, | |
| }); | |
| const pipeline = codepipeline.Pipeline.fromPipelineArn(stack, 'Pipeline', | |
| 'arn:aws:codepipeline:us-east-1:123456789012:MyPipeline'); | |
| expect(pipeline.env.region).toEqual('us-east-1'); | |
| expect(pipeline.env.account).toEqual('123456789012'); | |
| const stack = new cdk.Stack(); | |
| const pipeline = codepipeline.Pipeline.fromPipelineArn(stack, 'Pipeline', | |
| 'arn:aws:codepipeline:us-west-1:123456789012:MyPipeline'); | |
| expect(pipeline.env.region).toEqual('us-west-1'); | |
| expect(pipeline.env.account).toEqual('123456789012'); |
Let's keep it simple.
There was a problem hiding this comment.
I prefer adding the env to the stack explicitly, because it shows that the import really does not use the environment of the stack 🤔
|
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
5 similar comments
|
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
|
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
|
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
|
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
|
This PR cannot be merged because it has conflicts. Please resolve them. The PR will be considered stale and closed if it remains in an unmergeable state. |
| return new Import(scope, id); | ||
| return new Import(scope, id, { | ||
| environmentFromArn: pipelineArn, | ||
| }); |
There was a problem hiding this comment.
This is just a bug fix to codepipeline that we should have had in a long time ago lol
|
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
|
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
Pull request has been modified.
|
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
AWS CodeBuild CI Report
Powered by github-codebuild-logs, available on the AWS Serverless Application Repository |
|
Thank you for contributing! Your pull request will be updated from main and then merged automatically (do not update manually, and be sure to allow changes to be pushed to your fork). |
Closes #27449
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache-2.0 license