beam-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF GitHub Bot (JIRA)" <>
Subject [jira] [Work logged] (BEAM-3418) Python Fnapi - Support Multiple SDK workers on a single VM
Date Tue, 20 Mar 2018 20:40:00 GMT


ASF GitHub Bot logged work on BEAM-3418:

                Author: ASF GitHub Bot
            Created on: 20/Mar/18 20:39
            Start Date: 20/Mar/18 20:39
    Worklog Time Spent: 10m 
      Work Description: aaltay commented on a change in pull request #4587: [BEAM-3418] Send
worker_id in all grpc channels to runner harness

 File path: sdks/python/apache_beam/runners/worker/
 @@ -0,0 +1,54 @@
+# 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
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# See the License for the specific language governing permissions and
+# limitations under the License.
+"""Client Interceptor to inject worker_id"""
+from __future__ import absolute_import
+from __future__ import division
+from __future__ import print_function
+import collections
+import os
+import uuid
+import grpc
+class _ClientCallDetails(
+    collections.namedtuple('_ClientCallDetails',
+                           ('method', 'timeout', 'metadata', 'credentials')),
+    grpc.ClientCallDetails):
+  pass
+class WorkerIdInterceptor(grpc.StreamStreamClientInterceptor):
+  # Unique worker Id for this worker.
+  _worker_id = os.environ['WORKER_ID'] if os.environ.has_key(
 Review comment:
   Do we want to fail if WORKER_ID is not found?

This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:

Issue Time Tracking

    Worklog Id:     (was: 82469)
    Time Spent: 1h 20m  (was: 1h 10m)

> Python Fnapi - Support Multiple SDK workers on a single VM
> ----------------------------------------------------------
>                 Key: BEAM-3418
>                 URL:
>             Project: Beam
>          Issue Type: Improvement
>          Components: sdk-py-harness
>            Reporter: Ankur Goenka
>            Assignee: Ankur Goenka
>            Priority: Major
>              Labels: performance, portability
>          Time Spent: 1h 20m
>  Remaining Estimate: 0h
> Support multiple python SDK process on a VM to fully utilize a machine.
> Each SDK Process will work in isolation and interact with Runner Harness independently.

This message was sent by Atlassian JIRA

View raw message