From: Stephan Müller Date: Wed, 23 Sep 2020 09:16:44 +0000 (+0200) Subject: mgr/dashboard: Add clay plugin support X-Git-Tag: v15.2.9~106^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=3c58cd6e801cd5774cf55f21cef343f8516702e7;p=ceph.git mgr/dashboard: Add clay plugin support The erasure code plugin "clay" is now supported by the dashboard. Now a clay based profile can be created in the ec profile creation modal dialog which can be found in the pool form. The defaults of the plugin are calculated or preselected and shown in the dashboard, therefore things are made mandatory even if they are not on the cli, but as they automatically set the user doesn't have to set them, but sees the defaults instantly before creating the profile. (This is the same behavior that is used for all other supported plugins.) Fixes: https://tracker.ceph.com/issues/44433 Signed-off-by: Stephan Müller (cherry picked from commit b3fd05bbc568cb775d25032ce87ea8dbb5106b3a) Conflicts: src/pybind/mgr/dashboard/frontend/src/app/shared/api/erasure-code-profile.service.ts Fixed conflicts because https://github.com/ceph/ceph/pull/34696 has not been backported to octopus. --- diff --git a/doc/rados/operations/erasure-code-clay.rst b/doc/rados/operations/erasure-code-clay.rst index ccf3b309c39..3c09314236b 100644 --- a/doc/rados/operations/erasure-code-clay.rst +++ b/doc/rados/operations/erasure-code-clay.rst @@ -88,7 +88,7 @@ Where: :Description: Number of OSDs requested to send data during recovery of a single chunk. *d* needs to be chosen such that - k+1 <= d <= k+m-1. Larger the *d*, the better the savings. + k+1 <= d <= k+m-1. The larger the *d*, the better the savings. :Type: Integer :Required: No. diff --git a/src/pybind/mgr/dashboard/controllers/erasure_code_profile.py b/src/pybind/mgr/dashboard/controllers/erasure_code_profile.py index 3c8ba61f9f8..6842943c193 100644 --- a/src/pybind/mgr/dashboard/controllers/erasure_code_profile.py +++ b/src/pybind/mgr/dashboard/controllers/erasure_code_profile.py @@ -47,8 +47,8 @@ class ErasureCodeProfileUi(ErasureCodeProfile): """ config = mgr.get('config') return { - # Because 'shec' is experimental it's not included - 'plugins': config['osd_erasure_code_plugins'].split() + ['shec'], + # Because 'shec' and 'clay' are experimental they're not included + 'plugins': config['osd_erasure_code_plugins'].split() + ['shec', 'clay'], 'directory': config['erasure_code_dir'], 'nodes': mgr.get('osd_map_tree')['nodes'], 'names': [name for name, _ in diff --git a/src/pybind/mgr/dashboard/frontend/src/app/ceph/pool/erasure-code-profile-form/erasure-code-profile-form-modal.component.html b/src/pybind/mgr/dashboard/frontend/src/app/ceph/pool/erasure-code-profile-form/erasure-code-profile-form-modal.component.html index cbdeb36b1b4..a6510eccf0f 100644 --- a/src/pybind/mgr/dashboard/frontend/src/app/ceph/pool/erasure-code-profile-form/erasure-code-profile-form-modal.component.html +++ b/src/pybind/mgr/dashboard/frontend/src/app/ceph/pool/erasure-code-profile-form/erasure-code-profile-form-modal.component.html @@ -147,6 +147,56 @@ +
+ +
+
+ + + + +
+ D is automatically updated on k and m changes + + D can be set from {{getDMin()}} to {{getDMax()}} + D can only be set to {{getDMax()}} + + D has to be greater than k ({{getDMin()}}). + D has to be lower than k + m ({{getDMax()}}). +
+
+