-
Notifications
You must be signed in to change notification settings - Fork 544
Description
Expected Behavior
Upon termination (and notably in scale down) of a dapr application using pubsub.snssqs component, publisher should be able to keep publishing to SNS topics
Actual Behavior
Upon termination of a dapr application using pubsub.snssqs component (still only available in 'master'), daprd closes all pubsub components while calling the snssqs component Close function. The implementation in that function is derived from a misunderstanding of the SNS-SQS subscription model. Thus once a single daprd snssqs publisher/subscriber is terminating, the aforementioned function deletes the SNS-subscription. That subscription effectively is an SQS subscription (not a client/daprd subscription). Meaning, SQS is registered as a subscriber to an SNS topic. While this subscription is being deleted, SNS no longer considers SQS as its subscriber and messages are stopped from being published to SQS. The resolution is to make the Close function a NOOP (as I've tested on my fork)
Steps to Reproduce the Problem
- Apply the
pubsub.snssqscomponent over k8s. - Publish messages - verify publishing works.
- Go to AWS console for SNS and verify that SNS subscriptions for SQS have been created
- Scale down (not to zero) the consuming/producing application (and dapr application using that pubsub component).
- See on AWS console of SNS that the (SQS) subscriptions have been deleted
Release Note
RELEASE NOTE: