# Square Payroll's Migration from a Monolith to Microservices

DevFeed: [Square Payroll's Migration from a Monolith to Microservices](<https://devfeed.tech/articles/square-payroll-s-migration-from-a-monolith-to-microservices-15879.md>)

Original publisher: [Read original article](<https://developer.squareup.com/blog/square-payrolls-migration-from-a-monolith-to-microservices>)

Author: Harold Sultan

Published: 2022-10-12T04:00:00Z

Content type: article

Language: en

Sources: [Square Corner](<https://devfeed.tech/sources/square-corner-blog-medium.md>)

Topics: [Cloud Architecture](<https://devfeed.tech/topics/cloud-architecture.md>), [Microservices](<https://devfeed.tech/topics/microservices.md>), [Serverless](<https://devfeed.tech/topics/serverless.md>), [AWS Step Functions](<https://devfeed.tech/topics/aws-step-functions.md>), [Amazon Simple Queue Service (SQS)](<https://devfeed.tech/topics/amazon-simple-queue-service-sqs.md>), [software-architecture](<https://devfeed.tech/topics/software-architecture.md>), [Amazon DynamoDB](<https://devfeed.tech/topics/amazon-dynamodb.md>), [observability](<https://devfeed.tech/topics/observability.md>)

Tags: [2](<https://devfeed.tech/tags/2.md>), [3](<https://devfeed.tech/tags/3.md>), [account](<https://devfeed.tech/tags/account.md>), [actions](<https://devfeed.tech/tags/actions.md>), [added](<https://devfeed.tech/tags/added.md>), [all](<https://devfeed.tech/tags/all.md>), [allowed](<https://devfeed.tech/tags/allowed.md>), [allows](<https://devfeed.tech/tags/allows.md>), [also](<https://devfeed.tech/tags/also.md>), [architecture](<https://devfeed.tech/tags/architecture.md>), [aws](<https://devfeed.tech/tags/aws.md>), [engineering](<https://devfeed.tech/tags/engineering.md>), [microservices](<https://devfeed.tech/tags/microservices.md>), [migration](<https://devfeed.tech/tags/migration.md>), [monolith](<https://devfeed.tech/tags/monolith.md>), [payroll](<https://devfeed.tech/tags/payroll.md>), [scaling](<https://devfeed.tech/tags/scaling.md>), [serverless](<https://devfeed.tech/tags/serverless.md>), [serverless-architecture](<https://devfeed.tech/tags/serverless-architecture.md>), [square](<https://devfeed.tech/tags/square.md>), [with](<https://devfeed.tech/tags/with.md>)

## AI overview

Square Payroll moved its California SDI/SIT filing workflow from three polling cron jobs and Sidekiq workers to an event driven AWS serverless service. The monolith sends each filing's required data to payroll-filings over SQS; the service runs workflows with Step Functions, Lambda actions, choices, and waits, then sends supported status updates back over SQS. This removes database polling from the filing service and keeps its workflow data in DynamoDB. Step Functions make routing and retries visible, while reusable Lambdas avoid embedding workflow-specific branches in code. The article identifies reduced Sidekiq dependence, fewer no-op database queries, and clearer workflow paths as goals; it describes an early migration of one California tax workflow, not a completed migration of all Payroll tasks.

## Source excerpt

Scaling with AWS serverless architecture