enum ServiceConnectAccessLogFormat
| Language | Type name |
|---|---|
.NET | Amazon.CDK.AWS.ECS.ServiceConnectAccessLogFormat |
Go | github.com/aws/aws-cdk-go/awscdk/v2/awsecs#ServiceConnectAccessLogFormat |
Java | software.amazon.awscdk.services.ecs.ServiceConnectAccessLogFormat |
Python | aws_cdk.aws_ecs.ServiceConnectAccessLogFormat |
TypeScript (source) | aws-cdk-lib » aws_ecs » ServiceConnectAccessLogFormat |
The format of Service Connect access logs.
Example
declare const cluster: ecs.Cluster;
declare const taskDefinition: ecs.TaskDefinition;
const service = new ecs.FargateService(this, 'Service', {
cluster,
taskDefinition,
serviceConnectConfiguration: {
services: [
{
portMappingName: 'api',
},
],
accessLogConfiguration: {
format: ecs.ServiceConnectAccessLogFormat.JSON,
includeQueryParameters: true,
},
// When configuring access log,
// you also need to configure the log driver accordingly.
logDriver: ecs.LogDrivers.awsLogs({
streamPrefix: 'prefix',
}),
},
});
Members
| Name | Description |
|---|---|
| TEXT | Human-readable text format for access logs. |
| JSON | Structured JSON format for access logs. |
TEXT
Human-readable text format for access logs.
JSON
Structured JSON format for access logs.
This format is well-suited for integration with log analysis tools.

.NET
Go
Java
Python
TypeScript (