Class QueueProcessingServiceBase

java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.services.ecs.patterns.QueueProcessingServiceBase
All Implemented Interfaces:
software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IDependable
Direct Known Subclasses:
QueueProcessingEc2Service, QueueProcessingFargateService

@Generated(value="jsii-pacmak/1.104.0 (build e79254c)", date="2024-11-27T16:50:57.203Z") @Stability(Stable) public abstract class QueueProcessingServiceBase extends software.constructs.Construct
The base class for QueueProcessingEc2Service and QueueProcessingFargateService services.
  • Nested Class Summary

    Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject

    software.amazon.jsii.JsiiObject.InitializationMode

    Nested classes/interfaces inherited from interface software.constructs.IConstruct

    software.constructs.IConstruct.Jsii$Default
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    QueueProcessingServiceBase(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
     
    protected
    QueueProcessingServiceBase(software.amazon.jsii.JsiiObjectRef objRef)
     
    protected
    QueueProcessingServiceBase(software.constructs.Construct scope, String id, QueueProcessingServiceBaseProps props)
    Constructs a new instance of the QueueProcessingServiceBase class.
  • Method Summary

    Modifier and Type
    Method
    Description
    protected void
    Configure autoscaling based off of CPU utilization as well as the number of messages visible in the SQS queue.
    The cluster where your service will be deployed.
    The dead letter queue for the primary SQS queue.
    protected Cluster
    getDefaultCluster(software.constructs.Construct scope)
    Returns the default cluster.
    protected Cluster
    getDefaultCluster(software.constructs.Construct scope, IVpc vpc)
    Returns the default cluster.
    Environment variables that will include the queue name.
    The AwsLogDriver to use for logging if logging is enabled.
    The maximum number of instances for autoscaling to scale up to.
    The minimum number of instances for autoscaling to scale down to.
    The scaling interval for autoscaling based off an SQS Queue size.
    The secret environment variables.
    The SQS queue that the service will process from.
    protected void
    Grant SQS permissions to an ECS service.

    Methods inherited from class software.constructs.Construct

    getNode, isConstruct, toString

    Methods inherited from class software.amazon.jsii.JsiiObject

    jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

    Methods inherited from interface software.amazon.jsii.JsiiSerializable

    $jsii$toJson
  • Constructor Details

    • QueueProcessingServiceBase

      protected QueueProcessingServiceBase(software.amazon.jsii.JsiiObjectRef objRef)
    • QueueProcessingServiceBase

      protected QueueProcessingServiceBase(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
    • QueueProcessingServiceBase

      @Stability(Stable) protected QueueProcessingServiceBase(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull QueueProcessingServiceBaseProps props)
      Constructs a new instance of the QueueProcessingServiceBase class.

      Parameters:
      scope - This parameter is required.
      id - This parameter is required.
      props - This parameter is required.
  • Method Details

    • configureAutoscalingForService

      @Stability(Stable) protected void configureAutoscalingForService(@NotNull BaseService service)
      Configure autoscaling based off of CPU utilization as well as the number of messages visible in the SQS queue.

      Parameters:
      service - the ECS/Fargate service for which to apply the autoscaling rules to. This parameter is required.
    • getDefaultCluster

      @Stability(Stable) @NotNull protected Cluster getDefaultCluster(@NotNull software.constructs.Construct scope, @Nullable IVpc vpc)
      Returns the default cluster.

      Parameters:
      scope - This parameter is required.
      vpc -
    • getDefaultCluster

      @Stability(Stable) @NotNull protected Cluster getDefaultCluster(@NotNull software.constructs.Construct scope)
      Returns the default cluster.

      Parameters:
      scope - This parameter is required.
    • grantPermissionsToService

      @Stability(Stable) protected void grantPermissionsToService(@NotNull BaseService service)
      Grant SQS permissions to an ECS service.

      Parameters:
      service - the ECS/Fargate service to which to grant SQS permissions. This parameter is required.
    • getCluster

      @Stability(Stable) @NotNull public ICluster getCluster()
      The cluster where your service will be deployed.
    • getEnvironment

      @Stability(Stable) @NotNull public Map<String,String> getEnvironment()
      Environment variables that will include the queue name.
    • getMaxCapacity

      @Stability(Stable) @NotNull public Number getMaxCapacity()
      The maximum number of instances for autoscaling to scale up to.
    • getMinCapacity

      @Stability(Stable) @NotNull public Number getMinCapacity()
      The minimum number of instances for autoscaling to scale down to.
    • getScalingSteps

      @Stability(Stable) @NotNull public List<ScalingInterval> getScalingSteps()
      The scaling interval for autoscaling based off an SQS Queue size.
    • getSqsQueue

      @Stability(Stable) @NotNull public IQueue getSqsQueue()
      The SQS queue that the service will process from.
    • getDeadLetterQueue

      @Stability(Stable) @Nullable public IQueue getDeadLetterQueue()
      The dead letter queue for the primary SQS queue.
    • getLogDriver

      @Stability(Stable) @Nullable public LogDriver getLogDriver()
      The AwsLogDriver to use for logging if logging is enabled.
    • getSecrets

      @Stability(Stable) @Nullable public Map<String,Secret> getSecrets()
      The secret environment variables.