robertwb commented on a change in pull request #17189:
URL: https://github.com/apache/beam/pull/17189#discussion_r836871427



##########
File path: sdks/python/apache_beam/runners/dataflow/dataflow_job_service.py
##########
@@ -0,0 +1,100 @@
+#
+# 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.
+#
+
+import argparse
+import logging
+import sys
+import time
+import traceback
+
+from apache_beam.options import pipeline_options
+from apache_beam.portability.api import beam_artifact_api_pb2_grpc
+from apache_beam.portability.api import beam_runner_api_pb2
+from apache_beam.portability.api import beam_fn_api_pb2_grpc
+from apache_beam.portability.api import beam_job_api_pb2
+from apache_beam.portability.api import beam_job_api_pb2_grpc
+from apache_beam.portability.api import beam_provision_api_pb2
+from apache_beam.portability.api import endpoints_pb2
+from apache_beam.runners.dataflow import dataflow_runner
+from apache_beam.runners.job import utils as job_utils
+from apache_beam.runners.portability import abstract_job_service
+from apache_beam.runners.portability import local_job_service
+from apache_beam.runners.portability import local_job_service_main
+from apache_beam.runners.portability import portable_runner
+from apache_beam.runners.portability.fn_api_runner import fn_runner
+
+_LOGGER = logging.getLogger(__name__)
+
+
+class DataflowBeamJob(local_job_service.BeamJob):

Review comment:
       I've pulled the choice of class into an argument of run, so this code 
could be re-used as well. 




-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to