Steve Commisso

Case study · Attentive

Black Friday 2025 at 62% less


Over Black Friday and Cyber Monday 2025, Attentive's EC2 spend fell 62.4% year over year while message volume grew 46.3%, saving about $340K in five days. Four changes were behind it: the Java and Spring modernization I led, autoscaling, hardened multi-arch images and Graviton.

Role
Principal Software Engineer; led the platform-wide Java and Spring modernization
When
2025
  • −62.4%EC2 spend, year over year
  • +46.3%message volume
  • $340Ksaved in five days, approximately
  • $9Mannual infrastructure savings contributed to

Problem


Attentive is an AI-powered SMS, email and push marketing platform for 8,000+ retail and e-commerce brands. Black Friday and Cyber Monday are its peak: the year's largest send volume, compressed into five days, for customers whose own revenue depends on those messages arriving.

At the start of 2025 the platform under that peak was carrying several years of debt.

  • A Java fleet years behind

    Services ran Java 11 on Spring Boot 2. A move to Spring Boot 3 had been proposed in 2023 and had stalled.

  • An end-of-life base image

    Dozens of production services were built on an Ubuntu 20.04 image that reached end of life on May 31, 2025. Builds were single-stage, with minimal layer caching and base-image variants that differed from team to team.

  • x86 only

    Builds could not produce ARM64 images, which ruled out AWS Graviton.

The problem in one sentence: carry a much bigger peak without paying for it in x86, Java 11 era capacity, and without breaking anything in the most important week of the year.

Constraints


  • A hard deadline

    Everything had to be in place before the Black Friday code freeze.

  • More than 200 services, none of them mine

    Each service belonged to a product team with its own roadmap, so every change had to be nearly free for that team to adopt. By the end I had worked with every engineering team in the company.

  • The riskiest possible timing

    We were changing the runtime, the operating system and the CPU architecture ahead of the highest-traffic week of the year.

  • A dependency on another team

    The Spring Boot upgrade was blocked on another team's stream-processing upgrade.

  • Back to Java after twenty years

    I hadn't written Java in more than 20 years when I joined Attentive.

Approach & architecture


Four changes produced the result together. I led the Java and Spring Boot modernization and built the hardened multi-arch images. Autoscaling and Graviton were done with the infrastructure team, who tuned the autoscaler with me and ran the Graviton migration.

Four levers

  • Java and Spring Boot

    Java 11 / Spring Boot 2 → Java 25 / Spring Boot 3.4+, platform-wide, in only 3 months.

  • Autoscaling

    Services that start faster and use less memory can go on the Kubernetes Horizontal Pod Autoscaler, so capacity follows traffic instead of sitting at peak size.

  • Hardened multi-arch images

    Docker Hardened Images on an Amazon Corretto base, built multi-stage for AMD64 and ARM64, in place of the end-of-life Ubuntu image.

  • AWS Graviton

    40% of the production workload moved to ARM64. My images made it possible and I pushed for it. The infrastructure team ran the migration.

Drawn as four equal levers. I do not have a split of the savings between them.

What the runtime upgrade bought

+79%throughput for a core feature-flag service, on the same autoscaling rules

The runtime changes showed up service by service. A core feature-flag service handled 79% more throughput on the same autoscaling rules once it was on Java 24 with virtual threads. A core identity service cut its p95 latency by 49% in a load test on Java 25, with virtual threads and compact object headers.

How it reached more than 200 services

The engineering was the smaller half of the problem. The larger half was getting changes into services I did not own without asking much of the teams that did. The rollout ran as a pipeline.

The rollout pipeline

  1. Prioritize

    • Rank services by EC2 expense, using Datadog and cloud-cost data.
    • The most expensive quarter of the fleet goes first.
  2. Automate

    • OpenRewrite recipes make the mechanical Java and Spring Boot changes.
    • The Spring Boot track is decoupled from another team's stream-processing upgrade.
    • Hardened base images are built for AMD64 and ARM64.
  3. Stage

    • Base images are opt-in behind a build flag: canary services first, then the default for everyone.
  4. Adopt

    • Each service gets a ready-made pull request. Its owners only have to validate.
    • One internal CLI command puts a service on the autoscaler and upgrades its Java.
  5. Lock in

    • The service-quality scorecard requires Spring Boot 3.4+.
    • The procedure is written up as a reusable platform-upgrade playbook.

The base-image change followed the same pattern on its own track: a two-day proof of concept, then canary services opting in with one build variable, then a flag flip that made hardened images the default. It took 10 to 15 lines in the base Dockerfile and went from proof of concept to production in six weeks, across more than 200 services, with no incidents.

The build pipeline, before and after

StageBeforeAfter
Base imageUbuntu 20.04, end of life May 31, 2025Docker Hardened Images, on Amazon Corretto
BuildSingle stageMulti-stage
Base-image CVEs0Critical0High29Medium21Low0Critical0High0Medium5Low
Runs onAMD64 onlyAMD64 and ARM64 (AWS Graviton)
Example image500 MB189 MB

Figures from the public whitepaper by Docker and Attentive. The image size is the whitepaper's example image.

Read the whitepaper: Building Faster, Securing Smarter

Results


Black Friday / Cyber Monday, 2024 to 2025

Chart with two lines that start at the same point, index 100, at Black Friday and Cyber Monday 2024. By the same five days in 2025, message volume has risen to 146.3, up 46.3%, and EC2 spend has fallen to 37.6, down 62.4%. About $340K was saved in those five days.

Indexed: Black Friday / Cyber Monday 2024 = 100. Each line has two measured points and nothing in between.

Over the five days of Black Friday and Cyber Monday 2025, Attentive sent 46.3% more messages than in the same five days of 2024 and spent 62.4% less on EC2. That is about $340K saved in five days. The comparison is EC2 spend only, year over year, because EC2 is the cost these changes act on.

  • +79%

    throughput for a core feature-flag service

  • −49%

    p95 latency for a core identity service

  • $189.82

    infrastructure cost per million messages, down from $309.98

  • 40%

    of the production workload on AWS Graviton

  • 12–15%

    production cost reduction from Graviton, per the whitepaper

  • 90%

    of base-image CVEs eliminated

  • 200+

    services on hardened images, with no incidents

  • $9M

    annual infrastructure savings this work contributed to

None of it was one person's saving. The result came from the four changes together, and other teams did essential parts of it: the infrastructure team tuned the autoscaler with me and ran the Graviton migration, and every service team validated its own upgrade.

Why it mattered


Attentive sent far more messages for far less compute in the week that matters most to its customers. Infrastructure cost per million messages went from $309.98 to $189.82.

It also paid down years of debt in one push. The fleet went from years behind to the current runtime. Java 25 had shipped only that September.

Security came along with it. The same base-image change removed an end-of-life operating system, eliminated 90% of the CVEs in our base images, and put an SBOM and signed provenance on every image.

The migration procedure is now a documented playbook that another team has since reused for a different upgrade, and the scorecards now require services to stay current.

Lessons


  1. Start with the most expensive services

    Upgrading the most expensive quarter of the fleet first put the savings where the money was. Early wins on core services then pulled other teams in.

  2. Make the upgrade almost no work for each team

    Ready-made pull requests, one base image for the fleet, feature flags, and a single command that does the autoscaler onboarding and the Java upgrade together. Adoption depended on how little each team had to do.

  3. Decouple dependencies instead of waiting on them

    I split the Spring Boot work from the stream-processing upgrade it was blocked on. When Gradle 9 broke other teams' data workflows, I got Java 25 running on Gradle 8 instead of forcing a risky upgrade just before the freeze.

  4. Do the heavy lifting in the proof of concept

    Because the hard problems were solved in the proof of concept, the rollout to more than 200 services was transparent to the product teams.

  5. Keep the fleet from sliding back

    Scorecards, and principles written into the design-review process, keep the fleet from sliding back to years behind.

2026

More to come.