Skip to main content

ElasticConfig

Interface for unified elastic config handling across plugin version v0 and v1. This interface should always be aligned with the ElasticConfig defined in flyteidl.

Methods


GetMinReplicas()

@classmethod
def GetMinReplicas() - > int32

Fetches the minimum number of replicas for the elastic configuration. Callers use this to determine the lower bound for scaling.

Returns

TypeDescription
int32The minimum number of replicas as an integer.

GetMaxReplicas()

@classmethod
def GetMaxReplicas() - > int32

Fetches the maximum number of replicas for the elastic configuration. Callers use this to determine the upper bound for scaling.

Returns

TypeDescription
int32The maximum number of replicas as an integer.

GetNprocPerNode()

@classmethod
def GetNprocPerNode() - > int32

Fetches the number of processes per node for the elastic configuration. Callers use this to configure the parallelism on each node.

Returns

TypeDescription
int32The number of processes per node as an integer.

GetMaxRestarts()

@classmethod
def GetMaxRestarts() - > int32

Fetches the maximum number of restarts allowed for the elastic configuration. Callers use this to set fault tolerance limits.

Returns

TypeDescription
int32The maximum number of restarts as an integer.

GetRdzvBackend()

@classmethod
def GetRdzvBackend() - > string

Fetches the rendezvous backend string for the elastic configuration. Callers use this to identify the backend used for coordination.

Returns

TypeDescription
stringThe rendezvous backend as a string.