Skip to content

Commit

Permalink
Merge pull request #301 from martindanielsson/feature/add-sqs-change-…
Browse files Browse the repository at this point in the history
…message-visibility-permission

add sqs change message visibility permission to queue
  • Loading branch information
fredericbarthelet authored Mar 7, 2023
2 parents f408415 + 9b9dab2 commit c6e8f74
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/constructs/aws/Queue.ts
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@ export class Queue extends AwsConstruct {
}

permissions(): PolicyStatement[] {
return [new PolicyStatement("sqs:SendMessage", [this.queue.queueArn])];
return [new PolicyStatement(["sqs:SendMessage", "sqs:ChangeMessageVisibility"], [this.queue.queueArn])];
}

extend(): Record<string, CfnResource> {
Expand Down
2 changes: 1 addition & 1 deletion test/unit/queues.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ describe("queues", () => {
// eslint-disable-next-line @typescript-eslint/no-unsafe-assignment
Statement: expect.arrayContaining([
{
Action: "sqs:SendMessage",
Action: ["sqs:SendMessage", "sqs:ChangeMessageVisibility"],
Effect: "Allow",
Resource: [
{
Expand Down

0 comments on commit c6e8f74

Please sign in to comment.