AWS Fargate
Required AWS Fargate Attributes
The following cost calculation tags are required for traces originating from AWS Fargate tasks.
Always Required Fields
These fields are always required for AWS Fargate cost calculation:
| Attribute Name | Example Value | Allowed Values |
|---|---|---|
cloud.platform | aws_ecs | aws_ecs |
aws.ecs.launchtype | fargate | fargate |
aws.ecs.task.arn | arn:aws:ecs:us-east-1:123456789:task/cluster/taskid | Valid ECS task ARN |
aws.ecs.task.cpu | 1024 | CPU units (1024 = 1 vCPU) |
aws.ecs.task.memory | 2048 | Memory in MiB |
Optional Fields
These fields are extracted if present but are not required for cost calculation:
| Attribute Name | Example Value | Allowed Values | Default |
|---|---|---|---|
os.type | linux | linux, windows | linux |
aws.ecs.task.cpu_architecture | X86_64 | X86_64, ARM64 | X86_64 |
aws.ecs.task.capacity_provider | FARGATE | FARGATE, FARGATE_SPOT | FARGATE |
Required for CUR Cost Finalization
Costs calculated from the tags above are provisional — estimated from list prices. When you connect your AWS Cost and Usage Report (CUR), Beakpoint Insights replaces provisional costs with your actual billed costs by matching spans to CUR line items. That matching requires one additional tag:
| Attribute Name | Example Value | Allowed Values |
|---|---|---|
cloud.resource_id | arn:aws:ecs:us-east-1:123456789012:task/my-cluster/abc123 | The full ECS task ARN |
cloud.resource_id should be set as an OpenTelemetry resource attribute. Spans sent directly via OTLP will not match your CUR data if the tag only appears at the span level, and their costs will remain provisional indefinitely. (Traces imported from AWS X-Ray have span-level values promoted automatically, but do not rely on this.)
Cost Calculation
Fargate charges separately for vCPU and memory. Beakpoint calculates cost based on span duration:
cost = (cpu_units / 1024) × vCPU_hourly_rate × duration_hours
+ (memory_MiB / 1024) × memory_hourly_rate × duration_hours
The region is extracted from the task ARN. When multiple spans overlap on the same task (identified by aws.ecs.task.arn), costs are proportionally shared using a time-sharing algorithm. Spans on different tasks are priced independently.
Example Configuration
Set these as OpenTelemetry resource attributes in your application:
OTEL_RESOURCE_ATTRIBUTES: "cloud.platform=aws_ecs,aws.ecs.launchtype=fargate,aws.ecs.task.arn=arn:aws:ecs:us-east-1:123456789:task/my-cluster/abc123,aws.ecs.task.cpu=1024,aws.ecs.task.memory=2048,os.type=linux,aws.ecs.task.cpu_architecture=X86_64,aws.ecs.task.capacity_provider=FARGATE"