Notifications can trigger on Amazon S3 when any of the following events occur:
s3:ObjectCreated:*s3:ObjectCreated:Puts3:ObjectCreated:Posts3:ObjectCreated:Copys3:ObjectCreated:CompleteMultipartUploads3:ObjectRemoved:*s3:ObjectRemoved:Deletes3:ObjectRemoved:DeleteMarkerCreateds3:ReducedRedundancyLostObject
Notifications can be sent through three destinations:
- Amazon Simple Notification Service (SNS) , which in turn can send notifications by email, HTTP / S endpoint, SMS, mobile push notification
- Amazon Simple Queuing Service (SQS)
- Amazon Lambda (not yet available in all regions)
See: Setting up Amazon S3 event notifications
The most suitable choice depends on your preference for programming and how your application is written:
- Use SNS to navigate to the HTTP endpoint to invoke some code in your application.
- Write a code to periodically check the SQS queue
- Write a lambda function in Node.js or Java
After launching, your code will then need to determine who uploaded the video, get their user data, and then send them an email notification. This would be easiest if you control the key (file name) of the loaded object, as this will help identify the user for notification.
source share