Monitoring AWS AppSync

The AWS AppSync sensor is automatically deployed and installed after you install the Instana agent. You can view metrics that are related to AWS AppSync in the Instana UI.

For other supported AWS services, see the AWS topic.

Viewing metrics

To view the metrics, complete the following steps:

  1. In the sidebar of the Instana UI, select Infrastructure.
  2. Click a specific monitored AWS AppSync instance.

You can see an AWS AppSync dashboard with all the collected metrics.

Configuration data

The AWS AppSync sensor collects the following AppSync data:

  • ARN
  • Name
  • Region
  • API ID
  • API type
  • Authentication type
  • Visibility
  • Data sources

Metrics

The AWS AppSync sensor collects the following metrics:

Name Description
4xx Errors The number of errors that result from requests that are not valid due to an incorrect client configuration in a period.
5xx Errors The number of errors encountered during the running of a GraphQL query in a period.
Total Errors The total number of errors (4xx + 5xx) in a period.
Latency The average time between when AWS AppSync receives a request from a client and when it returns a response to the client.
Requests The total number of requests (queries + mutations) that all APIs in your account processed, by Region, in a period.
Tokens Consumed The total number of tokens allocated to requests processed in a particular Region in a period.
Connect Success The total number of successful WebSocket connections to AWS AppSync in a period.
Connect Client Error The number of WebSocket connections that were rejected by AWS AppSync because of client-side errors in a period.
Connect Server Error The number of errors that originated from AWS AppSync while connections are processed in a period.
Subscribe Success The number of subscriptions that are successfully registered to AWS AppSync through WebSocket in a period.
Subscribe Client Error The number of subscriptions that AWS AppSync rejected because of client-side errors in a period.
Subscribe Server Error The number of errors that originated from AWS AppSync while subscriptions are processed in a given period.
Publish Data Message Success The number of subscription event messages that are successfully published in a period.
Publish Data Message Client Error The number of subscription event messages that failed to publish because of client-side errors in a period.
Publish Data Message Server Error The number of errors that originated from AWS AppSync while subscription event messages are published in a period.
Publish Data Message Size The size of subscription event messages that are published in bytes.
Active Connections The number of concurrent WebSocket connections from clients to AWS AppSync in 1 minute.
Active Subscriptions The number of concurrent subscriptions from clients in 1 minute.
Connection Duration The average amount of time that the connection stays open.

Required permissions

The AWS AppSync sensor requires the following permissions:

  • cloudwatch:GetMetricData
  • cloudwatch:GetMetricStatistics
  • appsync:ListGraphqlApis
  • appsync:GetGraphqlApi
  • appsync:ListDataSources

Configuration

Metrics for AWS AppSync are pulled every 60 seconds. You can change this setting in the <agent_install_dir>/etc/instana/configuration.yml file:

com.instana.plugin.aws.appsync:
  cloudwatch_period: 60

To disable monitoring of AppSync instances, use the following configuration:

com.instana.plugin.aws.appsync:
  enabled: false

Enabling proxy configuration

To enable the AWS AppSync sensor to use the proxy configuration, add the following agent configuration settings:

com.instana.plugin.aws.appsync:
  proxy_host: 'example.com' # proxy host name or ip address
  proxy_port: 3128 # proxy port
  proxy_protocol: 'HTTP' # proxy protocol: HTTP or HTTPS
  proxy_username: 'username' # OPTIONAL: proxy username
  proxy_password: 'password' # OPTIONAL: proxy password

Monitoring multiple AWS accounts

To set up monitoring of multiple AWS accounts with one AWS agent in the same region, see the Monitoring multiple AWS accounts topic.

AWS-named profiles approach

To override which profiles are used to monitor AWS AppSync, use the following configuration:

com.instana.plugin.aws.appsync:
  profile_names:
    - 'profile2'
    - 'profile3'

If you define profiles on a service level, the global AWS profile configuration is overridden.

AWS STS approach

To override which IAM roles are used to monitor AppSync, use the following configuration:

com.instana.plugin.aws.appsync:
  role_arns:
    - 'arn:aws:iam::<account_1_id>:role/<role_1_name>'
    - 'arn:aws:iam::<account_2_id>:role/<role_2_name>'

If you define IAM roles on a service level, the global AWS IAM role configuration is overridden.

Filtering by defining tags

You can define multiple tags, each separated by a comma. Tags must be provided as a key-value pair. To make configuration easier, you can define which tags you want to include in discovery or exclude from discovery. If you define tag in both lists (include and exclude), the exclude list has a higher priority. If you don't need to filter services, you don't need to define the tags. It’s not mandatory to define all values to enable filtering.

You can specify how often sensors poll the AWS tagged resources by using the tagged-services-poll-rate configuration property. By default, the value is 300 seconds.

Tags are only available with the AWS agent.

To define how often sensors poll the tagged resources, use the following configuration:

com.instana.plugin.aws:
  tagged-services-poll-rate: 60 #default 300

To include services by tags into discovery, use the following configuration:

com.instana.plugin.aws.appsync:
  include_tags: # Comma separated list of tags in key:value format (e.g. env:prod,env:staging)

To exclude services by tags from discovery, use the following configuration:

com.instana.plugin.aws.appsync:
  exclude_tags: # Comma separated list of tags in key:value format (e.g. env:dev,env:test)

AWS services without tags are monitored by default, but can be excluded by setting the include_untagged field to false:

com.instana.plugin.aws.appsync:
  include_untagged: false # True value by default