Skip to main content
Ctrl+K
PyFlink 1.20+vvr.11.7.dev0 documentation - Home PyFlink 1.20+vvr.11.7.dev0 documentation - Home
  • API Reference
  • Examples
  • API Reference
  • Examples

Section Navigation

  • PyFlink Table
  • PyFlink DataStream
    • StreamExecutionEnvironment
    • DataStream
    • Functions
    • State
    • Timer
    • Window
    • Checkpoint
    • Side Outputs
    • Asynchronous I/O
    • Connectors
    • Formats
  • PyFlink DataFrame
  • PyFlink Common
  • API Reference
  • PyFlink DataStream
  • Functions
  • pyflink.datastream.functions.BroadcastProcessFunction

pyflink.datastream.functions.BroadcastProcessFunction#

class BroadcastProcessFunction[source]#

A function to be applied to a BroadcastConnectedStream that connects BroadcastStream, i.e. a stream with broadcast state, with a non-keyed DataStream.

The stream with the broadcast state can be created using the DataStream.broadcast() method.

The user has to implement two methods:

  • the process_broadcast_element() which will be applied to each element in the broadcast side

  • the process_element() which will be applied to the non-broadcasted side.

The process_broadcast_element() takes a context as an argument (among others), which allows it to read/write to the broadcast state, while the process_element() has read-only access to the broadcast state.

Added in version 1.16.0.

Methods

close()

open(runtime_context)

process_broadcast_element(value, ctx)

This method is called for each element in the BroadcastStream.

process_element(value, ctx)

This method is called for each element in the (non-broadcast) DataStream.

previous

pyflink.datastream.functions.Partitioner

next

pyflink.datastream.functions.KeyedBroadcastProcessFunction

On this page
  • BroadcastProcessFunction

This Page

  • Show Source

Created using Sphinx 7.4.7.

Built with the PyData Sphinx Theme 0.16.1.