-
Notifications
You must be signed in to change notification settings - Fork 271
Description
Is your feature request related to a problem?
There are no CRD field, api/Queue.go and pkg/resource/queue/sdk.go to accpect redriveAllowPolicy for DeadLetterQueue, which permit source queues to allow sending DLQ message to.
see: https://docs.aws.amazon.com/AWSSimpleQueueService/latest/APIReference/API_SetQueueAttributes.html
There is redrivePolicy, so I can set queue to indicate where is DLQ, but I cannot allow DLQ for source queues.
Describe the solution you'd like
Support of redriveAllowPolicy.
apiVersion: sqs.services.k8s.aws/v1alpha1
kind: Queue
metadata:
name: test-queue
annotations:
services.k8s.aws/region: ap-northeast-1
spec:
queueName: test-queue
policy: |
{
// .. omit
}
redrivePolicy: |
{
"deadLetterTargetArn": "arn:aws:sqs:ap-northeast-1:111111111111:test-dead-letter-queue", # <-- How can we handle circular reference?
"maxReceiveCount": 10
}
---
apiVersion: sqs.services.k8s.aws/v1alpha1
kind: Queue
metadata:
name: test-dead-letter-queue
namespace: default
annotations:
services.k8s.aws/region: ap-northeast-1
spec:
queueName: test-dead-letter-queue
policy: |
{
// .. omit
}
redriveAllowPolicy: | # <---- Missing this field!!
{
redrivePermission = "byQueue",
sourceQueueArns = ["arn:aws:sqs:ap-northeast-1:111111111111:test-queue"] # <-- How can we handle circular reference?
}However, how can I control dependency order when redriveAllowPolicy is comming? DQL require redriveAllowPolicy and Queue require redrivePolicy, it's circular reference. Terraform offers aws_sqs_queue_redrive_allow_policy to set policy after queue and DLQ has beed created..
Describe alternatives you've considered
A description of any alternative solutions or features you've considered.
None.