mgr/dashboard: do not show RGW API keys if only read-only privileges
Reviewed-by: Ernesto Puerta <epuertat@redhat.com>
Reviewed-by: Laura Paduano <lpaduano@suse.com>
Reviewed-by: Tatjana Dehler <tdehler@suse.com>
Hide the different meanings of max_buckets from the user by improving the UI.
Fixes: https://tracker.ceph.com/issues/44322
Signed-off-by: Volker Theile <vtheile@suse.com>
In the test test_unexpected_down(), there is client running on CPU0
and server runing on CPU1, the server maybe finished before the client
(client and other workloads share CPU0), so client couldn't read data
and throws "dispatch_sockets(): cb_client() got unexpected exception
std::system_error (error crimson::net:4, read eof)"
Signed-off-by: luo rixin <luorixin@huawei.com>
mgr/dashboard: fix stray requests/error in Grafana unit test
Reviewed-by: Kiefer Chang <kiefer.chang@suse.com>
Reviewed-by: Tatjana Dehler <tdehler@suse.com>
btree_set<> by default uses `std::allocator<Key>`, and btree_map by
default uses `std::allocator<std::pair<Key, Value>>`.
before this change, btree uses the allocator directly for allocating n
elements where element is `Key` or `std::pair<Key, Value>` respectively,
while "n" is actually supposed to be the number of bytes used by each
node which is being allocated.
but, what we need to allocate is actually a "node_type" for holding
multiple slots, and each slot holds an element. in addition to the
slots, a node also keeps track of metadata for btree itself. in short,
what we allocate now is (in bytes):
alignof(sizeof(node_type)) * sizeof(element)
but what we should allocate is (in bytes):
alignof(sizeof(node_type))
in this change:
* always rebind the allocator to the correct aligned type with given
alignment
* extract the allocator related helpers into a template class
Signed-off-by: Kefu Chai <kchai@redhat.com>
- if hosts are passed, use those.
- if all_hosts=true, use all hosts.
Otherwise, build a set of hosts based on the labels--either explicit or
implied. If there's no label, use all hosts.
If there is a count, use a subset of candidate hosts. If there was no
label and there is no count, fail.
If count and hosts are both provided, then we either (1) use the hosts
as the candidate list and place among them (if len(hosts) >= count), or
(2) ensure that any result includes *at least* the provided hosts.
Add tests that (I'm pretty sure) cover cases!
Signed-off-by: Sage Weil <sage@redhat.com>
* refs/pull/33553/head:
mgr/cephadm: orch ls: include specs with no daemons
mgr/cephadm: orch ls: show spec size
mgr/orch: remove unused fields in RGWSpec
mgr/orch: fix ServiceSpec fields
mgr/cephadm: simplify spec apply
pybind/mgr/mgr_module: revert PersistentStoreDict seperator
mgr/cephadm: apply services after refreshing inventory
mgr/cephadm: catch and log exceptions from apply
mgr/orch: no extra whitespace in stored json specs
mgr/cephadm: drop daemon_type arg to _apply_service
mgr/cephadm: use _apply() helper for all apply_ methods
mgr/cephadm: replace PersistentStoreDict with SpecStore
mgr/cephadm: do not remove service spec when removing a daemon
mgr/cephadm: rename completion variables&cleanup
mgr/cephadm: leverage service specs
Reviewed-by: Sage Weil <sage@redhat.com>
This way you see entries like
NAME RUNNING REFRESHED IMAGE NAME IMAGE ID SPEC
mds.foo 0/1 - <unknown> <unknown> present
before any daemons have been created.
Signed-off-by: Sage Weil <sage@redhat.com>
- service_type is required. Make it the first position arg to the ctor.
- service_id is the id *only* and optional.
- service_name() is the full service name (no change)
The old 'name' was previously used as the id only, so it was poorly named,
and optional, but in this series was changed to include the type, breaking
naming for a bunch of things (e.g., daemons called mds.mds.fsname.xyz).
Signed-off-by: Sage Weil <sage@redhat.com>
- Teach _apply_service how to pick the create (and config) functions, so
that we don't need any weird wrappers in the callers.
- Replace trigger_deploy() and _apply_services() with a simpler
_apply_all_services()
- Drop all of the per-type _apply_foo() methods.
Signed-off-by: Sage Weil <sage@redhat.com>
Clean up a few that were missed (due to racing PRs, presumably).
'creation' -> 'update', since an apply doesn't necessarily create (it may
destroy!).
Signed-off-by: Sage Weil <sage@redhat.com>