Interface CompositeDiskUsageData
-
- All Superinterfaces:
DiskUsageDataReader
- All Known Implementing Classes:
CompositeDiskUsageDataImpl
public interface CompositeDiskUsageData extends DiskUsageDataReader
Stores disk usage data for a single entity in several storages- Since:
- 2020.1
- See Also:
ArtifactStorageDiskUsageInfo
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description CompositeDiskUsageData
add(CompositeDiskUsageData other, boolean mergePerBuildData)
Summarizes two composited disk usage data instancesCompositeDiskUsageData
add(DiskUsageData other, boolean mergePerBuildData, String storageId)
Adds disk usage data to the storage with a given idCompositeDiskUsageData
cleanEmptyStorages()
Cleans empty data, saved in this storageCompositeDiskUsageData
clone()
boolean
containsData()
Optional<DiskUsageData>
getDiskUsageByStorageId(String storageId)
Map<String,DiskUsageData>
getDiskUsageData()
CompositeDiskUsageData
subtract(CompositeDiskUsageData other)
Excludes data of the other instanceCompositeDiskUsageData
subtract(DiskUsageData other, String storageId)
Excludes disk usage data from the storage with a given id-
Methods inherited from interface jetbrains.buildServer.serverSide.statistics.diskusage.DiskUsageDataReader
getArtifactSize, getBuildsData, getBuildsWithHugeLogsIds, getCleanedSize, getEntityId, getInternalArtifactsSize, getLastUpdatedDate, getLogSize, getNonBuilds, getVersion, isUpdating
-
-
-
-
Method Detail
-
clone
@NotNull CompositeDiskUsageData clone()
- Returns:
- full clone of this instance
-
getDiskUsageByStorageId
@NotNull Optional<DiskUsageData> getDiskUsageByStorageId(@NotNull String storageId)
- Parameters:
storageId
-- Returns:
- DiskUsageData for a particular storage with given id
-
getDiskUsageData
@NotNull Map<String,DiskUsageData> getDiskUsageData()
- Returns:
- mapping from all storage ids, which info is stored in the instance, to the particular data
-
add
@NotNull CompositeDiskUsageData add(@NotNull CompositeDiskUsageData other, boolean mergePerBuildData)
Summarizes two composited disk usage data instances- Parameters:
other
-mergePerBuildData
- true if information about saved builds should be merged as well- Returns:
- merged instance
-
subtract
@NotNull CompositeDiskUsageData subtract(@NotNull CompositeDiskUsageData other)
Excludes data of the other instance- Parameters:
other
-- Returns:
- resulted instance
-
add
@NotNull CompositeDiskUsageData add(@NotNull DiskUsageData other, boolean mergePerBuildData, @NotNull String storageId)
Adds disk usage data to the storage with a given id- Parameters:
other
- data to addmergePerBuildData
- true if information about saved builds should be merged as wellstorageId
- target storage id- Returns:
- resulted instance
-
subtract
@NotNull CompositeDiskUsageData subtract(@NotNull DiskUsageData other, @NotNull String storageId)
Excludes disk usage data from the storage with a given id- Parameters:
other
- data to excludestorageId
- target storage id- Returns:
- resulted instance
-
containsData
boolean containsData()
- Returns:
- true if this instance contains any data
-
cleanEmptyStorages
@NotNull CompositeDiskUsageData cleanEmptyStorages()
Cleans empty data, saved in this storage- Returns:
- resulted instance
-
-