]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/cephadm: catch and log exceptions from apply
authorSage Weil <sage@redhat.com>
Sat, 29 Feb 2020 21:55:40 +0000 (15:55 -0600)
committerSage Weil <sage@redhat.com>
Sun, 1 Mar 2020 14:10:54 +0000 (08:10 -0600)
Signed-off-by: Sage Weil <sage@redhat.com>
src/pybind/mgr/cephadm/module.py

index c39c9abc34c4562e3a9b61941fd2a3fc69adcb86..a415568bdd356e1987e1f3b002734d3316eab507 100644 (file)
@@ -2813,7 +2813,11 @@ receivers:
         specs = self.spec_store.find(service_name)
         completions = list()
         for spec in specs:
-            completions.append(func(spec))
+            try:
+                completions.append(func(spec))
+            except Exception as e:
+                self.log.warning('Failed to apply %s spec %s: %s' % (
+                    service_name, spec, e))
         if completions:
             return completions
         return [trivial_result("Nothing to do..")]