use of com.emc.sa.asset.annotation.AssetDependencies in project coprhd-controller by CoprHD.
the class VirtualDataCenterProvider method getExportedIngestionMethod.
@Asset("exportedIngestionMethod")
@AssetDependencies({ "unmanagedBlockVirtualPool" })
public List<AssetOption> getExportedIngestionMethod(AssetOptionsContext ctx, URI virtualPoolId) {
ViPRCoreClient client = api(ctx);
BlockVirtualPoolRestRep virtualPoolRestRep = client.blockVpools().get(virtualPoolId);
List<AssetOption> options = Lists.newArrayList();
options.add(newAssetOption(IngestionMethodEnum.FULL.toString(), "unmanagedVolume.ingestMethod.full"));
if (virtualPoolRestRep.getHighAvailability() != null) {
options.add(newAssetOption(IngestionMethodEnum.VIRTUAL_VOLUMES_ONLY.toString(), "unmanagedVolume.ingestMethod.virtualVolumesOnly"));
}
return options;
}
use of com.emc.sa.asset.annotation.AssetDependencies in project coprhd-controller by CoprHD.
the class VirtualDataCenterProvider method getUnmanagedFileSystemVirtualPools.
@Asset("unmanagedFileVirtualPool")
@AssetDependencies({ "fileStorageSystem", "virtualArray", "fileIngestExportType" })
public List<AssetOption> getUnmanagedFileSystemVirtualPools(AssetOptionsContext ctx, URI storageSystem, URI virtualArray, String ingestExportType) {
Map<URI, Integer> vpools = getFileVirtualPools(listUnmanagedFilesystems(ctx, storageSystem), ingestExportType);
Map<URI, FileVirtualPoolRestRep> virtualPoolMap = FileProvider.getFileVirtualPools(api(ctx), vpools.keySet());
List<AssetOption> options = Lists.newArrayList();
for (Map.Entry<URI, Integer> entry : vpools.entrySet()) {
FileVirtualPoolRestRep vpool = virtualPoolMap.get(entry.getKey());
if (isVirtualPoolInVirtualArray(vpool, virtualArray)) {
options.add(newAssetOption(vpool.getId().toString(), "file.virtualPool.unmanaged", vpool.getName(), entry.getValue()));
}
}
AssetOptionsUtils.sortOptionsByLabel(options);
return options;
}
use of com.emc.sa.asset.annotation.AssetDependencies in project coprhd-controller by CoprHD.
the class VirtualDataCenterProvider method getUnmanagedVolumeByStorageSystemVirtualPool.
@Asset("unmanagedVolumeByStorageSystemVirtualPool")
@AssetDependencies({ "unmanagedBlockStorageSystem", "blockVirtualPool", "volumeFilter" })
public List<AssetOption> getUnmanagedVolumeByStorageSystemVirtualPool(AssetOptionsContext ctx, URI storageSystemId, URI vpool, int volumePage) {
List<AssetOption> options = Lists.newArrayList();
for (UnManagedVolumeRestRep volume : listUnmanagedVolumes(ctx, storageSystemId, vpool)) {
if (!isNonRPExported(volume.getVolumeCharacteristics())) {
options.add(toAssetOption(volume));
}
}
AssetOptionsUtils.sortOptionsByLabel(options);
return getVolumeSublist(volumePage, options);
}
use of com.emc.sa.asset.annotation.AssetDependencies in project coprhd-controller by CoprHD.
the class VirtualDataCenterProvider method getUnmanagedFileVirtualPools.
@Asset("unmanagedFileVirtualPool")
@AssetDependencies({ "fileStorageSystem" })
public List<AssetOption> getUnmanagedFileVirtualPools(AssetOptionsContext ctx, URI storageSystem) {
Map<URI, Integer> vpools = getFileVirtualPools(listUnmanagedFilesystems(ctx, storageSystem));
Map<URI, FileVirtualPoolRestRep> virtualPoolMap = FileProvider.getFileVirtualPools(api(ctx), vpools.keySet());
List<AssetOption> options = Lists.newArrayList();
for (Map.Entry<URI, Integer> entry : vpools.entrySet()) {
FileVirtualPoolRestRep vpool = virtualPoolMap.get(entry.getKey());
if (vpool != null) {
options.add(newAssetOption(vpool.getId().toString(), "file.virtualPool.unmanaged", vpool.getName(), entry.getValue()));
}
}
AssetOptionsUtils.sortOptionsByLabel(options);
return options;
}
use of com.emc.sa.asset.annotation.AssetDependencies in project coprhd-controller by CoprHD.
the class VirtualDataCenterProvider method getUnmanagedVolumeByStorageSystemVirtualPool.
@Asset("unmanagedVolumeByStorageSystemVirtualPool")
@AssetDependencies({ "unmanagedBlockStorageSystem", "blockVirtualPool" })
public List<AssetOption> getUnmanagedVolumeByStorageSystemVirtualPool(AssetOptionsContext ctx, URI storageSystemId, URI vpool) {
List<AssetOption> options = Lists.newArrayList();
for (UnManagedVolumeRestRep volume : listUnmanagedVolumes(ctx, storageSystemId, vpool)) {
if (!isNonRPExported(volume.getVolumeCharacteristics())) {
options.add(toAssetOption(volume));
}
}
AssetOptionsUtils.sortOptionsByLabel(options);
return options;
}
Aggregations