Class CloudWatchAgentIntegrationProps.Builder
java.lang.Object
software.amazon.awscdk.services.applicationsignals.alpha.CloudWatchAgentIntegrationProps.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CloudWatchAgentIntegrationProps>
- Enclosing interface:
CloudWatchAgentIntegrationProps
@Stability(Experimental)
public static final class CloudWatchAgentIntegrationProps.Builder
extends Object
implements software.amazon.jsii.Builder<CloudWatchAgentIntegrationProps>
A builder for
CloudWatchAgentIntegrationProps-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionagentConfig(String agentConfig) Sets the value ofCloudWatchAgentOptions.getAgentConfig()build()Builds the configured instance.containerName(String containerName) Sets the value ofCloudWatchAgentOptions.getContainerName()Sets the value ofCloudWatchAgentOptions.getCpu()enableLogging(Boolean enableLogging) Sets the value ofCloudWatchAgentOptions.getEnableLogging()Sets the value ofCloudWatchAgentOptions.getEssential()memoryLimitMiB(Number memoryLimitMiB) Sets the value ofCloudWatchAgentOptions.getMemoryLimitMiB()memoryReservationMiB(Number memoryReservationMiB) Sets the value ofCloudWatchAgentOptions.getMemoryReservationMiB()operatingSystemFamily(OperatingSystemFamily operatingSystemFamily) Sets the value ofCloudWatchAgentOptions.getOperatingSystemFamily()portMappings(List<? extends PortMapping> portMappings) Sets the value ofCloudWatchAgentOptions.getPortMappings()taskDefinition(TaskDefinition taskDefinition) Sets the value ofCloudWatchAgentIntegrationProps.getTaskDefinition()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
taskDefinition
@Stability(Experimental) public CloudWatchAgentIntegrationProps.Builder taskDefinition(TaskDefinition taskDefinition) Sets the value ofCloudWatchAgentIntegrationProps.getTaskDefinition()- Parameters:
taskDefinition- The task definition to integrate CloudWatch agent into. This parameter is required. [disable-awslint:ref-via-interface]- Returns:
this
-
containerName
@Stability(Experimental) public CloudWatchAgentIntegrationProps.Builder containerName(String containerName) Sets the value ofCloudWatchAgentOptions.getContainerName()- Parameters:
containerName- Name of the CloudWatch Agent container. This parameter is required.- Returns:
this
-
agentConfig
@Stability(Experimental) public CloudWatchAgentIntegrationProps.Builder agentConfig(String agentConfig) Sets the value ofCloudWatchAgentOptions.getAgentConfig()- Parameters:
agentConfig- Custom agent configuration in JSON format.- Returns:
this
-
cpu
Sets the value ofCloudWatchAgentOptions.getCpu()- Parameters:
cpu- The minimum number of CPU units to reserve for the container.- Returns:
this
-
enableLogging
@Stability(Experimental) public CloudWatchAgentIntegrationProps.Builder enableLogging(Boolean enableLogging) Sets the value ofCloudWatchAgentOptions.getEnableLogging()- Parameters:
enableLogging- Whether to enable logging for the CloudWatch Agent.- Returns:
this
-
essential
@Stability(Experimental) public CloudWatchAgentIntegrationProps.Builder essential(Boolean essential) Sets the value ofCloudWatchAgentOptions.getEssential()- Parameters:
essential- Start as an essential container.- Returns:
this
-
memoryLimitMiB
@Stability(Experimental) public CloudWatchAgentIntegrationProps.Builder memoryLimitMiB(Number memoryLimitMiB) Sets the value ofCloudWatchAgentOptions.getMemoryLimitMiB()- Parameters:
memoryLimitMiB- The amount (in MiB) of memory to present to the container.- Returns:
this
-
memoryReservationMiB
@Stability(Experimental) public CloudWatchAgentIntegrationProps.Builder memoryReservationMiB(Number memoryReservationMiB) Sets the value ofCloudWatchAgentOptions.getMemoryReservationMiB()- Parameters:
memoryReservationMiB- The soft limit (in MiB) of memory to reserve for the container.- Returns:
this
-
operatingSystemFamily
@Stability(Experimental) public CloudWatchAgentIntegrationProps.Builder operatingSystemFamily(OperatingSystemFamily operatingSystemFamily) Sets the value ofCloudWatchAgentOptions.getOperatingSystemFamily()- Parameters:
operatingSystemFamily- Operating system family for the CloudWatch Agent.- Returns:
this
-
portMappings
@Stability(Experimental) public CloudWatchAgentIntegrationProps.Builder portMappings(List<? extends PortMapping> portMappings) Sets the value ofCloudWatchAgentOptions.getPortMappings()- Parameters:
portMappings- The port mappings to add to the container definition.- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<CloudWatchAgentIntegrationProps>- Returns:
- a new instance of
CloudWatchAgentIntegrationProps - Throws:
NullPointerException- if any required attribute was not provided
-