Search in sources :

Example 1 with DeactivateFileSnapshotExportRule

use of com.emc.sa.service.vipr.file.tasks.DeactivateFileSnapshotExportRule in project coprhd-controller by CoprHD.

the class FileStorageUtils method createFileSnapshotExport.

public static String createFileSnapshotExport(URI fileSnapshotId, String comment, String security, String permissions, String rootUser, List<String> exportHosts, String subDirectory) {
    Task<FileSnapshotRestRep> task = execute(new CreateFileSnapshotExport(fileSnapshotId, comment, NFS_PROTOCOL, security, permissions, rootUser, exportHosts, subDirectory));
    addAffectedResource(task);
    String exportId = task.getResourceId().toString();
    addRollback(new DeactivateFileSnapshotExportRule(fileSnapshotId, true, null));
    logInfo("file.storage.export.task", exportId, task.getOpId());
    return exportId;
}
Also used : FileSnapshotRestRep(com.emc.storageos.model.file.FileSnapshotRestRep) DeactivateFileSnapshotExportRule(com.emc.sa.service.vipr.file.tasks.DeactivateFileSnapshotExportRule) CreateFileSnapshotExport(com.emc.sa.service.vipr.file.tasks.CreateFileSnapshotExport)

Example 2 with DeactivateFileSnapshotExportRule

use of com.emc.sa.service.vipr.file.tasks.DeactivateFileSnapshotExportRule in project coprhd-controller by CoprHD.

the class FileStorageUtils method deactivateSnapshotExport.

public static void deactivateSnapshotExport(URI fileSnapshotId, Boolean allDir, String subDir) {
    Task<FileSnapshotRestRep> task = execute(new DeactivateFileSnapshotExportRule(fileSnapshotId, allDir, subDir));
    addAffectedResource(task);
}
Also used : FileSnapshotRestRep(com.emc.storageos.model.file.FileSnapshotRestRep) DeactivateFileSnapshotExportRule(com.emc.sa.service.vipr.file.tasks.DeactivateFileSnapshotExportRule)

Aggregations

DeactivateFileSnapshotExportRule (com.emc.sa.service.vipr.file.tasks.DeactivateFileSnapshotExportRule)2 FileSnapshotRestRep (com.emc.storageos.model.file.FileSnapshotRestRep)2 CreateFileSnapshotExport (com.emc.sa.service.vipr.file.tasks.CreateFileSnapshotExport)1