label-studio icon indicating copy to clipboard operation
label-studio copied to clipboard

fix: Clear expired locks for all tasks

Open seungwook0417 opened this issue 2 years ago • 6 comments

PR fulfills these requirements

  • [X] Commit message(s) and PR title follows the format [fix|feat|ci|chore|doc]: TICKET-ID: Short description of change made ex. fix: DEV-XXXX: Removed inconsistent code usage causing intermittent errors
  • [ ] Tests for the changes have been added/updated (for bug fixes/features)
  • [ ] Docs have been added/updated (for bug fixes/features)
  • [ ] Best efforts were made to ensure docs/code are concise and coherent (checked for spelling/grammatical errors, commented out code, debug logs etc.)
  • [ ] Self-reviewed and ran all changes on a local instance (for bug fixes/features)

Change has impacts in these area(s)

(check all that apply)

  • [ ] Product design
  • [ ] Backend (Database)
  • [X] Backend (API)
  • [ ] Frontend

Describe the reason for change

Issue #4781 indicates that tasks with an "expired lock" status are not being cleared as expected.

What does this fix?

This PR addresses the bug where tasks with "lock expired" status are not being cleared.

What is the new behavior?

Tasks that have their locks expired will now be properly cleared or made available for further processing.

What is the current behavior?

Currently, tasks with expired locks remain uncleared and are not available for reprocessing.

Does this change affect performance?

The change optimizes the task processing system by ensuring that expired tasks are cleared, potentially improving overall system efficiency.

Does this PR introduce a breaking change?

  • [ ] Yes, and covered entirely by feature flag(s)
  • [ ] Yes, and covered partially by feature flag(s)
  • [x] No
  • [ ] Not sure (briefly explain the situation below)

What level of testing was included in the change?

(check all that apply)

  • [ ] e2e
  • [ ] integration
  • [ ] unit

Which logical domain(s) does this change affect?

The change primarily affects the task management and lock handling domain.

seungwook0417 avatar Sep 14 '23 02:09 seungwook0417

Deploy request for label-studio-docs-new-theme pending review.

Visit the deploys page to approve it

Name Link
Latest commit 82562c169f3e6c44083b2f7f71f98e59cfa5b2ff

netlify[bot] avatar Sep 14 '23 02:09 netlify[bot]

Deploy request for heartex-docs pending review.

Visit the deploys page to approve it

Name Link
Latest commit 82562c169f3e6c44083b2f7f71f98e59cfa5b2ff

netlify[bot] avatar Sep 14 '23 02:09 netlify[bot]

Thanks for the patch @seungwook0417, on first pass it looks like this solution may be a bit too broad, especially in multi-user or multi-tenant environments. We're looking into a fix will will keep you updated.

hogepodge avatar Oct 06 '23 16:10 hogepodge

@hogepodge Thank you for letting me know about the patch. Our team has tried this and we've seen that it works well in multi-user environments. This reduces the likelihood of missing jobs, resulting in very satisfactory results. I'll be waiting for your update. Thank you again for contributing to a good thing.

seungwook0417 avatar Oct 06 '23 16:10 seungwook0417

This PR is stale because it has been open 45 days with no activity. Remove stale label or comment or this will be closed in 10 days.

robot-ci-heartex avatar Jun 10 '24 21:06 robot-ci-heartex

This PR is stale because it has been open 45 days with no activity. Remove stale label or comment or this will be closed in 10 days.

robot-ci-heartex avatar Oct 19 '24 01:10 robot-ci-heartex

This PR was closed because it has been stalled for 10 days with no activity.

robot-ci-heartex avatar Oct 29 '24 02:10 robot-ci-heartex