Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nautilus: mgr/rbd_support: support scheduling long-running background operations #29725

Merged
merged 14 commits into from Aug 20, 2019

Conversation

@dillaman
Copy link
Contributor

commented Aug 18, 2019

dillaman and others added 14 commits Jul 16, 2019
librbd: allow ProgressCtx::update_progress to cancel maintenance ops
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 026df75)
librbd: abort an image removal if block objects cannot be removed
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 361e51f)
pybind/rbd: flatten, remove, trash_remove, migration progress callback
This callback can be used to track progress and also to attempt to cancel
the operation while it's in-progress by returning a negative error code
from the callback.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 6dc8249)
pybind/rbd: new OperationCanceled exception
This allows the error to be directly caught instead of attempting
to parse the OSError.errno

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 2e85381)
pybind/mgr: new 'rbd task' background task management
Fixes: http://tracker.ceph.com/issues/40621
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit b7a826d)
pybind/mgr: support marking progress events as failed
The failed events can also include a failure message to indicate
the reason for the failure.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit d78ddaa)

Conflicts:
	src/pybind/mgr/progress/module.py: tweaked missing backport for task start/stop times
pybind/mgr: mark progress events as failed if an error occurs
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit b99ae27)
pybind/mgr: rbd tasks now provide a dict to the progress events
This dict will include an origin key fixed to 'rbd_support' as well
as pool and image references.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit e87aff5)
qa: test case for new rbd background tasks
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 63a8f6c)
pybind/mgr: handle duplicate rbd task commands
The 'ceph' CLI will duplicate commands within teuthology to test
the MONs idempotency. This shouldn't be required for the MGR module,
but we can keep a fixed set of completed tests to handle this
possible command replay.

Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 9bdc376)
pybind/mgr: don't log exception when cannot find RBD task by id
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 7ccf0b3)
pybind/rbd: fix call to unregister_osd_perf_queries
.. should be invoked as self.unregister_osd_perf_queries()
rather than self.module.unregister_osd_perf_queries().

Signed-off-by: Venky Shankar <vshankar@redhat.com>
(cherry picked from commit 37a9b53)
pybind/mgr/rbd_support: use image ids to detect duplicate tasks
This helps to to avoid the case where new tasks were not being scheduled
when an image name was re-used after having a task created under the
same name.

Fixes: https://tracker.ceph.com/issues/41032
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 7adb17f)
mon/mgr: add 'rbd_support' to list of always-on mgr modules
The 'rbd_support' mgr module provides many background functions that
are required by the 'rbd' CLI performance queries, as well as future
background long-running maintenance tasks.

Fixes: http://tracker.ceph.com/issues/40790
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 7231aab)

Conflicts:
	src/mon/MgrMonitor.cc: trivial resolution
@trociny
Copy link
Contributor

left a comment

LGTM

@dillaman

This comment has been minimized.

Copy link
Contributor Author

commented Aug 19, 2019

retest this please

@yuriw

This comment has been minimized.

Copy link
Contributor

commented Aug 19, 2019

@yuriw yuriw merged commit 8e3bf64 into ceph:nautilus Aug 20, 2019

4 checks passed

Docs: build check OK - docs built
Details
Signed-off-by all commits in this PR are signed
Details
Unmodified Submodules submodules for project are unmodified
Details
make check make check succeeded
Details

@dillaman dillaman deleted the dillaman:wip-41078-nautilus branch Aug 20, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.