airflow.providers.amazon.aws.operators.base_aws¶
Classes¶
Base AWS (Amazon) Operator Class to build operators on top of AWS Hooks. |
Module Contents¶
- class airflow.providers.amazon.aws.operators.base_aws.AwsBaseOperator(*, aws_conn_id='aws_default', region_name=None, verify=None, botocore_config=None, region=NOTSET, **kwargs)[source]¶
Bases:
airflow.models.BaseOperator
,airflow.providers.amazon.aws.utils.mixins.AwsBaseHookMixin
[airflow.providers.amazon.aws.utils.mixins.AwsHookType
]Base AWS (Amazon) Operator Class to build operators on top of AWS Hooks.
Warning
Only for internal usage, this class might be changed, renamed or removed in the future without any further notice.
- Examples:
from airflow.providers.amazon.aws.hooks.foo_bar import FooBarThinHook, FooBarThickHook class AwsFooBarOperator(AwsBaseOperator[FooBarThinHook]): aws_hook_class = FooBarThinHook def execute(self, context): pass class AwsFooBarOperator2(AwsBaseOperator[FooBarThickHook]): aws_hook_class = FooBarThickHook def __init__(self, *, spam: str, **kwargs): super().__init__(**kwargs) self.spam = spam @property def _hook_parameters(self): return {**super()._hook_parameters, "spam": self.spam} def execute(self, context): pass
- Parameters:
aws_conn_id (str | None) – The Airflow connection used for AWS credentials. If this is
None
or empty then the default boto3 behaviour is used. If running Airflow in a distributed manner and aws_conn_id is None or empty, then default boto3 configuration would be used (and must be maintained on each worker node).region_name (str | None) – AWS region_name. If not specified then the default boto3 behaviour is used.
verify (bool | str | None) – Whether or not to verify SSL certificates. See: https://boto3.amazonaws.com/v1/documentation/api/latest/reference/core/session.html
botocore_config (dict | None) – Configuration dictionary (key-values) for botocore client. See: https://botocore.amazonaws.com/v1/documentation/api/latest/reference/config.html
- template_fields: collections.abc.Sequence[str][source]¶