Introduction

Getting started with Judoscale on Amazon ECS (AWS)

Judoscale brings fast, reliable autoscaling to your Amazon ECS services. Once connected, Judoscale continuously monitors your workloads and automatically adjusts your ECS tasks to keep performance smooth without wasting money on over-provisioning.

There are two ways to set up the integration, and you can pick whichever fits your workflow best:

  • CloudFormation – The fastest way to get started. Launch our ready-to-go template in your AWS account, no extra tooling required.
  • Terraform – Perfect if your team manages infrastructure as code. Just add our configuration and terraform apply.

Prerequisites

Before you dive in, make sure you’ve got:

  • An AWS account with permissions to create ECS services and IAM roles.
  • An existing ECS cluster.
  • A Judoscale account (sign up for free).

Connect your AWS account to Judoscale

Choose your path to get started:

Migrating from Heroku to ECS

Every team / platform integration is managed on its own, so anything you do on your Heroku setup is completely independent from your ECS (or other platform) setup. Create a new ECS team tied to your AWS account, then link your clusters and services as Judoscale apps.

We usually suggest starting fresh because your ECS services may be shaped differently than your Heroku process types, and you may need slightly tweaked autoscale ranges once the app is running on a new platform. You can keep the Heroku add-ons installed but disable autoscaling if you want to refer back to them while configuring the ECS services.

If you prefer to automate the settings migration, contact us once the ECS services are linked. We can help you use the API to fetch settings from the source Heroku app and apply them to the matching ECS services, but you’ll still need to map each Heroku process type to its ECS service yourself.

Migrating ECS clusters

You can link multiple ECS clusters to the same Judoscale team as long as they’re in the same AWS account. If you’re moving services between clusters during a VPC or infrastructure migration, link the new cluster to the existing team and set up autoscaling for the new services before your cutover.

If the migration means you’ll temporarily run both the old and new clusters at the same time, you may exceed your normal task limit. Contact support with the Judoscale team that’s impacted and the timeframe for your migration. We’ll raise your limits so you can proceed with the migration.

If the new cluster is in a different AWS account, create a separate Judoscale team for that account.

Complete the setup

You can scale on a schedule without installing anything into your application, but metrics-based autoscaling will require one of our Judoscale packages. The app will walk you through the installation, and you can find more information for your stack in the links below:

👀 Note

Judoscale currently supports metrics-based autoscaling for Ruby, Python, Node, and Java. Want to use Judoscale with another stack? Let us know!

ECS (specifically Amazon’s load balancers) doesn’t expose the X-Request-Start header that’s required for measuring request queue time. If your web service is currently using utilization and you want to switch it to queue time, add an NGINX sidecar first so Judoscale can collect queue time metrics.

After queue time metrics are flowing, go through the Setup flow again for that ECS service to switch or select the metrics you want to autoscale with. This is especially important when you first configured the service before adding X-Request-Start; Judoscale may be receiving queue time data, but the service still needs queue time selected for autoscaling.

✅ Tip

If you can’t run the sidecar yet, switch your web autoscaling metric to utilization so you can still see data in the UI. Queue time is more consistent, but utilization is a better fallback than CPU or memory.

Autoscaling!

Once you have metrics flowing into Judoscale, you’re ready to autoscale! The default configuration is usually a great place to start, and you can turn on autoscaling with “one click” 😁.

screenshot of autoscale toggle in Judoscale

👀 Note

Unlike Heroku, Amazon ECS doesn’t expose real-time webhooks when you change a service’s task count. Judoscale fetches the current scale on a regular cadence (and every time we trigger an autoscale event or you load the dashboard), so expect a short delay before manual changes in AWS are reflected in the app.

For a full tour of the available charts and configuration options, use the links below: