with the fallback in RGWRados::update_containers_stats(), we no longer
need to pass placement_rule into the cls_user_bucket_entry
this removes the dependency between bucket entrypoint metadata and its
bucket instance metadata during multisite sync
Fixes: http://tracker.ceph.com/issues/21990
Signed-off-by: Casey Bodley <cbodley@redhat.com>
in case the cls_user_bucket_entry doesn't contain a placement_rule, take
it from the bucket instance info
Signed-off-by: Casey Bodley <cbodley@redhat.com>
The verbose output is helpful for debugging and understanding what is
being measured, but most of the time all that you care about is the score.
Signed-off-by: Sage Weil <sage@redhat.com>
To avoid getting stuck in a local minima, take a few additional
steps if our score drops and see if it gets better.
Signed-off-by: Sage Weil <sage@redhat.com>
Phase out the osd_weight values as we optimize the crush compat
weight set. Allow a small regression in overall score if it means
we are taking a step to remove the osd_weight value.
Fix the 'osd reweightn' invocation.
Signed-off-by: Sage Weil <sage@redhat.com>
..and fix the 'worse' threshold (we're just working around floating
point imprecision; 1.01 was too coarse).
Signed-off-by: Sage Weil <sage@redhat.com>
- it does multiple iterations, like the upmap optimizer.
- it decreases the step size if it isn't improving, in the hope
that it is overshooting the minimum
- debug output is cleaned up a bit (the info level should be
genuinely useful)
Signed-off-by: Sage Weil <sage@redhat.com>
Otherwise, when someone wants to see what's possible
to do with `mgr module enable` they have to trawl
through the whole mgr map dump.
Signed-off-by: John Spray <john.spray@redhat.com>
Some extra coverage of the dashboard, including its standby
redirect mode and the publishing of URIs.
Also invoking the command_spam mode of the selftest module.
Signed-off-by: John Spray <john.spray@redhat.com>
These didn't need to keep the GIL to go and do their
pure C++ parts, and by keeping it they could deadlock
while trying to take ActiveMgrModules::lock.
Signed-off-by: John Spray <john.spray@redhat.com>
A bunch of the previous commits were done
before this class existed, so updating in
one go instead of trying to edit history
in fine detail.
Signed-off-by: John Spray <john.spray@redhat.com>
Was passing a reference to a local stringstream into
Thread::create, not realising that it was taking a char*
reference instead of a copy. Result was garbage (or usually,
all threads having the name of the last one created)
Signed-off-by: John Spray <john.spray@redhat.com>
Modules can implement a second, separate class
that has access to very little state about the
system and can't implement commands.
They have just enough information to redirect
or forward incoming requests/traffic to the
active instance of the module on the active mgr.
This enables module authors to create modules
that end users can access via any (running) mgr node
at any time, rather than having to first work out
which mgr node is active.
Signed-off-by: John Spray <john.spray@redhat.com>
Separate out the *loading* of modules from
the *running* of modules.
This is a precursor to enabling modules to run
in standby mode.
Signed-off-by: John Spray <john.spray@redhat.com>