You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@beam.apache.org by Eddy G <ka...@gmail.com> on 2020/04/09 07:49:17 UTC
Is there any way to send a ValueProvider to a trigger?
Been trying to deal with this problem for sooooo long! I may be approaching this the incorrect way but can't really imagine another way.
.triggering(
AfterFirst.of(
AfterPane.elementCountAtLeast(options.getCountAtLeastValue().get()),
AfterProcessingTime.pastFirstElementInPane().plusDelayOf(Duration.standardSeconds(1))
)
)
Having the previous trigger, I would like to make the AfterPane.elementCountAtLeast value configurable at runtime, but haven't found a proper way to do so.
Is there any usual way in Beam to make trigger values configurable or should I make my own? I've ValueProvider options within a custom pipeline stage by including them in the constructor, but don't really know if there's an easier way to do so.
Re: Is there any way to send a ValueProvider to a trigger?
Posted by Luke Cwik <lc...@google.com>.
No and the triggers aren't extensible.
Your best bet is to use something which can run the entire pipeline
construction code and not rely on ValueProviders.
On Thu, Apr 9, 2020 at 12:49 AM Eddy G <ka...@gmail.com> wrote:
> Been trying to deal with this problem for sooooo long! I may be
> approaching this the incorrect way but can't really imagine another way.
>
> .triggering(
> AfterFirst.of(
>
> AfterPane.elementCountAtLeast(options.getCountAtLeastValue().get()),
>
> AfterProcessingTime.pastFirstElementInPane().plusDelayOf(Duration.standardSeconds(1))
> )
> )
>
> Having the previous trigger, I would like to make the
> AfterPane.elementCountAtLeast value configurable at runtime, but haven't
> found a proper way to do so.
>
> Is there any usual way in Beam to make trigger values configurable or
> should I make my own? I've ValueProvider options within a custom pipeline
> stage by including them in the constructor, but don't really know if
> there's an easier way to do so.
>
>
>