use of com.emc.storageos.Controller in project coprhd-controller by CoprHD.
the class BlockControllerImpl method activateSnapshot.
@Override
public void activateSnapshot(URI storage, List<URI> snapshotList, String opId) throws InternalException {
try {
// Direct RMI call to expedite this call without any potential distribute-Q delay
StorageSystem storageSystem = _dbClient.queryObject(StorageSystem.class, storage);
Controller controller = lookupDeviceController(storageSystem);
BlockController blkcontroller = (BlockController) controller;
blkcontroller.activateSnapshot(storage, snapshotList, opId);
} catch (RetryableDatabaseException e) {
if (e.getServiceCode() == ServiceCode.DBSVC_CONNECTION_ERROR) {
// netflix curator ConnectionException is not serializable
// and thus should not be sent back to rmi client.
_log.error("Failed to queue task due to dbsvc disconnected. Error: {}", e.getMessage());
_log.error(e.getMessage(), e);
throw DatabaseException.retryables.connectionFailed();
}
throw e;
}
}
use of com.emc.storageos.Controller in project coprhd-controller by CoprHD.
the class BlockControllerImpl method checkSyncProgress.
@Override
public Integer checkSyncProgress(URI storage, URI source, URI target, String opId) {
try {
StorageSystem storageSystem = _dbClient.queryObject(StorageSystem.class, storage);
Controller controller = lookupDeviceController(storageSystem);
BlockController blkcontroller = (BlockController) controller;
return blkcontroller.checkSyncProgress(storage, source, target, opId);
} catch (RetryableDatabaseException e) {
if (e.getServiceCode() == ServiceCode.DBSVC_CONNECTION_ERROR) {
// netflix curator ConnectionException is not serializable
// and thus should not be sent back to rmi client.
_log.error("Failed to queue task due to dbsvc disconnected. Error: {}", e.getMessage());
_log.error(e.getMessage(), e);
throw DatabaseException.retryables.connectionFailed();
}
throw e;
}
}
use of com.emc.storageos.Controller in project coprhd-controller by CoprHD.
the class BlockControllerImpl method validateStorageProviderConnection.
@Override
public boolean validateStorageProviderConnection(String ipAddress, Integer portNumber, String interfaceType) {
// Making a direct call to get connection status.
Controller controller = lookupDeviceController();
BlockController blkcontroller = (BlockController) controller;
return blkcontroller.validateStorageProviderConnection(ipAddress, portNumber, interfaceType);
}
use of com.emc.storageos.Controller in project coprhd-controller by CoprHD.
the class BlockControllerImpl method getInitiatorAlias.
@Override
public String getInitiatorAlias(URI systemURI, URI initiatorURI) throws Exception {
// Making a direct call to get alias.
Controller controller = lookupDeviceController();
BlockController blkcontroller = (BlockController) controller;
return blkcontroller.getInitiatorAlias(systemURI, initiatorURI);
}
use of com.emc.storageos.Controller in project coprhd-controller by CoprHD.
the class RPControllerImpl method getCopyAccessStates.
@Override
public Map<URI, String> getCopyAccessStates(URI protectionDevice, List<URI> volumeURIs) {
final DiscoveredSystemObject device = _dbClient.queryObject(ProtectionSystem.class, protectionDevice);
final Controller controller = lookupDeviceController(device);
// Try to grab a handle on the RPDeviceController so we can call directly into it.
if (controller instanceof RPDeviceController) {
return ((RPDeviceController) controller).getCopyAccessStates(protectionDevice, volumeURIs);
}
// Problem calling the controller so just return an empty map
return new HashMap<URI, String>();
}
Aggregations