I led the architecture and refactoring for a shared subscription layer. The work made it easier to extend an existing platform while preserving the consent behavior that users and teams relied on.
Published
Work timeframe: June–September 2025
- Architecture
- Domain modeling
- Legacy modernization
Problem and constraints
Similar subscription rules lived in several places, which made changes harder to apply consistently. The existing platform was already in use, so we needed a way to share behavior and migrate gradually while preserving what each consent state meant.
Ownership
I owned the shared subscription design and the refactoring that moved existing update paths toward it. I collaborated on the broader initiative and carried parts of the migration through testing and release.
Decisions and tradeoffs
I moved common subscription behavior into a shared layer while preserving distinctions that mattered to each channel. For example, a person who had never opted in and a person who had actively opted out could both have an inactive subscription, but those states mean different things. A shared design needed to preserve that distinction wherever it mattered.
Keeping each implementation separate would have avoided the immediate cost of a refactor. A shared layer took more coordination up front, but it gave us a common place to apply and test subscription rules as the platform evolved.
Testing and rollout
I used unit tests to cover the updated behavior and introduced changes in stages behind release controls. That let us verify existing paths as they moved to the shared layer. Once a replacement path was in place, I removed superseded interfaces and code where the migration allowed it.
Impact
I retired superseded interfaces where the migration was complete. That left fewer channel-specific paths to maintain, while preserving the distinction between someone who had never opted in and someone who had opted out.
Retrospective
I’d start a similar migration by writing down what each consent state means and how it can change. Once those distinctions are clear, it’s easier to decide which rules belong in shared code, where behavior needs to vary, and what tests should protect the transition.