]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
mgr/cephadm: CephadmService.create -> CephadmService.prepare_create 37115/head
authorSebastian Wagner <sebastian.wagner@suse.com>
Fri, 11 Sep 2020 17:49:57 +0000 (19:49 +0200)
committerSebastian Wagner <sebastian.wagner@suse.com>
Mon, 14 Sep 2020 11:38:15 +0000 (13:38 +0200)
commit245cf50132e1731982d19e1114116e4150b9ea97
tree5fcfab28d3c3193852e893abfe897627dd29943b
parentf972becdf85a16576d874c0a1ef565c35a0dadd8
mgr/cephadm: CephadmService.create -> CephadmService.prepare_create

Refactored this to simplify the control flow. It became obvious that

* `CephadmService.make_daemon_spec`
* `CephadmService.prepare_create`
* `CephadmService.generate_config`

are basically the same thing. They're all called directly
before the deployment of a daemon. All of them should be
unified. This PR makes this refactorization simpler

By renaming `create` to `prepare_create`, we make `create`
no longer being the entrypoint to call
`create_daemon`. Thus all the functions above
return some data structures.

Signed-off-by: Sebastian Wagner <sebastian.wagner@suse.com>
src/pybind/mgr/cephadm/module.py
src/pybind/mgr/cephadm/services/cephadmservice.py
src/pybind/mgr/cephadm/services/iscsi.py
src/pybind/mgr/cephadm/services/monitoring.py
src/pybind/mgr/cephadm/services/nfs.py