Plaid sync domain improvements #2267

Merged
zachgoll merged 32 commits from zachgoll/plaid-sync-domain-improvements into main 2025-05-24 06:58:22 +08:00
zachgoll commented 2025-05-20 01:06:08 +08:00 (Migrated from github.com)

This PR breaks our Plaid sync process out into more manageable classes. Notably, this moves the sync process to a distinct, 2-step flow:

  1. Import stage - we first make API calls and import Plaid data to "mirror" tables
  2. Processing stage - read the raw data, apply business rules, build internal domain models and sync balances

This provides several benefits:

  • Plaid syncs can now be "replayed" without fetching API data again
  • Mirror tables provide better audit and debugging capabilities
  • Eliminates the "all or nothing" sync behavior that is currently in place, which is brittle
This PR breaks our Plaid sync process out into more manageable classes. Notably, this moves the sync process to a distinct, 2-step flow: 1. Import stage - we first make API calls and import Plaid data to "mirror" tables 2. Processing stage - read the raw data, apply business rules, build internal domain models and sync balances This provides several benefits: - Plaid syncs can now be "replayed" without fetching API data again - Mirror tables provide better audit and debugging capabilities - Eliminates the "all or nothing" sync behavior that is currently in place, which is brittle
Firontiu (Migrated from github.com) approved these changes 2025-05-24 06:39:17 +08:00
Sign in to join this conversation.