try:
tree = json.loads(out)
except json.decoder.JSONDecodeError:
- self.log.error(f"Could not decode json -> {out}")
+ self.log.exception(f"Could not decode json -> {out}")
return osd_host_map
nodes = tree.get('nodes', {})
daemon_type, daemon_id, host))
if daemon_type == 'mon':
create_func(daemon_id, host, network) # type: ignore
- elif daemon_type == 'nfs':
+ elif daemon_type in ['nfs', 'iscsi']:
create_func(daemon_id, host, spec) # type: ignore
else:
- create_func(daemon_id, host) # type: ignore
+ create_func(daemon_id, host) # type: ignore
# add to daemon list so next name(s) will also be unique
sd = orchestrator.DaemonDescription(
if self._apply_service(spec):
r = True
except Exception as e:
- self.log.warning('Failed to apply %s spec %s: %s' % (
+ self.log.exception('Failed to apply %s spec %s: %s' % (
spec.service_name(), spec, e))
return r
daemon_type, daemon_id, host))
if daemon_type == 'mon':
args.append((daemon_id, host, network)) # type: ignore
- elif daemon_type == 'nfs':
- args.append((daemon_id, host, spec)) # type: ignore
- elif daemon_type == 'iscsi':
+ elif daemon_type in ['nfs', 'iscsi']:
args.append((daemon_id, host, spec)) # type: ignore
else:
args.append((daemon_id, host)) # type: ignore