AWS Classroom Series – 18/Dec/2021

Events in CloudWatch

  • AWS has a new service for events which is called as Event Bridge Preview Preview

  • Cloudwatch events are designed to be able to respond to changes in different AWS resources and services

  • Using some rules that determine specific change or action or activity that tookplace, Cloudwatch events can be configured to respond accordingly.

  • Amazon EventBridge

    • This is newer version of Amazon CloudWatch Events.
    • Event Bridge is a serverless event bus service that is designed to responds to events by triggering other events
    • Event bridge is very similar to Cloud Watch Events => it recieves events and responds to events from other services
    • Event bridge is different from Cloud Watch Events as it can respind to the events from sources others than AWS Services.
    • Events from Software as a Services or custom applications can be tied to EventBridge and we can respond Accordingly.
  • Components of Cloudwatch Event:

    • Input Trigger:
      • This is what starts the process or the CloudWatch Event
      • It contains information that is useful for the behavior of the resulting trigger and how the event pattern behaves
      • The input trigger or event source can range from different AWS Services
      • In the Case of Event Bridge, in addition to AWS sources we can also get events from third party
        • PagerDuty
        • Opsgenie
        • Datadog
        • SugarCRM
    • Rule/event pattern:
      • The event pattern gives Cloudwatch Events all the information it needs to react to it
    • Target:
      • This is the destination service that reacts to the input trigger
  • Activity: Lets try to use the events to notify the state changes (running -> shutdown etc…)

    • create a rule Preview Preview
    • Add a target Preview Preview Preview
    • To configure specific instances Preview
  • Activity: Lets assume your organization wants to start some ec2 instances at 10:00 AM on every working day and shutdown ec2 instances at 7:00 PM to save costs

    • This is where the Schedule will be your input trigger
    • Lets try to create cron sytnax Refer Here Preview Preview
    • To know more about cloudwatch schedule expression Refer Here
    • The timezone over here is UTC => Convert to your timezone Preview Preview

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

About learningthoughtsadmin