Avaiga / taipy-core

A Python library to build powerful and customized data-driven back-end applications.
Apache License 2.0
38 stars 17 forks source link

Feature/new update submission status algorithm #832

Closed toan-quach closed 11 months ago

toan-quach commented 11 months ago

Purpose:

This PR is an attempt to improve the submission status change algorithm performance.

Changes:

Instead of looping over all jobs of a submission entity when 1 job status is updated, we will update the submission status based only on the recently updated job status.

Remaing tasks:

Result

Previously, when running pytest tests/enterprise/core/test_end_to_end.py::test_without_authorization_standalone on my local (the previous test used during our discussion), it took 22.55s to run, after applying this changes, it now takes only 5.39s to run!

Results from running profiling:

------------ Old version ------------

Web capture_27-11-2023_202952_127 0 0 1

------------ New version ------------

Web capture_27-11-2023_202959_127 0 0 1

github-actions[bot] commented 11 months ago

☂️ Python Cov

current status: ✅

Overall Coverage

Lines Covered Coverage Threshold Status
8717 8256 95% 85% 🟢

New Files

No new covered files...

Modified Files

File Coverage Status
src/taipy/core/_orchestrator/_orchestrator.py 98% 🟢
src/taipy/core/submission/_submission_converter.py 100% 🟢
src/taipy/core/submission/_submission_manager.py 100% 🟢
src/taipy/core/submission/_submission_model.py 100% 🟢
src/taipy/core/submission/submission.py 94% 🟢
TOTAL 98% 🟢

updated for commit: c3f2a21 by action🐍

jrobinAV commented 11 months ago

The code is already merged in taipy repo, right? Can we close this PR?

toan-quach commented 11 months ago

@jrobinAV yep we can! Sorry for that!