Package com.morpheusdata.model
Class ServerStatsData
java.lang.Object
com.morpheusdata.model.ServerStatsData
Representation of server statistics data for a specific point in time.
Used to track historical metrics for compute servers including CPU, memory, and storage usage.
This is a POJO (Plain Old Java Object) that encapsulates the server metrics data.
- Since:
- 1.2.14
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the CPU usage as a percentage (0-100)getDate()Get the timestamp for this stats data pointGet the free memory in bytesGet the free storage in bytesgetId()Get the compute server IDGet the maximum memory available in bytesGet the maximum storage available in bytesGet whether the server is runningGet the used memory in bytesGet the used storage in bytesvoidsetCpuUsage(Float cpuUsage) Set the CPU usage as a percentage (0-100)voidSet the timestamp for this stats data pointvoidsetFreeMemory(Long freeMemory) Set the free memory in bytesvoidsetFreeStorage(Long freeStorage) Set the free storage in bytesvoidSet the compute server IDvoidsetMaxMemory(Long maxMemory) Set the maximum memory available in bytesvoidsetMaxStorage(Long maxStorage) Set the maximum storage available in bytesvoidsetRunning(Boolean running) Set whether the server is runningvoidsetUsedMemory(Long usedMemory) Set the used memory in bytesvoidsetUsedStorage(Long usedStorage) Set the used storage in bytes
-
Field Details
-
id
-
date
-
usedMemory
-
maxMemory
-
freeMemory
-
maxStorage
-
usedStorage
-
freeStorage
-
cpuUsage
-
running
-
-
Constructor Details
-
ServerStatsData
public ServerStatsData()Default constructor
-
-
Method Details
-
getId
Get the compute server ID- Returns:
- the server ID
-
setId
Set the compute server ID- Parameters:
id- the server ID
-
getDate
Get the timestamp for this stats data point- Returns:
- the date/time of the stats
-
setDate
Set the timestamp for this stats data point- Parameters:
date- the date/time of the stats
-
getUsedMemory
Get the used memory in bytes- Returns:
- used memory in bytes
-
setUsedMemory
Set the used memory in bytes- Parameters:
usedMemory- used memory in bytes
-
getMaxMemory
Get the maximum memory available in bytes- Returns:
- max memory in bytes
-
setMaxMemory
Set the maximum memory available in bytes- Parameters:
maxMemory- max memory in bytes
-
getFreeMemory
Get the free memory in bytes- Returns:
- free memory in bytes
-
setFreeMemory
Set the free memory in bytes- Parameters:
freeMemory- free memory in bytes
-
getMaxStorage
Get the maximum storage available in bytes- Returns:
- max storage in bytes
-
setMaxStorage
Set the maximum storage available in bytes- Parameters:
maxStorage- max storage in bytes
-
getUsedStorage
Get the used storage in bytes- Returns:
- used storage in bytes
-
setUsedStorage
Set the used storage in bytes- Parameters:
usedStorage- used storage in bytes
-
getFreeStorage
Get the free storage in bytes- Returns:
- free storage in bytes
-
setFreeStorage
Set the free storage in bytes- Parameters:
freeStorage- free storage in bytes
-
getCpuUsage
Get the CPU usage as a percentage (0-100)- Returns:
- CPU usage percentage
-
setCpuUsage
Set the CPU usage as a percentage (0-100)- Parameters:
cpuUsage- CPU usage percentage
-
getRunning
Get whether the server is running- Returns:
- true if the server is running, false otherwise
-
setRunning
Set whether the server is running- Parameters:
running- true if the server is running, false otherwise
-