Skip to content

Create/Import: Enhancement - remove duplicate work and introducing controlled concurrency#2089

Open
cmgustavo wants to merge 1 commit intobitpay:masterfrom
cmgustavo:ref/create-import-key-improvements-01
Open

Create/Import: Enhancement - remove duplicate work and introducing controlled concurrency#2089
cmgustavo wants to merge 1 commit intobitpay:masterfrom
cmgustavo:ref/create-import-key-improvements-01

Conversation

@cmgustavo
Copy link
Member

This PR improves app-side performance for createKey and serverAssistedImport by removing duplicate wallet creation and introducing controlled concurrency.

Onboarding

  • Prevent delay (show the ongoingprocess) when pressing Create Key button during the Onboarding

createKey

  • Added controlled concurrency when creating wallets (createMultipleWallets)
  • Reduced strict sequential execution

import (serverAssistedImport)

  • Removed duplicate wallet creation attempts in createWalletsForAccounts
  • Implemented wallet-level deduplication (account + chain + coin)
  • Avoided unnecessary createMultipleWallets calls for already existing wallets
  • Eliminated bwc.ErrorCOPAYER_REGISTERED noise during import

Results

createKey

  • Before: ~36.6s
  • After: ~20.7s
  • Improvement: ~43.5% faster (~15.9s saved)

import

  • Before: ~77.5s
  • After: ~66.0s
  • Improvement: ~11.5s faster

@cmgustavo cmgustavo force-pushed the ref/create-import-key-improvements-01 branch from a87f97e to d304618 Compare March 20, 2026 21:00
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