AWS CodeBuild
User Guide (API Version 2016-10-06)

The procedures in this guide support the new console design. If you choose to use the older version of the console, you will find many of the concepts and basic procedures in this guide still apply. To access help in the new console, choose the information icon.

Monitoring Builds with CloudWatch Metrics

AWS CodeBuild monitors functions on your behalf and reports metrics through Amazon CloudWatch. These metrics include the number of total builds, failed builds, successful builds, and the duration of builds.

You can use the AWS CodeBuild console or the CloudWatch console to monitor metrics for AWS CodeBuild. The following procedures show you how to access metrics.

Access Build Metrics (AWS CodeBuild Console)

The graphs in the AWS CodeBuild console show three days of metrics. You cannot customize the metrics or the graphs used to display them. Use the Amazon CloudWatch console to view your build metrics if you want to edit them.

To access AWS account level metrics

  1. Sign in to the AWS Management Console and open the AWS CodeBuild console at https://console.aws.amazon.com/codesuite/codebuild/home.

  2. In the navigation pane, choose Account metrics.

To access project-level metrics

  1. Sign in to the AWS Management Console and open the AWS CodeBuild console at https://console.aws.amazon.com/codesuite/codebuild/home.

  2. In the navigation pane, choose Build projects.

  3. In the list of build projects, in the Name column, choose the project where you want to view metrics.

  4. Choose the Metrics tab.

Access Build Metrics (Amazon CloudWatch Console)

You can customize the metrics and the graphs used to display them.

To access account level metrics

  1. Sign in to the AWS Management Console and open the CloudWatch console at https://console.aws.amazon.com/cloudwatch/.

  2. In the navigation pane, choose Metrics.

  3. On the All metrics tab, choose CodeBuild.

  4. Choose Account Metrics.

  5. Choose one or more projects and metrics. For each project, you can choose the SucceededBuilds, FailedBuilds, Builds, and Duration metrics. All selected project and metric combinations are displayed in the graph on the page.

To access project-level metrics

  1. Sign in to the AWS Management Console and open the CloudWatch console at https://console.aws.amazon.com/cloudwatch/.

  2. In the navigation pane, choose Metrics.

  3. On the All metrics tab, choose CodeBuild.

  4. Choose By Project.

  5. Choose one or more project and metric combinations. For each project, you can choose the SucceededBuilds, FailedBuilds, Builds, and Duration metrics. All selected project and metric combinations are displayed in the graph on the page.

  6. (Optional) You can customize your metrics and graphs. For example, from the drop-down list in the Statistic columm, you can choose a different statistic to display. Or from the drop-down menu in the Period column, you can choose a different time period to use to monitor the metrics. For more information, see Graph Metrics and View Available Metrics in the Amazon CloudWatch User Guide.