Skip to content

feat(frontend): Integrate backend user transactions in Solana scheduler and services#12229

Merged
AntonioVentilii merged 7 commits intomainfrom
feat/sol-backend-transactions-integration
Mar 31, 2026
Merged

feat(frontend): Integrate backend user transactions in Solana scheduler and services#12229
AntonioVentilii merged 7 commits intomainfrom
feat/sol-backend-transactions-integration

Conversation

@AntonioVentilii
Copy link
Copy Markdown
Collaborator

@AntonioVentilii AntonioVentilii commented Mar 30, 2026

Motivation

The Solana user transaction services and utilities were introduced in #12220 and #12221, but the scheduler (SolWalletScheduler) and the transaction loading service (loadSolTransactions) did not yet use them.

This PR wires the backend persistence layer into both, matching the pattern already established for EVM in eth-transactions.services.ts.

Changes

  • sol-wallet.scheduler.ts: On initial sync (isInitialSync), load stored transactions from the backend via loadSolUserTransactions and seed the internal store. Save newly discovered RPC transactions back to the backend via saveSolFinalizedTransactions (fire-and-forget with error logging via consoleError).
  • sol-transactions.services.ts: In the private loadSolTransactions, load stored transactions from the backend and merge them with fresh RPC results. Save new RPC transactions back to the backend. Both operations are gated behind USER_TRANSACTIONS_LOAD_FROM_BACKEND_ENABLED.

Tests

Added tests.

@AntonioVentilii AntonioVentilii marked this pull request as ready for review March 30, 2026 14:57
@AntonioVentilii AntonioVentilii requested a review from a team as a code owner March 30, 2026 14:58
Copilot AI review requested due to automatic review settings March 30, 2026 14:58
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Integrates Solana backend user-transaction persistence into the Solana wallet scheduler and Solana transaction loading service, aligning behavior with the existing EVM pattern.

Changes:

  • Load stored Solana user transactions from the backend and merge/seed them into frontend stores.
  • Save newly discovered finalized Solana transactions back to the backend (fire-and-forget with error logging).
  • Add/extend unit tests for scheduler and services backend integration behavior.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 4 comments.

File Description
src/frontend/src/sol/services/sol-transactions.services.ts Loads stored backend transactions and saves new RPC transactions, gated by USER_TRANSACTIONS_LOAD_FROM_BACKEND_ENABLED.
src/frontend/src/sol/schedulers/sol-wallet.scheduler.ts Seeds scheduler’s internal transaction store from backend on initial sync and saves newly found RPC transactions.
src/frontend/src/tests/sol/services/sol-transactions.services.spec.ts Adds tests asserting backend load/merge/save behavior for Sol transaction services.
src/frontend/src/tests/sol/schedulers/sol-wallet.scheduler.spec.ts Adds tests asserting backend load-on-initial-sync and save-on-new-RPC behavior for the wallet scheduler.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/frontend/src/sol/services/sol-transactions.services.ts Outdated
Comment thread src/frontend/src/sol/schedulers/sol-wallet.scheduler.ts
Comment thread src/frontend/src/sol/services/sol-transactions.services.ts Outdated
@AntonioVentilii AntonioVentilii added this pull request to the merge queue Mar 31, 2026
Merged via the queue into main with commit a839385 Mar 31, 2026
80 checks passed
@AntonioVentilii AntonioVentilii deleted the feat/sol-backend-transactions-integration branch March 31, 2026 15:58
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.

3 participants