Skip to content

perf(multichain-account-service): add v2 createAccounts (account batching when supported)#8131

Open
ccharly wants to merge 6 commits intomainfrom
cc/feat/solana-batch-accounts
Open

perf(multichain-account-service): add v2 createAccounts (account batching when supported)#8131
ccharly wants to merge 6 commits intomainfrom
cc/feat/solana-batch-accounts

Conversation

@ccharly
Copy link
Contributor

@ccharly ccharly commented Mar 6, 2026

Explanation

Implementing proper batching for our Solana account provider.

References

Checklist

  • I've updated the test suite for new or updated code as appropriate
  • I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate
  • I've communicated my changes to consumers by updating changelogs for packages I've changed
  • I've introduced breaking changes in this PR and have prepared draft pull requests for clients and consumer packages to resolve them

Note

Medium Risk
Changes core Snap-based account creation to optionally use SnapKeyring.createAccounts for single and range derivations; misconfiguration or Snap incompatibilities could impact account creation or indexing across Sol/BTC/TRX.

Overview
Adds a config-gated v2 path for Snap-based providers to batch BIP-44 account creation via SnapKeyring.createAccounts, while keeping the existing per-account v1 flow as the default.

Refactors SnapAccountProvider to own createAccounts validation + timeout handling and introduces provider overrides (createAccountV1, optional toBip44Account) so SolAccountProvider, BtcAccountProvider, and TrxAccountProvider reuse shared batching logic; discovery now creates accounts through the shared helper.

Updates defaults to include createAccounts.v2: false, expands unit tests to cover v1 vs v2 behavior (single, range, idempotency, timeout), and adds small test utilities (DeepPartial, toGroupIndexRangeArray).

Written by Cursor Bugbot for commit 130af27. This will update automatically on new commits. Configure here.

@ccharly ccharly changed the title feat(multichain-account-service): add Solana account batching perf(multichain-account-service): add Solana account batching Mar 6, 2026
@ccharly ccharly force-pushed the cc/feat/solana-batch-accounts branch from 8f805c8 to 6d1259e Compare March 6, 2026 10:58
@ccharly ccharly force-pushed the cc/feat/backup-and-sync-batch branch 5 times, most recently from 716a57a to 16a70a6 Compare March 9, 2026 17:12
@ccharly ccharly force-pushed the cc/feat/solana-batch-accounts branch from 6d1259e to 99d0aa2 Compare March 9, 2026 17:17
@ccharly ccharly marked this pull request as ready for review March 9, 2026 17:17
@ccharly ccharly requested review from a team as code owners March 9, 2026 17:17
@ccharly ccharly force-pushed the cc/feat/solana-batch-accounts branch 2 times, most recently from 18c070d to 05ecd6a Compare March 9, 2026 18:18
@ccharly ccharly force-pushed the cc/feat/backup-and-sync-batch branch from 25d09e4 to 957ea19 Compare March 10, 2026 09:35
@ccharly ccharly force-pushed the cc/feat/solana-batch-accounts branch 2 times, most recently from 6fd4e76 to fb482ca Compare March 10, 2026 14:43
@ccharly ccharly force-pushed the cc/feat/solana-batch-accounts branch from fb482ca to 20605ec Compare March 10, 2026 15:32
@ccharly ccharly force-pushed the cc/feat/backup-and-sync-batch branch from 957ea19 to 222e1eb Compare March 12, 2026 08:56
Base automatically changed from cc/feat/backup-and-sync-batch to main March 12, 2026 13:01
@ccharly ccharly force-pushed the cc/feat/solana-batch-accounts branch from 20605ec to 4feb6e9 Compare March 12, 2026 17:13
@ccharly ccharly changed the title perf(multichain-account-service): add Solana account batching perf(multichain-account-service): add v2 createAccounts (account batching when supported) Mar 16, 2026
Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant