Why is subscriber optional on ansible sns?

0 votes

I subscribe to a lambda function to an SNS topic. When I do this using the aws console or even the aws command-line interface, there is a column named "subscriber" in the subscription information, which contains my account id.

I am unable to control this field using neither AWS console nor the command-line. However, I can do the same thing using ansible.

---

- name: set up topic and subscribe lambda

sns_topic:

   name: "topic_name"

   state: present

   display_name: "Display Name"

   Subscriptions:

        - endpoint: "arn:aws:lambda:ap-southeast-2:123456789:function:functionName"

  protocol: "lambda"

  subscriber: 123456789

Here a couple of questions I had. Isn't the subscriber field optional? But the SNS messages do not seem to reach lambda without it.

  • What is this field for?

  • Can I subscribe to Lambdas in other accounts for my SNS topic?

  • How can I affect change in this field with AWS CLI?

  • Why is it optional in Ansible 2.4

Aug 8, 2018 in AWS by bug_seeker
• 15,480 points

edited Jun 8 by Sirajul 170 views

1 answer to this question.

0 votes

Hey @bug_seeker, I could not find any reference to the field "subscriber".

I guess this could have been supported by the older sdk/api  which has now been dropped.

Although here are some findings from my research on this topic:

1. I couldn't find the subscriber field in the AWS console when subscribing to lambda. You can see the image below:

 2. Even in the AWS command line there is no such field. 

Link for SNS Subscribe command through CLI documentation.

answered Aug 8, 2018 by Priyaj
• 57,640 points

edited Jun 8 by Sirajul

Related Questions In AWS

0 votes
2 answers

What is the difference between Amazon SNS and Amazon SQS?

Amazon SQS and SNS are the two ...READ MORE

answered Sep 9 in AWS by Michael
• 140 points
1,349 views
+7 votes
2 answers

Why S3 is called a Object storage?

Amazon S3 stores data as objects within resources called "buckets".  Object storage, also ...READ MORE

answered Sep 24, 2018 in AWS by Priyaj
• 57,640 points
3,310 views
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 26, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
669 views
+1 vote
2 answers

AWS CloudWatch Logs in Docker

The awslogs works without using ECS. you need to configure ...READ MORE

answered Sep 6, 2018 in AWS by bug_seeker
• 15,480 points
734 views
0 votes
1 answer