1
00:00:00,300 --> 00:00:06,360
In this video, we are going to publish message from the Amazon sans topic and these will be subscribed

2
00:00:06,360 --> 00:00:11,550
from the lambda and we will see lambda execution log from the Amazon Cloud Watch logs.

3
00:00:12,000 --> 00:00:13,420
So let's get started.

4
00:00:13,440 --> 00:00:20,770
For that purpose, please open the A management console and go to the SAS topics and open the outgoing

5
00:00:20,820 --> 00:00:24,540
notification and you can see the publish message button in here.

6
00:00:24,570 --> 00:00:26,490
Click the publish message and give.

7
00:00:26,490 --> 00:00:29,010
The subject is a gold.

8
00:00:30,140 --> 00:00:34,010
And you can give the random message in the body information.

9
00:00:36,350 --> 00:00:41,570
We provide the subject and the body information, and if you scroll down, we can publish a message,

10
00:00:41,570 --> 00:00:46,820
click the publish message, and we have successfully publishing message to Amazon sans topic, which

11
00:00:46,820 --> 00:00:48,140
is the goal notification.

12
00:00:48,140 --> 00:00:53,960
And this will be consumed by the subscriptions subscribers and our subscriber is the ADA, which is

13
00:00:53,960 --> 00:00:54,570
Lambda.

14
00:00:54,590 --> 00:01:01,900
If you go to the ADA Lambda open the goal function and go to monitor and we include voice logs.

15
00:01:01,970 --> 00:01:05,390
We should see the execution invocation.

16
00:01:05,390 --> 00:01:06,020
Yes.

17
00:01:06,050 --> 00:01:08,030
As you can see that we have a one log stream.

18
00:01:08,030 --> 00:01:14,780
And if you open this log stream, you can see the incoming event, JSON from the SNS topic and this

19
00:01:14,780 --> 00:01:16,620
is the details about the topic.

20
00:01:16,640 --> 00:01:23,540
This is a notification message did topic and subject and the message we can see the subject and message

21
00:01:23,540 --> 00:01:30,560
that we send from the SMS topic and this is the execute our lambda function and we basically log the

22
00:01:30,560 --> 00:01:35,060
incoming event JSON and write down the message into our logs.

23
00:01:35,150 --> 00:01:41,630
So as you can see that we have finished our hands on lab, we can extend this lab, for example, we

24
00:01:41,630 --> 00:01:47,320
can insert incoming notification into Dynamo DB table or send it to the case and so on.

25
00:01:47,330 --> 00:01:53,570
We will do implement these kind of hansen-love in the upcoming sections, but now it is enough for now.
