You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2022/04/07 11:08:52 UTC

[GitHub] [airflow] ashb commented on a diff in pull request #22737: Deprecate S3PrefixSensor

ashb commented on code in PR #22737:
URL: https://github.com/apache/airflow/pull/22737#discussion_r845007680


##########
airflow/providers/amazon/aws/sensors/s3.py:
##########
@@ -332,66 +339,32 @@ def poke(self, context: 'Context'):
         return self.is_keys_unchanged(set(self.hook.list_keys(self.bucket_name, prefix=self.prefix)))
 
 
-class S3PrefixSensor(BaseSensorOperator):
+class S3PrefixSensor(S3KeySensor):
     """
-    Waits for a prefix or all prefixes to exist. A prefix is the first part of a key,
-    thus enabling checking of constructs similar to glob ``airfl*`` or
-    SQL LIKE ``'airfl%'``. There is the possibility to precise a delimiter to
-    indicate the hierarchy or keys, meaning that the match will stop at that
-    delimiter. Current code accepts sane delimiters, i.e. characters that
-    are NOT special characters in the Python regex engine.
-
-    :param bucket_name: Name of the S3 bucket
-    :param prefix: The prefix being waited on. Relative path from bucket root level.
-    :param delimiter: The delimiter intended to show hierarchy.
-        Defaults to '/'.
-    :param aws_conn_id: a reference to the s3 connection
-    :param verify: Whether or not to verify SSL certificates for S3 connection.
-        By default SSL certificates are verified.
-        You can provide the following values:
-
-        - ``False``: do not validate SSL certificates. SSL will still be used
-                 (unless use_ssl is False), but SSL certificates will not be
-                 verified.
-        - ``path/to/cert/bundle.pem``: A filename of the CA cert bundle to uses.
-                 You can specify this argument if you want to use a different
-                 CA cert bundle than the one used by botocore.
+    This class is deprecated.
+    Please use `airflow.providers.amazon.aws.sensors.s3.S3KeySensor`.

Review Comment:
   ```suggestion
       Please use :class:`~airflow.providers.amazon.aws.sensors.s3.S3KeySensor`.
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org