Class WorkerResourceSpec
- java.lang.Object
-
- org.apache.flink.runtime.resourcemanager.WorkerResourceSpec
-
- All Implemented Interfaces:
Serializable
public final class WorkerResourceSpec extends Object implements Serializable
Resource specification of a worker, mainly used by SlotManager requesting from ResourceManager.- See Also:
- Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
WorkerResourceSpec.Builder
Builder forWorkerResourceSpec
.
-
Field Summary
Fields Modifier and Type Field Description static WorkerResourceSpec
ZERO
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(Object obj)
static WorkerResourceSpec
fromTaskExecutorProcessSpec(TaskExecutorProcessSpec taskExecutorProcessSpec)
static WorkerResourceSpec
fromTotalResourceProfile(ResourceProfile resourceProfile, int numSlots)
CPUResource
getCpuCores()
Map<String,ExternalResource>
getExtendedResources()
MemorySize
getManagedMemSize()
MemorySize
getNetworkMemSize()
int
getNumSlots()
MemorySize
getTaskHeapSize()
MemorySize
getTaskOffHeapSize()
MemorySize
getTotalMemSize()
int
hashCode()
String
toString()
-
-
-
Field Detail
-
ZERO
public static final WorkerResourceSpec ZERO
-
-
Method Detail
-
fromTaskExecutorProcessSpec
public static WorkerResourceSpec fromTaskExecutorProcessSpec(TaskExecutorProcessSpec taskExecutorProcessSpec)
-
fromTotalResourceProfile
public static WorkerResourceSpec fromTotalResourceProfile(ResourceProfile resourceProfile, int numSlots)
-
getCpuCores
public CPUResource getCpuCores()
-
getTaskHeapSize
public MemorySize getTaskHeapSize()
-
getTaskOffHeapSize
public MemorySize getTaskOffHeapSize()
-
getNetworkMemSize
public MemorySize getNetworkMemSize()
-
getManagedMemSize
public MemorySize getManagedMemSize()
-
getTotalMemSize
public MemorySize getTotalMemSize()
-
getNumSlots
public int getNumSlots()
-
getExtendedResources
public Map<String,ExternalResource> getExtendedResources()
-
-