Bug 970785
Summary: | Need a way to update the auto publish flag on a distributor | ||
---|---|---|---|
Product: | [Retired] Pulp | Reporter: | Partha Aji <paji> |
Component: | API/integration | Assignee: | Michael Hrivnak <mhrivnak> |
Status: | CLOSED CURRENTRELEASE | QA Contact: | Preethi Thomas <pthomas> |
Severity: | unspecified | Docs Contact: | |
Priority: | medium | ||
Version: | 2.1.1 | CC: | mhrivnak, nobody, skarmark |
Target Milestone: | --- | Keywords: | Triaged |
Target Release: | 2.3.0 | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2013-12-09 14:30:09 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: |
Description
Partha Aji
2013-06-04 21:32:10 UTC
Relevance w.r.t Katello In katello we used to set the auto publish attribute false for repositories in the library environment. This was done as an optimization thing since never had any consumers register to library (so we never needed to do the somewhat expensive publish op). However we now want a feature that will let one to register consumers to library and consume content from there. For that to happen we need to either enable auto publish or periodically call the publish operation directly. build: 2.3.0-0.10.alpha verified In [45]: pic.PUT('/v2/repositories/upload/distributors/yum_distributor/', {'distributor_config':{"http": True},"delta": {"auto_publish": False}}) Request Body { "distributor_config": { "http": true }, "delta": { "auto_publish": false } } Response Body [ { "task_group_id": "6b0f9a37-e4d2-4332-87aa-fb219a72002c", "call_request_id": "5383657d-a1e3-47a2-96a9-575980312456", "exception": null, "_href": "/pulp/api/v2/task_groups/6b0f9a37-e4d2-4332-87aa-fb219a72002c/", "task_id": "5383657d-a1e3-47a2-96a9-575980312456", "call_request_tags": [ "pulp:repository:upload", "pulp:repository_distributor:yum_distributor", "pulp:action:update_distributor" ], "reasons": [], "start_time": null, "traceback": null, "schedule_id": null, "finish_time": null, "state": "waiting", "result": null, "dependency_failures": {}, "call_request_group_id": "6b0f9a37-e4d2-4332-87aa-fb219a72002c", "progress": {}, "principal_login": "admin", "response": "accepted", "tags": [ "pulp:repository:upload", "pulp:repository_distributor:yum_distributor", "pulp:action:update_distributor" ] } ] Out[45]: (202, [{u'_href': u'/pulp/api/v2/task_groups/6b0f9a37-e4d2-4332-87aa-fb219a72002c/', u'call_request_group_id': u'6b0f9a37-e4d2-4332-87aa-fb219a72002c', u'call_request_id': u'5383657d-a1e3-47a2-96a9-575980312456', u'call_request_tags': [u'pulp:repository:upload', u'pulp:repository_distributor:yum_distributor', u'pulp:action:update_distributor'], u'dependency_failures': {}, u'exception': None, u'finish_time': None, u'principal_login': u'admin', u'progress': {}, u'reasons': [], u'response': u'accepted', u'result': None, u'schedule_id': None, u'start_time': None, u'state': u'waiting', u'tags': [u'pulp:repository:upload', u'pulp:repository_distributor:yum_distributor', u'pulp:action:update_distributor'], u'task_group_id': u'6b0f9a37-e4d2-4332-87aa-fb219a72002c', u'task_id': u'5383657d-a1e3-47a2-96a9-575980312456', u'traceback': None}]) In [46]: pic.GET('/v2/repositories/upload/distributors/')Response Body [ { "repo_id": "upload", "_ns": "repo_distributors", "last_publish": "2013-09-19T13:44:05-04:00", "auto_publish": false, "scheduled_publishes": [], "distributor_type_id": "yum_distributor", "scratchpad": {}, "_id": { "$oid": "523b3262d669f043f70000a8" }, "config": { "http": true, "relative_url": "upload", "https": true }, "id": "yum_distributor" }, { "repo_id": "upload", "_ns": "repo_distributors", "last_publish": null, "auto_publish": false, "scheduled_publishes": [], "distributor_type_id": "export_distributor", "scratchpad": null, "_id": { "$oid": "523b3262d669f043f70000a9" }, "config": { "http": false, "https": true }, "id": "export_distributor" } ] Out[46]: (200, [{u'_id': {u'$oid': u'523b3262d669f043f70000a8'}, u'_ns': u'repo_distributors', u'auto_publish': False, u'config': {u'http': True, u'https': True, u'relative_url': u'upload'}, u'distributor_type_id': u'yum_distributor', u'id': u'yum_distributor', u'last_publish': u'2013-09-19T13:44:05-04:00', u'repo_id': u'upload', u'scheduled_publishes': [], u'scratchpad': {}}, {u'_id': {u'$oid': u'523b3262d669f043f70000a9'}, u'_ns': u'repo_distributors', u'auto_publish': False, u'config': {u'http': False, u'https': True}, u'distributor_type_id': u'export_distributor', u'id': u'export_distributor', u'last_publish': None, u'repo_id': u'upload', u'scheduled_publishes': [], u'scratchpad': None}]) In [47]: Pulp 2.3 released. |