java.lang.Object
java.lang.Enum<ServiceNamespace>
software.amazon.awscdk.services.applicationautoscaling.ServiceNamespace
All Implemented Interfaces:
Serializable, Comparable<ServiceNamespace>, java.lang.constant.Constable

@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)", date="2023-06-19T16:30:37.375Z") @Stability(Stable) public enum ServiceNamespace extends Enum<ServiceNamespace>
The service that supports Application AutoScaling.

Example:

 import software.amazon.awscdk.services.lambda.*;
 Code code;
 Function handler = Function.Builder.create(this, "MyFunction")
         .runtime(Runtime.PYTHON_3_7)
         .handler("index.handler")
         .code(code)
         .reservedConcurrentExecutions(2)
         .build();
 Version fnVer = handler.getCurrentVersion();
 ScalableTarget target = ScalableTarget.Builder.create(this, "ScalableTarget")
         .serviceNamespace(ServiceNamespace.LAMBDA)
         .maxCapacity(100)
         .minCapacity(10)
         .resourceId(String.format("function:%s:%s", handler.getFunctionName(), fnVer.getVersion()))
         .scalableDimension("lambda:function:ProvisionedConcurrency")
         .build();
 target.scaleToTrackMetric("PceTracking", BasicTargetTrackingScalingPolicyProps.builder()
         .targetValue(0.9)
         .predefinedMetric(PredefinedMetric.LAMBDA_PROVISIONED_CONCURRENCY_UTILIZATION)
         .build());
 
  • Enum Constant Details

    • ECS

      @Stability(Stable) public static final ServiceNamespace ECS
      Elastic Container Service.
    • ELASTIC_MAP_REDUCE

      @Stability(Stable) public static final ServiceNamespace ELASTIC_MAP_REDUCE
      Elastic Map Reduce.
    • EC2

      @Stability(Stable) public static final ServiceNamespace EC2
      Elastic Compute Cloud.
    • APPSTREAM

      @Stability(Stable) public static final ServiceNamespace APPSTREAM
      App Stream.
    • DYNAMODB

      @Stability(Stable) public static final ServiceNamespace DYNAMODB
      Dynamo DB.
    • RDS

      @Stability(Stable) public static final ServiceNamespace RDS
      Relational Database Service.
    • SAGEMAKER

      @Stability(Stable) public static final ServiceNamespace SAGEMAKER
      SageMaker.
    • CUSTOM_RESOURCE

      @Stability(Stable) public static final ServiceNamespace CUSTOM_RESOURCE
      Custom Resource.
    • LAMBDA

      @Stability(Stable) public static final ServiceNamespace LAMBDA
      Lambda.
    • COMPREHEND

      @Stability(Stable) public static final ServiceNamespace COMPREHEND
      Comprehend.
    • KAFKA

      @Stability(Stable) public static final ServiceNamespace KAFKA
      Kafka.
    • ELASTICACHE

      @Stability(Stable) public static final ServiceNamespace ELASTICACHE
      ElastiCache.
  • Method Details

    • values

      public static ServiceNamespace[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static ServiceNamespace valueOf(String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum type has no constant with the specified name
      NullPointerException - if the argument is null