Skip to content

Conversation

@heditar
Copy link
Contributor

@heditar heditar commented Dec 26, 2025

Proposed changes

  • Adding repo method to clean Injects without using .clear() on several inject attributes
  • On my machine, I was able to reproduce perfoimance issue by creation 100+ scenarios with 100+ simulation each and this change improve the latency from >20s to <1sec

Testing Instructions

  1. Create a simulation with injects and run it
  2. This simulation should have findings,communication and expectation on these injects
  3. Reset the simulation
  4. Verify that findings,communications and expectation are deleted

Note: to test the perf improvement you need to load your db with scenarionwith lot simu

Related issues

Checklist

  • I consider the submitted work as finished
  • I tested the code for its functionality
  • I wrote test cases for the relevant uses case -> test cases will be added to the perf tests
  • [NA] I added/update the relevant documentation (either on github or on notion)
  • Where necessary I refactored code to improve the overall quality
  • For bug fix -> I implemented a test that covers the bug -> going to the perf tests in another review

Further comments

If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did and what alternatives you considered, etc...

@heditar heditar changed the base branch from release/current to master December 26, 2025 17:51
@codecov
Copy link

codecov bot commented Dec 29, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 50.26%. Comparing base (469665c) to head (427c1db).
⚠️ Report is 6 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff            @@
##             master    #4650   +/-   ##
=========================================
  Coverage     50.25%   50.26%           
- Complexity     3654     3655    +1     
=========================================
  Files           897      897           
  Lines         26666    26671    +5     
  Branches       1995     1995           
=========================================
+ Hits          13402    13407    +5     
  Misses        12461    12461           
  Partials        803      803           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

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.

Reset a simulation takes a lot of time

2 participants