And welcome back.
Now in today's video, we'll be discussing about these three event notification now at a high level
overview, the S3 event notification feature allows you to receive notification when a certain event
happens within your S3 bucket.
So let's take an example.
So let's say there is an operation that has happened in your history book.
So this can be various operations, like, for example, let's say someone has uploaded certain file
in history.
So that is expiration for this example.
Now, based on this specific put operation, the is bucket, with the help of event notification feature,
can send event to various endpoints like Lambda, Rescuer's and Ascendis.
Now, what does this event basically contain?
It basically contains the details that someone has uploaded file to the S3 bucket and basically it is
a port operation and various other things like Timestamp and others.
So this is the basic of what a three event notification allows you to do now.
And there are a lot of important use cases for event notification will be discussing about this in just
a moment.
But before we do that, let's complete this practically so that our basic concept is better understood.
Now for today's video, let's go ahead and quickly create a new bucket.
I'll just call it as my AP labs haven't even time for notification.
Now, this can even work if you have existing bucket.
It all depends upon the scenario.
However, for simplicity, I'll just use it from scratch.
So we have a Strathbogie.
Let's quickly open this up now.
At this specific stage, whenever a certain event occurs like uploading a file or deletion of file.
We do not directly have a notification feature enabled.
So what you can do, you can go to properties.
Let's go bit down.
And within you, you have the event notifications and currently you see there are no notifications that
are available, so let's go ahead and create a new notification.
The event is something that you can specify.
And the most important part here is the even types based on what event types you want the notification
to be sent to various endpoints like Lambda Eschaton asanas.
So you have both, you have Borst, you have copy, you have delete related events, restor related
events, replication related events and so on.
And the next important part is the destination.
Destination can be LAMDA, Senate or rescuer's.
So in case if you have business then you have more flexibility related to where the event can be sent,
including email.
So let's do one thing.
In order for us to create this specific event notification, we need to have this destination up and
ready.
So for two days we will be making use of our destination of addressing this topic.
So let's go ahead and go to the soonest service.
Now currently within the Senate's control, let's go to topic and let's create a new topic, not a topic.
Let us use the standard one and let's call it, as is three event notification and will create a topic
right now once the topic is created.
The next part is to create a subscription.
Let's do that now based on the protocol.
Again, there are multiple ways you have SMS, EDP, stripper's email and so on will be using email
for simplicity.
You can specify the email address.
Let me give the email address here.
And now you can create a subscription.
So this should go ahead and send you an email for verification purposes.
So within the email you see that we have received email and we have to confirm the subscription.
So let's go ahead and confirm the subscription and Perfecta subscription is confirmed.
Now, one more important thing that needs to be noted here specifically for the Zenescope, it is that
43 even notification feature will be able to send the notification to send it to Ascendis must also
allow the notification to happen.
So what you need to do is you need to go ahead and add a specific policy to the S3 event notification
topic.
So within the access policy, Audur, so you see this is the policy and what we need to do is we have
to edit it so that the S3 even notification can send the notification here.
So I'll click on editorial and within the access policy, one important part to note is the airing of
the topic.
Now within the item, Ed..
I have a sample based policy available.
So what this policy does, it basically allows the service is treated, Amazon AWG dot com to go ahead
and do a publish related action on the area of the census topic.
So what we need to do is we have to copy this area and we have to pay audio.
And one more thing to note is that we also have a condition and within the condition you have the area
not distributed.
So you can directly copy the name of the EU budget, which is Mike Epilepsia notification.
So let's go a bit back.
So I'll cover this up and let's face it.
Great.
So let's go P.D.A.
And within our access policy for our topic, I'll paste it and let's do a sea change.
Great.
So at this stage, addressing this topic is ready with the right access policy that allows the S3 to
publish notifications here.
Now, once you have done that, we can go ahead and create an event notification.
So let's quickly do that.
So I'll create a new event notification list, call it as demo notify.
And within the event tape, you can either select one or you can select the entire category of all object
creative.
And so let's do the all object, create events or anywhere object is created.
We'll get an email.
So we'll use that.
That destination will use DNS and SNH topic is a street event notification once.
Then you can see if the change pavic.
So in order to test if things are working, let's go ahead and upload some file in this bucket.
So allow the file and let me add temporary text file available in my desktop and I'll click on upload.
Perfect.
So now within email you see I received an email right away associated with the Amazon S3 notification.
Now your record is in Jason.
It's a little difficult to read.
However, let's quickly copy this up.
And in a web that does Jizan formatting, let me paste here.
Let's process this to understand how the design even looks like.
Another important thing that you will see, Horia, is the event source, which is a street.
The region is us e when you have the event time and the event name is object created.
But so there was a port operation that had taken place.
It is giving you the IP address from which the port operation has taken place.
And if you look into the object, it is showing you the name of the object that was uploaded, which
is MPLX for DataDot B.
Great.
So I hope you understood the basics of what a Stryver notification allows you to do.
Now, I'll give you a real world use case, primarily because we used to use this as part of our security
related project.
So what used to happen was we had a three bucket and any time user uploaded data to the S3 bucket,
we do not really know if their data is infected with malware or virus or any other thing.
So the data needs to be scanned.
Now, who will take care of scanning the lambda function?
So now what will happen?
Anytime a user uploads the data to a supermarket, the notification would go to the lambda function,
lambda function.
We'll get the exact object name similar to what we see, it will get the object name, it will fetch
this specific object, it will go ahead and scan it in case if it has a light, it it will notify us
via email.
If it does not have, then there is no notification there.
So this is one of the use cases which I have seen many of the organization used specifically in terms
of security using the Estrela notification.
So that's about it, about the basics of even notification.
And with this will conclude today's we do.
And again, the policy that we have used in today's video, I'll add it as part of the resource section
of the video so that you can also reference to it.