Upgrade to Pro — share decks privately, control downloads, hide ads and more …

251102 Rethinking Serverless Application Workfl...

Avatar for Takumi Abe Takumi Abe
November 02, 2025

251102 Rethinking Serverless Application Workflows from a Testing Perspective

2025/11/02 (日) AWS Community Day 2025 Hong Kongにて発表した登壇資料。
https://awscommunity.hk/

Avatar for Takumi Abe

Takumi Abe

November 02, 2025
Tweet

More Decks by Takumi Abe

Other Decks in Technology

Transcript

  1. SPEAKER Takumi Abe JAWS-UG Oita, AWS Community Builder(Serverless) Where Ideas

    Meet Action Rethinking Serverless Application Workflows from a Testing Perspective
  2. Abetaku (Takumi Abe)
 {  "Community": [   "JAWS-UG Oita",   "AWS Community

    Builder(Serverless)",   "Fukuoka Cloud UG",   "Main Street revitalization in Oita, Japan."  ], "Company": "KDDI Agile Development Center", "Work": "Software Engineer",  "LinkdIn": "east-takumi" } }
  3. Agenda
 1. Context - Click-Through, Not Scripted 2. Try -

    Workflow Tests with SFN Local 3. Reflections - Rethinking from a testing perspective
  4. In My Project…
 • Develop a new batch process on

    a serverless architecture • A simple three-state Step Functions workflow (all Lambda) • Unit tests exist per state, but end-to-end state machine testing is manual with visual I/O verification. Context- Click-Through, Not Scripted

  5. In My Project…
 • Develop a new batch process on

    a serverless architecture • A simple three-state Step Functions workflow (all Lambda) • Unit tests exist per state, but end-to-end state machine testing is manual with visual I/O verification. Context- Click-Through, Not Scripted
 Wait—now I really want this automated.(^◇^;)

  6. Why no automation?
 • Team Context ◦ Limited serverless testing

    beyond UT (integration/E2E) • Project Context ◦ Serverless spec changes are expected to be rare Context- Click-Through, Not Scripted

  7. Development State & Requirements
 • Lambda + Step Functions, defined

    via AWS SAM • Workflow: 3 states in a straight line, all built as Lambda • Tests: for each state, assert that inputs/outputs contain the expected values, etc. • CI: self-contained in GitHub Actions (no deploy to AWS) Try - Workflow Tests with SFN Local

  8. Step Functions Local
 A local emulator (JAR/Docker) to run Step

    Functions on your machine.Integrations can hit mock responses, local endpoints, or real AWS. Try - Workflow Tests with SFN Local
 Source:DevelopersIO https://dev.classmethod.jp/articles/step-functions-local-tried/
  9. • Unsupported and not production-parity (dev only) ◦ Keep sensitive

    data out ◦ Low ops fidelity (IAM, CloudWatch etc.) • Prod use → LocalStack ◦ Recreates many AWS services—including Step Functions—in one local environment ◦ Easy to plug into CI ▪ →note that some features aren’t available for free. However…
 Try - Workflow Tests with SFN Local

  10. Why do we even need tests?
 • Understand to system

    behavior ◦ →Tests are tools for understanding • Build Trust through Reproducibility & Explainability • Grasp the Risks ◦ →If we can quantify the risk, can devise countermeasures Trust. Predict. Observe. The better the path, the more risk becomes visible and manageable. Reflections - Rethinking from a testing perspective
 https://www.amazon.co.jp/dp/B074BQQ96X?ref =ppx_yo2ov_dt_b_fed_digi_asin_title_351
  11. Design Tests: Layers × Boundaries
 • Different tests, different purposes

    ◦ Logic, contracts, connections, workflows, and user paths—each has its own test. • Boundaries ◦ Cut at observable units; the system explains itself ◦ Hard to test → Responsibility is piled up Reflections - Rethinking from a testing perspective

  12. Example
 Fetch/process data from an other server and upload results

    to DynamoDB
 Reflections - Rethinking from a testing perspective

  13. Tests as a Design Feedback Loop
 • Expose design weaknesses

    (concentrated responsibility, fuzzy boundaries, scattered side effects) • Enable fearless refactoring with an automated safety net • Shorten cycle time ◦ change small → get fast certainty → ship Reflections - Rethinking from a testing perspective

  14. Tests as a Design Feedback Loop
 • Expose design weaknesses

    (concentrated responsibility, fuzzy boundaries, scattered side effects) • Enable fearless refactoring with an automated safety net • Shorten cycle time ◦ change small → get fast certainty → ship High testability leads to better design —and faster delivery. Reflections - Rethinking from a testing perspective

  15. Don't strive for perfection too much
 • Progress over perfection.

    • Ship, learn, iterate. • Continuously reassess what “user value” means. →Testing and serverless are means to deliver “user value” Reflections - Rethinking from a testing perspective

  16. Takeaways
 • SFn workflow tests are doable with SFn Local,

    LocalStack • Clear state responsibilities → easier, reliable tests • Design for testability → ship faster • Let’s build better serverless testing together