Skip to content

Comments

[PERF] account: optimize migration performance by pre-creating column and bulk transferring invoice_date#721

Merged
royle-vietnam merged 1 commit intoViindoo:17.0from
royle-vietnam:v17_imp_account
Dec 5, 2025
Merged

[PERF] account: optimize migration performance by pre-creating column and bulk transferring invoice_date#721
royle-vietnam merged 1 commit intoViindoo:17.0from
royle-vietnam:v17_imp_account

Conversation

@royle-vietnam
Copy link
Collaborator

Pre-create the target column to avoid triggering compute() during update,
and perform a direct bulk data transfer from account_move to account_move_line.
This avoids ORM overhead, reduces heap rewrites, and prevents unnecessary
recomputation on 15M move lines.

Performance result:

  • Previous approach: ~2 hours
  • Optimized approach: ~15 minutes (~8x faster)

and bulk transferring invoice_date

Pre-create the target column to avoid triggering compute() during
update,
and perform a direct bulk data transfer from account_move to
account_move_line.
This avoids ORM overhead, reduces heap rewrites, and prevents
unnecessary
recomputation on 15M move lines.

Performance result:
- Previous approach: ~2 hours
- Optimized approach: ~15 minutes
(~8x faster)
@royle-vietnam royle-vietnam merged commit 54639f8 into Viindoo:17.0 Dec 5, 2025
2 checks passed
@royle-vietnam royle-vietnam deleted the v17_imp_account branch December 5, 2025 03:25
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