Skip to content

perf(simulation): optimize market talent persistence with bulk write operations #467

Description

@Diwakar-odds

Problem Statement

In ickEngine.js, the simulation sequentially awaits MarketDirector.updateOne and MarketActor.updateOne inside a or...of loop for potentially thousands of market talents. This synchronous DB await in a loop blocks the Node.js event loop severely during the weekly tick, degrading performance linearly with talent count.

Proposed Technical Approach

  • Refactor the sequential updateOne loops into a single �ulkWrite operation.
  • Group talent mutations into batches to drastically reduce database roundtrips.

Metadata

Metadata

Assignees

Labels

ECSOC2026Issues open for ECSOC 2026 contributorsECSoC26Mandatory tracking label for ECSoC Sentinel scoringassignedIssue has been assigned to a contributor and is currently being worked on.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions