You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 15 Next »

Document the state by adding a label to the FLIP page with one of "discussion", "accepted", "released", "rejected".

Discussion thread

https://lists.apache.org/thread/5lyjrrdtwkngkol2t541r4xwoh7133km

Vote threadTBD

JIRA

https://issues.apache.org/jira/browse/FLINK-6912

Release

Please keep the discussion on the mailing list rather than commenting on the wiki (wiki discussions get unwieldy fast).

Motivation

The open() method in RichFunction requires a Configuration instance as an argument, which is always passed as a new instance without any configuration parameters in AbstractUdfStreamOperator#open. Thus, it is unnecessary to include this parameter in the open() method.

Public Interfaces

Modify the RichFunction#open(Configuration parameters) to RichFunction#open().

Proposed Changes

There are two steps to modify the RichFunction#open(Configuration parameters) to RichFunction#open().

First step, add a new method open() to RichFunction interface. Implement the open() and make open(Configuration parameters) invoke it in the implementations of RichFunction.

The configuration parameter is always empty so the implementations of RichFunction#open(Configuration parameters) should't get value from configuration and just use the default value. There are three classes that still get value from configuration: ContinuousFileMonitoringFunction#open, OutputFormatSinkFunction#open, InputFormatSourceFunction#open. The three methods should be modified to use the default value instead of getting value from configuration.

Second step, mark the open(Configuration parameters) as deprecated and remove open(Configuration parameters) in next major release.

Compatibility, Deprecation, and Migration Plan

  • What impact (if any) will there be on existing users?
  • For the users that rely on the open() method, they will have to migrate to the no parameter variants. This migration shouldn't be difficult.

  • As the RichFunction abstract class is part of the public API we will deprecate the method 2 releases before removal.

  • No labels