Skip to main content

Function: isSchedulingResourceServed()

function isSchedulingResourceServed(
cluster: string,
apiVersions: string[],
apiName: string): Promise<boolean>;

Defined in: lib/k8s/podGroup.ts:164

Whether a cluster serves one of the scheduling.k8s.io resources.

This asks for each candidate version directly instead of using apiDiscovery, because discovery only reports the first version of each group and scheduling.k8s.io also serves v1.

Parameters​

ParameterTypeDescription
clusterstringThe cluster to check.
apiVersionsstring[]The group versions the resource may be served by, newest first.
apiNamestringThe plural name of the resource to look for.

Returns​

Promise<boolean>

true when one of the versions serves the resource.