deregisterScalableTarget

Deregisters an Application Auto Scaling scalable target when you have finished using it. To see which resources have been registered, use DescribeScalableTargets.

Deregistering a scalable target deletes the scaling policies and the scheduled actions that are associated with it.

Samples

import aws.sdk.kotlin.services.applicationautoscaling.model.ScalableDimension
import aws.sdk.kotlin.services.applicationautoscaling.model.ServiceNamespace

fun main() { 
   //sampleStart 
   // This example deregisters a scalable target for an Amazon ECS service called web app that is running
// in the default cluster.
val resp = applicationAutoScalingClient.deregisterScalableTarget {
    serviceNamespace = ServiceNamespace.fromValue("ecs")
    resourceId = "service/default/web-app"
    scalableDimension = ScalableDimension.fromValue("ecs:service:DesiredCount")
} 
   //sampleEnd
}