Application Auto Scaling
AWS Application Auto Scaling — scalable targets, step / target-tracking / predictive policies, scheduled actions, scaling activities, predictive forecasts, tags. JSON 1.1 protocol.
fakecloud implements AWS Application Auto Scaling's full JSON 1.1 control plane: 14 operations covering scalable targets, scaling policies, scheduled actions, scaling activities, predictive forecasts, and tags. 100% Smithy conformance.
Status: 100% control-plane coverage.
Supported today
- Scalable targets —
RegisterScalableTargetacceptsServiceNamespace,ResourceId,ScalableDimension,MinCapacity,MaxCapacity,RoleARN,SuspendedState. Re-registering an existing target only patches the supplied fields (PUT-merge).RoleARNdefaults to the per-namespace service-linked role ARN (e.g.AWSServiceRoleForApplicationAutoScaling_ECSService).DescribeScalableTargetsfilters byServiceNamespace+ResourceIds+ScalableDimensionwithMaxResults+NextTokenpagination.DeregisterScalableTargetcascades: anyScalingPolicyorScheduledActionfor the same target is removed, so test state stays consistent. Supported namespaces includeecs,lambda,dynamodb,rds,elasticache,sagemaker,elasticmapreduce,appstream,cassandra,kafka,neptune,ec2,comprehend. - Scaling policies —
PutScalingPolicyacceptsPolicyName+PolicyType(StepScaling/TargetTrackingScaling/PredictiveScaling) and stores the corresponding configuration verbatim (round-tripped throughDescribeScalingPolicies). Returns a deterministicPolicyARNand an emptyAlarmslist. Without a registered scalable target, returnsObjectNotFoundException.DescribeScalingPoliciesfilters byPolicyNames/ResourceId/ScalableDimensionand paginates.DeleteScalingPolicyremoves by name + target tuple. - Scheduled actions —
PutScheduledActionacceptsSchedule(at(...)/rate(...)/cron(...)),Timezone,StartTime,EndTime,ScalableTargetAction(MinCapacity/MaxCapacity). Existing actions PUT-merge supplied fields.DescribeScheduledActionspaginates, filters by names + target.DeleteScheduledActionremoves by name + target tuple. Targets must already be registered. - Scaling activities —
DescribeScalingActivitiesreturns the per-target activity log newest-first withIncludeNotScaledActivitiesfiltering (default suppressesFailed). - Predictive scaling forecast —
GetPredictiveScalingForecastrequires the policy to bePolicyType = PredictiveScaling(otherwiseValidationException), then returns deterministic hourly Load + Capacity buckets betweenStartTimeandEndTimecapped at one week. Values are computed from the hour-of-day so tests can assert specific points. - Tags —
TagResourceupserts tag pairs keyed byResourceARN,UntagResourceremoves byTagKeys,ListTagsForResourcereturns the current tag map. Unknown ARNs returnObjectNotFoundException.
Smoke test
fakecloud &
aws --endpoint-url http://localhost:4566 application-autoscaling register-scalable-target \
--service-namespace ecs \
--resource-id service/cluster/api \
--scalable-dimension ecs:service:DesiredCount \
--min-capacity 1 --max-capacity 10
aws --endpoint-url http://localhost:4566 application-autoscaling put-scaling-policy \
--service-namespace ecs \
--resource-id service/cluster/api \
--scalable-dimension ecs:service:DesiredCount \
--policy-name scale-out \
--policy-type TargetTrackingScaling \
--target-tracking-scaling-policy-configuration '{
"TargetValue": 70.0,
"PredefinedMetricSpecification": {"PredefinedMetricType": "ECSServiceAverageCPUUtilization"}
}'
aws --endpoint-url http://localhost:4566 application-autoscaling describe-scaling-policies \
--service-namespace ecsCaveats
fakecloud does not actually scale anything. PutScalingPolicy and PutScheduledAction store configurations verbatim and return them on Describe*, but no metric is collected, no alarm is created, and ECS task counts / Lambda concurrency / DynamoDB capacity are never adjusted. Predictive forecasts are deterministic synthetic curves, not actual ML predictions — useful for asserting your code reads the response shape correctly, not for any business logic. Scaling activities are an in-memory log seeded by the service itself; fakecloud doesn't emit any. CloudWatch alarms reported under ScalingPolicy.Alarms are always empty.