Skip to content

[Due for payment 2026-06-12] perf: precompute transaction-thread report IDs #92490

@mountiny

Description

@mountiny

Problem

In MoneyRequestReportView, transaction rows were not given a transactionThreadReportID. Because of that, TransactionItemRowRBR could never take its early-return path and always mounted the heavy TransactionItemRowRBRInner, which opens 6 Onyx subscriptions for every transaction row — including rows with nothing to display in the RBR (no violations, missing-field errors, transaction errors, or thread errors).

Solution

Precompute a transactionID → transaction-thread report ID map once in MoneyRequestReportTransactionList (a single pass over report actions) and pass the resulting ID down to each row. With the thread ID present, TransactionItemRowRBR can early-return for clean rows and skip mounting the RBR inner, eliminating those 6 subscriptions per clean row. The ID is computed once at the list level rather than per row to avoid O(transactions × actions) re-scans. TransactionItemRow accepts transactionThreadReportID as an optional prop and falls back to its existing per-row lookup when callers do not supply it.

PR

#92483

Issue OwnerCurrent Issue Owner: @aimane-chnaif

Metadata

Metadata

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions