From 3cfa58b6c31baca8d6afd31a37385101507809f0 Mon Sep 17 00:00:00 2001 From: Joel Colledge Date: Mon, 5 Nov 2018 16:23:37 +0100 Subject: [PATCH] Create snapshots using reactive approach This makes the events ResourceDeploymentState, SnapshotDeployment and InProgressSnapshot unnecessary. --- linstor_client/commands/commands.py | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/linstor_client/commands/commands.py b/linstor_client/commands/commands.py index 808a23d..49975e7 100644 --- a/linstor_client/commands/commands.py +++ b/linstor_client/commands/commands.py @@ -6,8 +6,7 @@ from datetime import datetime, timedelta import linstor -from linstor.sharedconsts import NAMESPC_AUXILIARY, EVENT_VOLUME_DISK_STATE, EVENT_RESOURCE_STATE, \ - EVENT_RESOURCE_DEPLOYMENT_STATE, EVENT_SNAPSHOT_DEPLOYMENT +from linstor.sharedconsts import NAMESPC_AUXILIARY, EVENT_VOLUME_DISK_STATE, EVENT_RESOURCE_STATE from linstor.properties import properties from linstor.protobuf_to_dict import protobuf_to_dict import linstor_client @@ -672,11 +671,7 @@ def reply_handler(replies): event_formatter_table = { EVENT_VOLUME_DISK_STATE: lambda event_data: "Disk state: " + event_data.disk_state, - EVENT_RESOURCE_STATE: lambda event_data: "Resource ready: " + str(event_data.ready), - EVENT_RESOURCE_DEPLOYMENT_STATE: lambda event_data: - "Deployment state: " + self._summarize_api_call_responses(event_data.responses), - EVENT_SNAPSHOT_DEPLOYMENT: lambda event_data: - "Snapshot deployment state: " + self._summarize_api_call_responses(event_data.responses) + EVENT_RESOURCE_STATE: lambda event_data: "Resource ready: " + str(event_data.ready) } def event_handler(event_header, event_data):