c

cloudflow.flink

FlinkStreamlet

abstract class FlinkStreamlet extends Streamlet[FlinkStreamletContext] with Serializable

The base class for defining Flink streamlets. Derived classes need to override createLogic to provide the custom implementation for the behavior of the streamlet.

Here's an example:

// new custom `FlinkStreamlet`
class MyFlinkProcessor extends FlinkStreamlet {
  // Step 1: Define inlets and outlets. Note for the outlet you can specify
  //         the partitioner function explicitly or else `RoundRobinPartitioner`
  //         will be used
  val in = AvroInlet[Data]("in")
  val out = AvroOutlet[Simple]("out", _.name)

  // Step 2: Define the shape of the streamlet. In this example the streamlet
  //         has 1 inlet and 1 outlet
  val shape = StreamletShape(in, out)

  // Step 3: Provide custom implementation of `FlinkStreamletLogic` that defines
  //         the behavior of the streamlet
  override def createLogic() = new FlinkStreamletLogic {
    override def executeStreamingQueries = {
      val outStream: DataStream[Simple] =
        writeStream(
          readStream(in).map(r => Simple(r.name)),
          out
        )
      executionEnv.execute()
    }
  }
}
Source
FlinkStreamlet.scala
Linear Supertypes
Serializable, Serializable, Streamlet[FlinkStreamletContext], AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. FlinkStreamlet
  2. Serializable
  3. Serializable
  4. Streamlet
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new FlinkStreamlet()

Type Members

  1. sealed trait FlinkJobExecutor extends Serializable

    Different strategy for execution of Flink jobs in local mode and in cluster

Abstract Value Members

  1. abstract def createLogic(): FlinkStreamletLogic
    Attributes
    protected
  2. abstract def shape(): StreamletShape
    Definition Classes
    Streamlet

Concrete Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def attributes: Set[StreamletAttribute]
    Attributes
    protected[cloudflow]
    Definition Classes
    Streamlet
  6. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  7. def configParameters: IndexedSeq[ConfigParameter]
    Definition Classes
    Streamlet
  8. final def configuredValue(context: FlinkStreamletContext, configKey: String): String
  9. implicit final def context: FlinkStreamletContext
    Attributes
    protected
    Definition Classes
    Streamlet
  10. final def createContext(config: Config): FlinkStreamletContext
    Attributes
    protected
    Definition Classes
    FlinkStreamlet → Streamlet
  11. def createExecutionEnvironment(config: Config, streamlet: String): StreamExecutionEnvironment

    Creates the Flink StreamExecutionEnvironment and by default sets up exactly-once checkpointing.

    Creates the Flink StreamExecutionEnvironment and by default sets up exactly-once checkpointing.

    Attributes
    protected
    See also

    setupExecutionEnvironment to modify the StreamExecutionEnvironment that is created by this method.

  12. def customAttributes: Set[StreamletAttribute]
    Definition Classes
    Streamlet
  13. def defineConfigParameters(): Array[ConfigParameter]
    Definition Classes
    Streamlet
  14. def defineCustomAttributes(): Array[StreamletAttribute]
    Definition Classes
    Streamlet
  15. def defineVolumeMounts(): Array[VolumeMount]
    Definition Classes
    Streamlet
  16. def description: String
    Definition Classes
    Streamlet
  17. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  18. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  19. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  20. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  21. final def getContext(): FlinkStreamletContext
    Attributes
    protected
    Definition Classes
    Streamlet
  22. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  23. final def inlets: IndexedSeq[Inlet]
    Definition Classes
    Streamlet
  24. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  25. final def jsonDescriptor: String
    Definition Classes
    Streamlet
  26. def labels: IndexedSeq[String]
    Definition Classes
    Streamlet
  27. lazy val log: Logger
    Attributes
    protected
    Definition Classes
    Streamlet
    Annotations
    @transient()
  28. def logStartRunnerMessage(buildInfo: String): Unit
    Definition Classes
    FlinkStreamlet → Streamlet
  29. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  30. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  31. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  32. final def outlets: IndexedSeq[Outlet]
    Definition Classes
    Streamlet
  33. final def run(context: FlinkStreamletContext): StreamletExecution
    Definition Classes
    FlinkStreamlet → Streamlet
  34. final val runtime: FlinkStreamletRuntime.type
    Definition Classes
    FlinkStreamlet → Streamlet
  35. def setDefaultCheckpointing(env: StreamExecutionEnvironment): CheckpointConfig
  36. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  37. def toString(): String
    Definition Classes
    AnyRef → Any
  38. def volumeMounts: IndexedSeq[VolumeMount]
    Definition Classes
    Streamlet
  39. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  40. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  41. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()

Inherited from Serializable

Inherited from Serializable

Inherited from Streamlet[FlinkStreamletContext]

Inherited from AnyRef

Inherited from Any

Ungrouped