Interface MorpheusStorageVolumeGroupService
- All Superinterfaces:
MorpheusDataQueryService<StorageVolumeGroup>,MorpheusDataService<StorageVolumeGroup,,StorageVolumeGroupIdentityProjection> MorpheusIdentityService<StorageVolumeGroupIdentityProjection>
StorageVolumeGroup entities in Morpheus.
StorageVolumeGroup represents a logical grouping of storage volumes that can be managed together for consistent snapshot and replication operations. This service provides:
- CRUD operations for volume groups
- Volume membership management (add/remove volumes)
- Sync operations for plugin-based data synchronization
- Provider delegation for storage-level operations
When volumes are added or removed from a group, the operation is delegated to the
appropriate StorageProviderVolumeGroupsFacet implementation
so plugins can take action at the storage array level.
- Since:
- 1.4.0
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptiondefault io.reactivex.rxjava3.core.Single<ServiceResponse<StorageVolumeGroup>>addVolume(StorageVolumeGroup volumeGroup, StorageVolume volume) Add a single volume to a volume group.io.reactivex.rxjava3.core.Single<ServiceResponse<StorageVolumeGroup>>addVolumes(StorageVolumeGroup volumeGroup, List<StorageVolume> volumes, Map<String, Object> opts) Add volumes to a volume group.io.reactivex.rxjava3.core.Single<ServiceResponse<Boolean>>canDelete(StorageVolumeGroup volumeGroup) Check if a volume group can be deleted.io.reactivex.rxjava3.core.Single<Boolean>create(List<StorageVolumeGroup> volumeGroups) Create volume groups in bulk during sync operations.io.reactivex.rxjava3.core.Single<ServiceResponse<StorageVolumeGroup>>createVolumeGroup(StorageServer storageServer, StorageVolumeGroup volumeGroup, Map<String, Object> opts) Create a new volume group on the storage server.io.reactivex.rxjava3.core.Single<ServiceResponse>deleteVolumeGroup(StorageVolumeGroup volumeGroup, Map<String, Object> opts) Delete a volume group.io.reactivex.rxjava3.core.Single<StorageVolumeGroup>findByExternalId(Long storageServerId, String externalId) Find a volume group by external ID within a storage server.io.reactivex.rxjava3.core.Single<StorageVolumeGroup>findByName(Long storageServerId, String name) Find a volume group by name within a storage server.io.reactivex.rxjava3.core.Observable<StorageVolumeGroup>listByStorageServer(StorageServer storageServer) List all volume groups for a storage server.io.reactivex.rxjava3.core.Observable<StorageVolumeGroup>listByStorageServerId(Long storageServerId) List all volume groups for a storage server by ID.io.reactivex.rxjava3.core.Observable<StorageVolumeGroupIdentityProjection>listIdentityProjections(StorageServer storageServer) Get a list of StorageVolumeGroup projections based on StorageServer.io.reactivex.rxjava3.core.Observable<StorageVolumeGroupIdentityProjection>listIdentityProjections(Long storageServerId) Get a list of StorageVolumeGroup projections based on StorageServer id.io.reactivex.rxjava3.core.Single<Boolean>remove(List<StorageVolumeGroupIdentityProjection> volumeGroups) Remove volume groups in bulk during sync operations.default io.reactivex.rxjava3.core.Single<ServiceResponse<StorageVolumeGroup>>removeVolume(StorageVolumeGroup volumeGroup, StorageVolume volume) Remove a single volume from a volume group.io.reactivex.rxjava3.core.Single<ServiceResponse<StorageVolumeGroup>>removeVolumes(StorageVolumeGroup volumeGroup, List<StorageVolume> volumes, Map<String, Object> opts) Remove volumes from a volume group.io.reactivex.rxjava3.core.Single<Boolean>save(List<StorageVolumeGroup> volumeGroups) Save (update) volume groups in bulk during sync operations.io.reactivex.rxjava3.core.Single<ServiceResponse<StorageVolumeGroup>>updateVolumeGroup(StorageVolumeGroup volumeGroup, Map<String, Object> opts) Update an existing volume group.Methods inherited from interface com.morpheusdata.core.MorpheusDataQueryService
count, find, get, list, list, listById, listOptions, listOptions, searchMethods inherited from interface com.morpheusdata.core.MorpheusDataService
bulkCreate, bulkRemove, bulkSave, create, remove, saveMethods inherited from interface com.morpheusdata.core.MorpheusIdentityService
getIdentityProperties, listIdentityProjections
-
Method Details
-
listIdentityProjections
io.reactivex.rxjava3.core.Observable<StorageVolumeGroupIdentityProjection> listIdentityProjections(Long storageServerId) Get a list of StorageVolumeGroup projections based on StorageServer id.- Parameters:
storageServerId- the storage server to filter by- Returns:
- Observable stream of identity projections
-
listIdentityProjections
io.reactivex.rxjava3.core.Observable<StorageVolumeGroupIdentityProjection> listIdentityProjections(StorageServer storageServer) Get a list of StorageVolumeGroup projections based on StorageServer.- Parameters:
storageServer- the storage server to filter by- Returns:
- Observable stream of identity projections
-
listByStorageServer
io.reactivex.rxjava3.core.Observable<StorageVolumeGroup> listByStorageServer(StorageServer storageServer) List all volume groups for a storage server.- Parameters:
storageServer- the storage server- Returns:
- Observable stream of volume groups
-
listByStorageServerId
io.reactivex.rxjava3.core.Observable<StorageVolumeGroup> listByStorageServerId(Long storageServerId) List all volume groups for a storage server by ID.- Parameters:
storageServerId- the storage server ID- Returns:
- Observable stream of volume groups
-
findByExternalId
io.reactivex.rxjava3.core.Single<StorageVolumeGroup> findByExternalId(Long storageServerId, String externalId) Find a volume group by external ID within a storage server.- Parameters:
storageServerId- the storage server IDexternalId- the external ID from the storage system- Returns:
- Single containing the volume group if found
-
findByName
Find a volume group by name within a storage server.- Parameters:
storageServerId- the storage server IDname- the volume group name- Returns:
- Single containing the volume group if found
-
addVolumes
io.reactivex.rxjava3.core.Single<ServiceResponse<StorageVolumeGroup>> addVolumes(StorageVolumeGroup volumeGroup, List<StorageVolume> volumes, Map<String, Object> opts) Add volumes to a volume group.This operation validates that:
- The volumes are not already in another group
- The volumes belong to the same storage server as the group
StorageProviderVolumeGroupsFacet.addVolumesToVolumeGroup(com.morpheusdata.model.StorageServer, com.morpheusdata.model.StorageVolumeGroup, java.util.List<com.morpheusdata.model.StorageVolume>, java.util.Map<java.lang.String, java.lang.Object>)so the plugin can update the storage array.- Parameters:
volumeGroup- the volume group to add volumes tovolumes- the volumes to addopts- additional options for the operation- Returns:
- ServiceResponse indicating success/failure with updated volume group
-
addVolume
default io.reactivex.rxjava3.core.Single<ServiceResponse<StorageVolumeGroup>> addVolume(StorageVolumeGroup volumeGroup, StorageVolume volume) Add a single volume to a volume group.- Parameters:
volumeGroup- the volume groupvolume- the volume to add- Returns:
- ServiceResponse indicating success/failure
-
removeVolumes
io.reactivex.rxjava3.core.Single<ServiceResponse<StorageVolumeGroup>> removeVolumes(StorageVolumeGroup volumeGroup, List<StorageVolume> volumes, Map<String, Object> opts) Remove volumes from a volume group.The operation is delegated to the storage provider plugin via
StorageProviderVolumeGroupsFacet.removeVolumesFromVolumeGroup(com.morpheusdata.model.StorageServer, com.morpheusdata.model.StorageVolumeGroup, java.util.List<com.morpheusdata.model.StorageVolume>, java.util.Map<java.lang.String, java.lang.Object>)so the plugin can update the storage array.- Parameters:
volumeGroup- the volume group to remove volumes fromvolumes- the volumes to removeopts- additional options for the operation- Returns:
- ServiceResponse indicating success/failure with updated volume group
-
removeVolume
default io.reactivex.rxjava3.core.Single<ServiceResponse<StorageVolumeGroup>> removeVolume(StorageVolumeGroup volumeGroup, StorageVolume volume) Remove a single volume from a volume group.- Parameters:
volumeGroup- the volume groupvolume- the volume to remove- Returns:
- ServiceResponse indicating success/failure
-
createVolumeGroup
io.reactivex.rxjava3.core.Single<ServiceResponse<StorageVolumeGroup>> createVolumeGroup(StorageServer storageServer, StorageVolumeGroup volumeGroup, Map<String, Object> opts) Create a new volume group on the storage server.This operation delegates to the storage provider plugin via
StorageProviderVolumeGroupsFacet.createVolumeGroup(com.morpheusdata.model.StorageServer, com.morpheusdata.model.StorageVolumeGroup, java.util.Map<java.lang.String, java.lang.Object>)to create the group on the actual storage array.- Parameters:
storageServer- the storage server to create the group onvolumeGroup- the volume group to createopts- additional options- Returns:
- ServiceResponse with the created volume group
-
updateVolumeGroup
io.reactivex.rxjava3.core.Single<ServiceResponse<StorageVolumeGroup>> updateVolumeGroup(StorageVolumeGroup volumeGroup, Map<String, Object> opts) Update an existing volume group.Uses optimistic locking via the version field. If the version has changed since the group was loaded, the update will fail with a conflict error.
- Parameters:
volumeGroup- the volume group to updateopts- additional options- Returns:
- ServiceResponse with the updated volume group
-
deleteVolumeGroup
io.reactivex.rxjava3.core.Single<ServiceResponse> deleteVolumeGroup(StorageVolumeGroup volumeGroup, Map<String, Object> opts) Delete a volume group.This operation will fail if:
- The group has active replication relationships (FR-066)
- The group still contains volumes (depending on force flag)
- Parameters:
volumeGroup- the volume group to deleteopts- additional options (e.g., "force" to remove volumes first)- Returns:
- ServiceResponse indicating success/failure
-
canDelete
io.reactivex.rxjava3.core.Single<ServiceResponse<Boolean>> canDelete(StorageVolumeGroup volumeGroup) Check if a volume group can be deleted.Validates that:
- No active replication relationships exist
- Group is not in a protected state
- Parameters:
volumeGroup- the volume group to check- Returns:
- ServiceResponse with canDelete=true/false and reason if not deletable
-
create
Create volume groups in bulk during sync operations.- Specified by:
createin interfaceMorpheusDataService<StorageVolumeGroup,StorageVolumeGroupIdentityProjection> - Parameters:
volumeGroups- the volume groups to create- Returns:
- success indicator
- See Also:
-
save
Save (update) volume groups in bulk during sync operations.- Specified by:
savein interfaceMorpheusDataService<StorageVolumeGroup,StorageVolumeGroupIdentityProjection> - Parameters:
volumeGroups- the volume groups to save- Returns:
- success indicator
- See Also:
-
remove
io.reactivex.rxjava3.core.Single<Boolean> remove(List<StorageVolumeGroupIdentityProjection> volumeGroups) Remove volume groups in bulk during sync operations.- Specified by:
removein interfaceMorpheusDataService<StorageVolumeGroup,StorageVolumeGroupIdentityProjection> - Parameters:
volumeGroups- the volume groups to remove- Returns:
- success indicator
- See Also:
-