Documentation
¶
Index ¶
- Constants
- Variables
- func FieldPatch(path string, value any, options ...FieldPatchOption) (client.Patch, error)
- func Keys[K comparable, V any](items map[K]V) []K
- func MergeTolerations(tolerations []corev1.Toleration, toleration corev1.Toleration) []corev1.Toleration
- func NamespacedNameFromString(qualifiedName string) types.NamespacedName
- func NewTaintNodeBridged(schedulerName string) *corev1.Taint
- func NewTolerationNodeBridged(schedulerName string) *corev1.Toleration
- func Values[K comparable, V any](items map[K]V) []V
- type FieldPatchOption
Constants ¶
const ( // TaintKeyBridgedNode will be added when nodes detected as bridged, // containing co-located kubelet and slurmd services, and removed // when detected as no longer bridged. TaintKeyBridgedNode = "slinky.slurm.net/managed-node" )
Variables ¶
var ( // TaintNodeBridged will mark a node such that: // - Any already-running pods that do not tolerate the taint will be evicted. // Currently enforced by the Kubernetes NodeController. // - Indicates the node is being managed by the named slurm-bridge scheduler. TaintNodeBridged = corev1.Taint{ Key: TaintKeyBridgedNode, Effect: corev1.TaintEffectNoExecute, } )
var ( // TolerationNodeBridged is used to mark pods such that they can run on the // slurm-bridge marked nodes. TolerationNodeBridged = corev1.Toleration{ Key: TaintNodeBridged.Key, Operator: corev1.TolerationOpEqual, Effect: TaintNodeBridged.Effect, } )
Functions ¶
func FieldPatch ¶ added in v1.3.0
FieldPatch adds or replaces the field at path. Path is a JSON Pointer whose parent must exist. Without options, the patch has no identity precondition.
func MergeTolerations ¶
func MergeTolerations(tolerations []corev1.Toleration, toleration corev1.Toleration) []corev1.Toleration
func NamespacedNameFromString ¶
func NamespacedNameFromString(qualifiedName string) types.NamespacedName
func NewTaintNodeBridged ¶
func NewTolerationNodeBridged ¶
func NewTolerationNodeBridged(schedulerName string) *corev1.Toleration
Types ¶
type FieldPatchOption ¶ added in v1.3.0
type FieldPatchOption func(*fieldPatchOptions)
FieldPatchOption configures preconditions for a field patch.
func WithUIDPrecondition ¶ added in v1.3.0
func WithUIDPrecondition(uid types.UID) FieldPatchOption
WithUIDPrecondition requires the object to retain this UID. The check and field update execute atomically in one PATCH, without resource-version locking.
Directories
¶
| Path | Synopsis |
|---|---|
|
Package controllercheck explores generated controller lifecycles against a shared contract.
|
Package controllercheck explores generated controller lifecycles against a shared contract. |
|
Package slurmconstraint composes Slurm job constraint (feature) expressions.
|
Package slurmconstraint composes Slurm job constraint (feature) expressions. |
|
Package timelimit parses the values accepted by the Slurm job time limit annotation into the whole minutes that Slurm's TimeLimit field expects.
|
Package timelimit parses the values accepted by the Slurm job time limit annotation into the whole minutes that Slurm's TimeLimit field expects. |