---
title: AWS App Mesh
description: Amazon App Mesh is an open source edge and service proxy.
breadcrumbs: Docs > Integrations > AWS App Mesh
---

# AWS App Mesh
Integration version1.0.0
## Overview{% #overview %}

[AWS App Mesh](https://docs.datadoghq.com/integrations/ecs_fargate.md#log-collection) is a service mesh that provides application-level networking to your micro services running on Amazon ECS Fargate or Amazon EKS clusters.

**Minimum Agent version:** 6.15.0

## Setup{% #setup %}

{% tab title="EKS" %}
Use the instructions below to enable metric collection for the AWS App Mesh proxy sidecar, called Envoy. Users can choose to add sidecars in one of three modes: deploying, patching the deployment later, or using the AWS App Mesh injector controller. All modes are supported by the following steps.

#### Metric collection{% #metric-collection %}

**Prerequisite**: Deploy Datadog Agents as a DaemonSet in your Kubernetes cluster using the [EKS integration](https://docs.datadoghq.com/integrations/ecs_fargate.md#log-collection) documentation.

1. Due to limitations in App Mesh, forwarding metrics from EKS to Datadog requires the Egress filter to be set to `Allow External Traffic`.

1. Create a ConfigMap in your cluster to automatically discover App Mesh's Envoy side cars that are added to each pod:

   ```yaml
     apiVersion: v1
     kind: ConfigMap
     metadata:
     name: datadog-config
     data:
     envoy: |-
       ad_identifiers:
       - aws-appmesh-envoy
       init_config:
       instances:
       - stats_url: http://%%host%%:9901/stats
         tags:
           - <TAG_KEY>:<TAG_VALUE>  # Example - cluster:eks-appmesh
   ```

1. Update the `volumeMounts` object in your Datadog Agent's DaemonSet YAML file:

   ```yaml
         volumeMounts:
          - name: datadog-config
            mountPath: /conf.d
   ```

1. Update the `volumes` object in your Datadog Agent's DaemonSet YAML file:

   ```yaml
        volumes:
         - name: datadog-config
           configMap:
             name: datadog-config
             items:
             - key: envoy
               path: envoy.yaml
   ```

#### Log collection{% #log-collection %}

{% callout %}
# Important note for users on the following Datadog sites: us3.datadoghq.com

Log collection is not supported for this site.
{% /callout %}

{% callout %}
# Important note for users on the following Datadog sites: app.datadoghq.com, app.datadoghq.eu, app.ddog-gov.com

To enable log collection, update the Agent's DaemonSet with the dedicated [Kubernetes log collection instructions](https://docs.datadoghq.com/integrations/ecs_fargate.md#log-collection).
{% /callout %}

#### Trace collection{% #trace-collection %}

Select the namespace to deploy the `datadog-agent` and service, for example: `monitoring`. Use this in the option to deploy the appmesh-injector with:

```shell
  helm upgrade -i appmesh-controller eks/appmesh-controller \
  --namespace appmesh-system \
  --set sidecar.logLevel=debug \
  --set tracing.enabled=true \
  --set tracing.provider=datadog \
  --set tracing.address=ref:status.hostIP \
  --set tracing.port=8126
```

Alternatively, the appmesh injector can be deployed by following the [App Mesh with EKS](https://github.com/aws/aws-app-mesh-examples/blob/master/walkthroughs/eks/base.md#install-app-mesh--kubernetes-components) documentation using the option `enable-datadog-tracing=true` or environment variable `ENABLE_DATADOG_TRACING=true`.
{% /tab %}

{% tab title="ECS Fargate" %}
#### Metric collection{% #metric-collection %}

**Prerequisite**: Add Datadog Agents to each of your Fargate task definitions with App Mesh enabled, such as an Envoy sidecar injected, using the [ECS Fargate integration](https://docs.datadoghq.com/integrations/ecs_fargate.md#log-collection) documentation.

1. Due to limitations in App Mesh, forwarding metrics from an ECS task to Datadog requires the Egress filter to be set to `Allow External Traffic`.

1. Update all task definitions containing the Envoy sidecar and Datadog Agent with the following Docker labels. See [Integration Setup for ECS Fargate](https://app.datadoghq.com/agent/kubernetes/daemonset_setup/#log-collection) for details.

   ```text
       "dockerLabels": {
             com.datadoghq.ad.instances : [{"stats_url": "http://%%host%%:9901/stats"}]
             com.datadoghq.ad.check_names : ["envoy"]
             com.datadoghq.ad.init_configs : [{}]
           },
   ```

#### Log collection{% #log-collection %}

{% callout %}
# Important note for users on the following Datadog sites: us3.datadoghq.com

Log collection is not supported for this site.
{% /callout %}

{% callout %}
# Important note for users on the following Datadog sites: app.datadoghq.com, app.datadoghq.eu, app.ddog-gov.com

Enable log collection with the instructions in the [ECS Fargate integration documentation](https://docs.datadoghq.com/integrations/ecs_fargate.md#log-collection).
{% /callout %}

#### Trace collection{% #trace-collection %}

1. Enable trace collection with the instructions in the [ECS Fargate integration](https://docs.datadoghq.com/integrations/ecs_fargate.md#trace-collection) documentation.

Set the AWS App Mesh parameters `ENABLE_ENVOY_DATADOG_TRACING` and `DATADOG_TRACER_PORT` as environment variables in the ECS Fargate task definition. Learn more in the [AWS App Mesh](https://docs.aws.amazon.com/app-mesh/latest/userguide/envoy.html) documentation.
{% /tab %}

{% tab title="ECS EC2" %}
#### Metric collection{% #metric-collection %}

**Prerequisite**: Add Datadog Agents to each of your ECS EC2 task definitions with App Mesh enabled, such as an Envoy sidecar injected, using the [ECS integration](https://docs.datadoghq.com/integrations/ecs_fargate.md#log-collection) documentation.

1. Due to limitations in App Mesh, forwarding metrics from an ECS task to Datadog requires the Egress filter to be set to `Allow External Traffic`.

1. Update all task definitions containing the Envoy sidecar and Datadog Agent with the following Docker labels. See [Integration Setup for ECS Fargate](https://app.datadoghq.com/agent/kubernetes/daemonset_setup/#log-collection) for details.

   ```text
       "dockerLabels": {
             com.datadoghq.ad.instances : [{"stats_url": "http://%%host%%:9901/stats"}]
             com.datadoghq.ad.check_names : ["envoy"]
             com.datadoghq.ad.init_configs : [{}]
           },
   ```

#### Log collection{% #log-collection %}

{% callout %}
# Important note for users on the following Datadog sites: us3.datadoghq.com

Log collection is not supported for this site.
{% /callout %}

{% callout %}
# Important note for users on the following Datadog sites: app.datadoghq.com, app.datadoghq.eu, app.ddog-gov.com

Enable log collection with the instructions in the [ECS integration documentation](https://docs.datadoghq.com/integrations/ecs_fargate.md#log-collection).
{% /callout %}

#### Trace collection{% #trace-collection %}

1. Enable trace collection with the instructions in the [ECS integration](https://docs.datadoghq.com/integrations/ecs_fargate.md#trace-collection) documentation.

1. Set the AWS App Mesh parameters `ENABLE_ENVOY_DATADOG_TRACING` and `DATADOG_TRACER_PORT` as environment variables in the ECS task definition. Learn more in the [AWS App Mesh](https://docs.aws.amazon.com/app-mesh/latest/userguide/envoy.html) documentation.

{% /tab %}

## Data Collected{% #data-collected %}

### Metrics{% #metrics %}

See the [Envoy integration](https://app.datadoghq.com/agent/kubernetes/daemonset_setup/#log-collection) for a list of metrics.

### Events{% #events %}

The AWS App Mesh integration does not include any events.

### Service Checks{% #service-checks %}

The AWS App Mesh integration does not include any service checks.

## Troubleshooting{% #troubleshooting %}

Need help? Contact [Datadog support](https://github.com/aws/aws-app-mesh-examples/blob/master/walkthroughs/eks/base.md#install-app-mesh--kubernetes-components).

## Further Reading{% #further-reading %}

- [Envoy](https://docs.datadoghq.com/integrations/envoy.md)
