[
https://issues.apache.org/jira/browse/BEAM-3645?focusedWorklogId=281092&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-281092
]
ASF GitHub Bot logged work on BEAM-3645:
----------------------------------------
Author: ASF GitHub Bot
Created on: 23/Jul/19 15:20
Start Date: 23/Jul/19 15:20
Worklog Time Spent: 10m
Work Description: robertwb commented on pull request #8979: [BEAM-3645]
add multiplexing for python FnApiRunner
URL: https://github.com/apache/beam/pull/8979#discussion_r306353009
##########
File path: sdks/python/apache_beam/runners/portability/fn_api_runner.py
##########
@@ -82,6 +82,54 @@
beam.transforms.window.GlobalWindows.windowed_value(b''))
+class ConnectionHandler(object):
+
+ _conn_handlers = {}
Review comment:
Generally it's best to avoid mutable global state (such as class members).
For example, this will cause issues below where one can only close *all*
handles, not just the ones associated with a particular connection. It also
means the set of worker ids must be globally unique across pipelines (not just
for a particular runner instance).
In this case, I think we can replace this class by a
`collections.defaultdict(ControlConnection)` instance member in
BeamFnControlServicer.
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
Issue Time Tracking
-------------------
Worklog Id: (was: 281092)
Time Spent: 28.5h (was: 28h 20m)
> Support multi-process execution on the FnApiRunner
> --------------------------------------------------
>
> Key: BEAM-3645
> URL: https://issues.apache.org/jira/browse/BEAM-3645
> Project: Beam
> Issue Type: Improvement
> Components: sdk-py-core
> Affects Versions: 2.2.0, 2.3.0
> Reporter: Charles Chen
> Assignee: Hannah Jiang
> Priority: Major
> Fix For: 2.15.0
>
> Time Spent: 28.5h
> Remaining Estimate: 0h
>
> https://issues.apache.org/jira/browse/BEAM-3644 gave us a 15x performance
> gain over the previous DirectRunner. We can do even better in multi-core
> environments by supporting multi-process execution in the FnApiRunner, to
> scale past Python GIL limitations.
--
This message was sent by Atlassian JIRA
(v7.6.14#76016)