-
Notifications
You must be signed in to change notification settings - Fork 13.7k
/
__init__.py
65 lines (61 loc) · 2.77 KB
/
__init__.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
"""Executors."""
from __future__ import annotations
from airflow.utils.deprecation_tools import add_deprecated_classes
__deprecated_classes = {
"celery_executor": {
"app": "airflow.providers.celery.executors.celery_executor_utils.app",
"CeleryExecutor": "airflow.providers.celery.executors.celery_executor.CeleryExecutor",
},
"celery_kubernetes_executor": {
"CeleryKubernetesExecutor": "airflow.providers.celery.executors."
"celery_kubernetes_executor.CeleryKubernetesExecutor",
},
"dask_executor": {
"DaskExecutor": "airflow.providers.daskexecutor.executors.dask_executor.DaskExecutor",
},
"kubernetes_executor": {
"KubernetesExecutor": "airflow.providers.cncf.kubernetes."
"executors.kubernetes_executor.KubernetesExecutor",
},
"kubernetes_executor_types": {
"ALL_NAMESPACES": "airflow.providers.cncf.kubernetes."
"executors.kubernetes_executor_types.ALL_NAMESPACES",
"POD_EXECUTOR_DONE_KEY": "airflow.providers.cncf.kubernetes."
"executors.kubernetes_executor_types.POD_EXECUTOR_DONE_KEY",
},
"kubernetes_executor_utils": {
"AirflowKubernetesScheduler": "airflow.providers.cncf.kubernetes."
"executors.kubernetes_executor_utils.AirflowKubernetesScheduler",
"KubernetesJobWatcher": "airflow.providers.cncf.kubernetes."
"executors.kubernetes_executor_utils.KubernetesJobWatcher",
"ResourceVersion": "airflow.providers.cncf.kubernetes."
"executors.kubernetes_executor_utils.ResourceVersion",
},
"local_kubernetes_executor": {
"LocalKubernetesExecutor": "airflow.providers.cncf.kubernetes.executors.LocalKubernetesExecutor",
},
}
add_deprecated_classes(
__deprecated_classes,
__name__,
{},
"For Celery executors, the `celery` provider should be >= 3.3.0. "
"For Kubernetes executors, the `cncf.kubernetes` provider should be >= 7.4.0 for that. "
"For Dask executors, any version of `daskexecutor` provider is needed.",
)