AWS CodeCommit notification is a feature of AWS CodeCommit, a managed source control service provided by Amazon Web Services (AWS). The notification feature allows you to receive automated notifications via various channels when certain events occur in your AWS CodeCommit repositories, such as code pushes, pull requests, and branch or tag creations or deletions.

AWS CodeCommit notifications can be configured to send notifications to a variety of destinations, including email addresses, Amazon Simple Notification Service (SNS) topics, and AWS Lambda functions. You can also customize the content of the notification messages, including the message template and the events that trigger notifications.

Protect Your Data with BDRSuite

Cost-Effective Backup Solution for VMs, Servers, Endpoints, Cloud VMs & SaaS applications. Supports On-Premise, Remote, Hybrid and Cloud Backup, including Disaster Recovery, Ransomware Defense & more!

AWS CodeCommit

Create SNS topic

If you do not have existing SNS topic, please follow the below procedure to create one.

  1. Navigate to SNS topic service and click on “Create topic”
  2. AWS CodeCommit

    Download Banner
  3. Select the topic type as “Standard”
  4. AWS CodeCommit

  5. Navigate to subscriptions and click on “Create subscription”
  6. AWS CodeCommit

  7. Enter the subscription details
  8. AWS CodeCommit

  9. SNS topic has been successfully created
  10. AWS CodeCommit

  11. Login to the email endpoint and click on “confirm subscription”

AWS CodeCommit

Configure AWS CodeCommit notifications

  1. Open the AWS Management Console and navigate to the CodeCommit service
  2. AWS CodeCommit

  3. In the CodeCommit console, select the repository for which you want to configure notifications
  4. AWS CodeCommit

  5. From the repository details page, choose the “Settings” option in the left navigation menu
  6. AWS CodeCommit

  7. Scroll down to the “Notifications” section, and choose “Create Notification”
  8. AWS CodeCommit

  9. Select the type of notification you want to configure. AWS CodeCommit supports notifications for various events, such as repository pushes, pull requests, and branch or tag creations or deletions.

    Specify the notification recipients. This can include email addresses, Amazon SNS topics, or AWS Lambda functions.

  10. AWS CodeCommit

  11. Customize the notification settings as needed, such as the message template and the events that trigger notifications
  12. Choose “Submit” to save the configuration
  13. AWS CodeCommit

  14. Navigate to triggers
  15. AWS CodeCommit

  16. Configure triggers like below

AWS CodeCommit

AWS CodeCommit

Test our work

  1. Let’s create a new branch. Navigate to CodeCommit – > Branches
  2. AWS CodeCommit

  3. Create a new branch from master
  4. AWS CodeCommit

  5. Once the branch is created, click on the branch to browse the repo. I have selected “pom.xml” to make some updates to it
  6. AWS CodeCommit

  7. Once the update is made, click on “create pull request”
  8. AWS CodeCommit

  9. In real world, one of your team members or authorized reviewer will review the change and merge it with master
  10. AWS CodeCommit

  11. Click on merge to push the changes from developer1 branch to master
  12. AWS CodeCommit

  13. Once you merge the pull request, you should have got the notification on your email like below

AWS CodeCommit

Conclusion

By using AWS CodeCommit notifications, you can stay informed about important events in your repositories and respond quickly to changes in your codebase. This can help you to improve collaboration and streamline your development workflow. You can configure multiple notifications for a single repository, and you can also use AWS CloudWatch Events to route notifications to other AWS services, such as Amazon SNS or AWS Lambda.

Follow our Twitter and Facebook feeds for new releases, updates, insightful posts and more.

Rate this post