Search in sources :

Example 1 with SnapRequests

use of com.emc.storageos.vnxe.requests.SnapRequests in project coprhd-controller by CoprHD.

the class VNXeApiClient method attachSnap.

/**
 * Attach the snapshot so hosts can access it.
 * Attaching a snapshot makes the snapshot accessible to configured hosts.
 */
public VNXeCommandResult attachSnap(String snapId) {
    _logger.info("attaching snap: {}", snapId);
    SnapRequests req = new SnapRequests(_khClient);
    return req.attachSnapSync(snapId);
}
Also used : SnapRequests(com.emc.storageos.vnxe.requests.SnapRequests) LunGroupSnapRequests(com.emc.storageos.vnxe.requests.LunGroupSnapRequests) FileSystemSnapRequests(com.emc.storageos.vnxe.requests.FileSystemSnapRequests) LunSnapRequests(com.emc.storageos.vnxe.requests.LunSnapRequests)

Example 2 with SnapRequests

use of com.emc.storageos.vnxe.requests.SnapRequests in project coprhd-controller by CoprHD.

the class VNXeApiClient method createSnap.

/**
 * Create snapshot for VNX Unity
 *
 * @param resourceID
 *            lun or consistency group id
 * @param name
 *            snapshot name
 * @param isReadOnly
 * @return VNXeCommandJob
 */
public VNXeCommandJob createSnap(String resourceID, String name, Boolean isReadOnly) {
    _logger.info("creating snap for :" + resourceID);
    SnapCreateParam parm = new SnapCreateParam();
    parm.setStorageResource(new VNXeBase(resourceID));
    parm.setName(name);
    if (isReadOnly != null) {
        parm.setIsReadOnly(isReadOnly);
    }
    SnapRequests req = new SnapRequests(_khClient);
    return req.createSnap(parm);
}
Also used : VNXeBase(com.emc.storageos.vnxe.models.VNXeBase) SnapRequests(com.emc.storageos.vnxe.requests.SnapRequests) LunGroupSnapRequests(com.emc.storageos.vnxe.requests.LunGroupSnapRequests) FileSystemSnapRequests(com.emc.storageos.vnxe.requests.FileSystemSnapRequests) LunSnapRequests(com.emc.storageos.vnxe.requests.LunSnapRequests) SnapCreateParam(com.emc.storageos.vnxe.models.SnapCreateParam) LunSnapCreateParam(com.emc.storageos.vnxe.models.LunSnapCreateParam) FileSystemSnapCreateParam(com.emc.storageos.vnxe.models.FileSystemSnapCreateParam)

Example 3 with SnapRequests

use of com.emc.storageos.vnxe.requests.SnapRequests in project coprhd-controller by CoprHD.

the class VNXeApiClient method detachSnap.

/**
 * Detach the snapshot so hosts can access it.
 * Attaching a snapshot makes the snapshot accessible to configured hosts.
 */
public VNXeCommandResult detachSnap(String snapId) {
    _logger.info("detaching snap: {}", snapId);
    SnapRequests req = new SnapRequests(_khClient);
    return req.detachSnapSync(snapId);
}
Also used : SnapRequests(com.emc.storageos.vnxe.requests.SnapRequests) LunGroupSnapRequests(com.emc.storageos.vnxe.requests.LunGroupSnapRequests) FileSystemSnapRequests(com.emc.storageos.vnxe.requests.FileSystemSnapRequests) LunSnapRequests(com.emc.storageos.vnxe.requests.LunSnapRequests)

Example 4 with SnapRequests

use of com.emc.storageos.vnxe.requests.SnapRequests in project coprhd-controller by CoprHD.

the class VNXeApiClient method deleteSnap.

/**
 * Delete snapshot
 *
 * @param snapId
 *            snapshot VNXe Id
 * @return VNXeCommandJob
 */
public VNXeCommandResult deleteSnap(String snapId) {
    _logger.info("deleting snap:" + snapId);
    SnapRequests req = new SnapRequests(_khClient);
    return req.deleteSnap(snapId);
}
Also used : SnapRequests(com.emc.storageos.vnxe.requests.SnapRequests) LunGroupSnapRequests(com.emc.storageos.vnxe.requests.LunGroupSnapRequests) FileSystemSnapRequests(com.emc.storageos.vnxe.requests.FileSystemSnapRequests) LunSnapRequests(com.emc.storageos.vnxe.requests.LunSnapRequests)

Example 5 with SnapRequests

use of com.emc.storageos.vnxe.requests.SnapRequests in project coprhd-controller by CoprHD.

the class VNXeApiClient method getSnapshot.

/**
 * Get snapshot by its id
 *
 * @param name
 *            snapshot name
 * @return VNXeLunSnap
 */
public Snap getSnapshot(String id) {
    _logger.info("Getting the snapshot: {}", id);
    SnapRequests req = new SnapRequests(_khClient);
    return req.getSnap(id);
}
Also used : SnapRequests(com.emc.storageos.vnxe.requests.SnapRequests) LunGroupSnapRequests(com.emc.storageos.vnxe.requests.LunGroupSnapRequests) FileSystemSnapRequests(com.emc.storageos.vnxe.requests.FileSystemSnapRequests) LunSnapRequests(com.emc.storageos.vnxe.requests.LunSnapRequests)

Aggregations

FileSystemSnapRequests (com.emc.storageos.vnxe.requests.FileSystemSnapRequests)5 LunGroupSnapRequests (com.emc.storageos.vnxe.requests.LunGroupSnapRequests)5 LunSnapRequests (com.emc.storageos.vnxe.requests.LunSnapRequests)5 SnapRequests (com.emc.storageos.vnxe.requests.SnapRequests)5 FileSystemSnapCreateParam (com.emc.storageos.vnxe.models.FileSystemSnapCreateParam)1 LunSnapCreateParam (com.emc.storageos.vnxe.models.LunSnapCreateParam)1 SnapCreateParam (com.emc.storageos.vnxe.models.SnapCreateParam)1 VNXeBase (com.emc.storageos.vnxe.models.VNXeBase)1