Uploaded image for project: 'Red Hat OpenStack Services on OpenShift'
  1. Red Hat OpenStack Services on OpenShift
  2. OSPRH-17941

[fork vs multiprocessing] 3 - Refactor periodic_task.py for spawn-safe parallel tasks

XMLWordPrintable

    • Icon: Story Story
    • Resolution: Unresolved
    • Icon: Critical Critical
    • None
    • None
    • python-oslo-service
    • None
    • Sprint 8, Sprint 10, Sprint 11, Sprint 12
    • 4
    • Important

      Goal: Modify any parallel execution path (e.g., run_periodic_tasks_in_parallel) to utilize spawn context, preventing deadlock when periodic threads and multiprocessing intersect.

      Acceptance Criteria:

      • Verify code paths create a pool through get_spawn_pool.
      • Unit test: schedule 10 dummy tasks while another thread holds a lock; confirm child processes execute and exit cleanly.
      • Coverage for new branch > 90 %.

      Additional Details:
      See https://pythonspeed.com/articles/python-multiprocessing/ and video explanation at https://youtu.be/RIc-Tut95YM?t=185.

              mbollo@redhat.com Daniel Mats Niklas Bengtsson
              hberaud Hervé Beraud
              rhos-dfg-pidone
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated: