Project

Profile

Help

Story #5108

closed

As a user, a task can reserve multiple resources

Added by ttereshc about 5 years ago. Updated almost 5 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Assignee:
Category:
-
Sprint/Milestone:
-
Start date:
Due date:
% Done:

100%

Estimated time:
Platform Release:
2.21.0
Groomed:
No
Sprint Candidate:
No
Tags:
Pulp 2
Sprint:
Quarter:

Description

Motivation

Dependency solving for multiple repositories (which implies copy to multiple target repositories) requires the ability to lock on multiple resources.
Without this feature, changes to a repo might not be deterministic.

Solution

  • Change uniqueness constraint on the ReservedResource model, from task_id to (task_id, resource_id).
  • For multi-lock task choose a worker if only 0 or 1 workers have a lock for any of the resources from a multi-lock task, otherwise wait.
  • release all the locks for the task when it's complete.
  • document the worst case scenario (N-2 works can be idle until there is only one worker being busy)

the pulp3 patch adding multi-locking support https://github.com/pulp/pulpcore/commit/ff0739e9a9fe4d3c0762e498ae59ec756d02fb71


Related issues

Blocks RPM Support - Story #5067: As a user, multiple source/target repositories can be used for recursive copyCLOSED - CURRENTRELEASEdalley

Actions
Actions #1

Updated by ttereshc about 5 years ago

  • Blocks Story #5067: As a user, multiple source/target repositories can be used for recursive copy added
Actions #2

Updated by ggainey about 5 years ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to ggainey
Actions #3

Updated by dkliban@redhat.com about 5 years ago

  • Groomed changed from No to Yes
  • Sprint Candidate changed from No to Yes
  • Sprint set to Sprint 55
Actions #4

Updated by dkliban@redhat.com about 5 years ago

  • Sprint changed from Sprint 55 to Sprint 56
Actions #5

Updated by ggainey about 5 years ago

  • Status changed from ASSIGNED to POST
  • Groomed changed from Yes to No
  • Sprint Candidate changed from Yes to No
  • Sprint deleted (Sprint 56)

Added by ggainey almost 5 years ago

Revision e1bb056f | View on GitHub

Add API to allow queueing an async task for multiple resources

Adds API to tasks.py:

  • _queue_reserved_task_list
  • get_worker_for_reservation_list
  • apply_async_with_reservation_list

Closes #5108 https://pulp.plan.io/issues/5108

Actions #6

Updated by ggainey almost 5 years ago

  • Status changed from POST to MODIFIED
  • % Done changed from 0 to 100
Actions #7

Updated by dalley almost 5 years ago

  • Platform Release set to 2.21.0
Actions #8

Updated by dalley almost 5 years ago

  • Project changed from RPM Support to Pulp
Actions #9

Updated by dalley almost 5 years ago

  • Status changed from MODIFIED to CLOSED - CURRENTRELEASE

Also available in: Atom PDF