connection.sfname = self.config.dell_sc_server_folder
# Set appropriate ssn and failover state.
if self.active_backend_id:
- connection.ssn = self.active_backend_id
+ # active_backend_id is a string. Convert to int.
+ connection.ssn = int(self.active_backend_id)
connection.failed_over = True
else:
{'ssn': destssn})
return destssn
+ def _update_backend(self, active_backend_id):
+ # Update our backend id. On the next open_connection it will use this.
+ self.active_backend_id = str(active_backend_id)
+ self._client.active_backend_id = self.active_backend_id
+
def failover_host(self, context, volumes, secondary_id=None):
"""Failover to secondary.
'updates': model_update})
# this is it.
+ self._update_backend(destssn)
return destssn, volume_updates
else:
raise exception.InvalidInput(message=(