Taragolis commented on code in PR #29168:
URL: https://github.com/apache/airflow/pull/29168#discussion_r1087077136


##########
airflow/providers/amazon/aws/operators/neptune.py:
##########
@@ -0,0 +1,152 @@
+#
+# 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.
+from __future__ import annotations
+
+import json
+from typing import TYPE_CHECKING
+
+from airflow.models import BaseOperator
+from airflow.providers.amazon.aws.hooks.neptune import NeptuneHook
+from airflow.providers.amazon.aws.utils.neptune import NeptuneDbType
+
+if TYPE_CHECKING:
+    from airflow.utils.context import Context
+
+
+class NeptuneStartDbOperator(BaseOperator):
+    """
+    Starts a Neptune DB cluster
+
+    .. seealso::
+        For more information on how to use this operator, take a look at the 
guide:
+        :ref:`howto/operator:NeptuneStartDbOperator`
+
+    :param db_identifier: The AWS identifier of the DB to start
+    :param db_type: Type of the DB - either "instance" or "cluster" (default: 
"cluster")
+    :param aws_conn_id: The Airflow connection used for AWS credentials. 
(default: "aws_default")
+    :param wait_for_completion:  If True, waits for DB to start. (default: 
True)
+
+    Note: In boto3 supports starting db operator only for cluster and not for 
instance db_type.
+        So, default is maintained as Cluster, however it can be extended once 
instance db_type is available,
+        similar to RDS database implementation
+    """
+
+    template_fields = ("db_identifier", "db_type")
+    STATES_FOR_STARTING = ["available", "starting"]
+
+    def __init__(
+        self,
+        *,
+        db_identifier: str,
+        db_type: NeptuneDbType | str = NeptuneDbType.CLUSTER,
+        aws_conn_id: str = "aws_default",
+        region_name: str = "us-east-1",

Review Comment:
   We should  not define default region_name
   
   ```suggestion
           region_name: str | None = None,
   ```
   



-- 
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-unsubscr...@airflow.apache.org

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

Reply via email to