11
11
import kubernetes_asyncio as kubernetes
12
12
from importlib_metadata import entry_points
13
13
from kubernetes_asyncio .client import ApiException
14
- from kr8s .asyncio .objects import APIObject
15
14
15
+ from dask_kubernetes .operator .objects import DaskCluster
16
16
from dask_kubernetes .common .auth import ClusterAuth
17
17
from dask_kubernetes .common .networking import get_scheduler_address
18
18
from distributed .core import rpc , clean_exception
@@ -39,45 +39,6 @@ class SchedulerCommError(Exception):
39
39
"""Raised when unable to communicate with a scheduler."""
40
40
41
41
42
- class DaskCluster (APIObject ):
43
- version = "kubernetes.dask.org/v1"
44
- endpoint = "daskclusters"
45
- kind = "DaskCluster"
46
- plural = "daskclusters"
47
- singular = "daskcluster"
48
- namespaced = True
49
- scalable = True
50
- scalable_spec = "worker.replicas"
51
-
52
-
53
- class DaskWorkerGroup (APIObject ):
54
- version = "kubernetes.dask.org/v1"
55
- endpoint = "daskworkergroups"
56
- kind = "DaskWorkerGroup"
57
- plural = "daskworkergroups"
58
- singular = "daskworkergroup"
59
- namespaced = True
60
- scalable = True
61
-
62
-
63
- class DaskAutoscaler (APIObject ):
64
- version = "kubernetes.dask.org/v1"
65
- endpoint = "daskautoscalers"
66
- kind = "DaskAutoscaler"
67
- plural = "daskautoscalers"
68
- singular = "daskautoscaler"
69
- namespaced = True
70
-
71
-
72
- class DaskJob (APIObject ):
73
- version = "kubernetes.dask.org/v1"
74
- endpoint = "daskjobs"
75
- kind = "DaskJob"
76
- plural = "daskjobs"
77
- singular = "daskjob"
78
- namespaced = True
79
-
80
-
81
42
def _get_annotations (meta ):
82
43
return {
83
44
annotation_key : annotation_value
0 commit comments