Refactor #2157
closedConvert pulp_resource_manager to use a django lock model
0%
Description
pulp_resource_manager currently uses a mongodb collection with a uniqueness constraint to obtain a lock. Multiple processes attempt to insert a document, and the one who succeeds is the active process.
Given the lock model that has already been created in django, convert pulp_resource_manager to use it instead of the mongo model.
It's important to test that these locks are acquired and released as expected. Hand testing this by manually invoking two pulp_resource_managers and testing failover would be good.
NOTE: Work done with issue #2154 removed
- this codepath[0] from the 3.0-dev branch That codepath and any necessary supporting codepaths should be added to the signal in pulp.tasking.celery_app
- this codepath[1] from the 3.0-dev branch. That logic needs to be added back to pulp.tasking.base:delete_worker function.
[0]: https://github.com/pulp/pulp/blob/33ce8590f6112c2101930e23f0470c1883ef98a7/server/pulp/server/async/app.py#L84-L87
[1]: https://github.com/pulp/pulp/blob/1331a5846297eb614bfd6fe5ffefb1914d76fad0/server/pulp/server/async/tasks.py#L255-L257
Related issues
Updated by mhrivnak over 8 years ago
- Blocked by Refactor #2087: create django models for task system added
Updated by mhrivnak over 8 years ago
- Project changed from RPM Support to Pulp
- Sprint Candidate changed from No to Yes
Updated by bmbouter over 8 years ago
- Description updated (diff)
- Groomed changed from No to Yes
Updated by fdobrovo about 8 years ago
- Status changed from NEW to ASSIGNED
- Assignee set to fdobrovo
Updated by fdobrovo about 8 years ago
- Blocked by Refactor #2154: Convert task system to use django models added
Updated by fdobrovo about 8 years ago
- Status changed from ASSIGNED to POST
Added by fdobrovo about 8 years ago
Updated by fdobrovo about 8 years ago
- Status changed from POST to MODIFIED
I accidently have written wrong issue number into the commit reference to it is here:
https://github.com/pulp/pulp/commit/6e81d8d723144c586933192754b8d99fe8af3414
Updated by bmbouter almost 5 years ago
- Status changed from MODIFIED to CLOSED - CURRENTRELEASE
Convert pulp_resource_manager to use a django lock model
closes #2156 https://pulp.plan.io/issues/2156