beam-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kenneth Knowles (JIRA)" <>
Subject [jira] [Commented] (BEAM-3737) Key-aware batching function
Date Tue, 06 Mar 2018 04:58:00 GMT


Kenneth Knowles commented on BEAM-3737:

Actually I may have misinterpreted this, but I think [~robertwb] has context for this. Unassigning
for now.

> Key-aware batching function
> ---------------------------
>                 Key: BEAM-3737
>                 URL:
>             Project: Beam
>          Issue Type: New Feature
>          Components: sdk-py-core
>            Reporter: Chuan Yu Foo
>            Priority: Major
> I have a CombineFn for which add_input has very large overhead. I would like to batch
the incoming elements into a large batch before each call to add_input to reduce this overhead.
In other words, I would like to do something like: 
> {{elements | GroupByKey() | BatchElements() | CombineValues(MyCombineFn())}}
> Unfortunately, BatchElements is not key-aware, and can't be used after a GroupByKey to
batch elements per key. I'm working around this by doing the batching within CombineValues,
which makes the CombineFn rather messy. It would be nice if there were a key-aware BatchElements
transform which could be used in this context.

This message was sent by Atlassian JIRA

View raw message