twalthr opened a new pull request #14329:
URL: https://github.com/apache/flink/pull/14329


   ## What is the purpose of the change
   
   This updates the `LookupTableSource` interface to the new type system.
   
   ```
    * <p>By default, input and output data types are automatically extracted 
using reflection. This includes
    * the generic argument {@code T} of the class for determining an output 
data type. Input arguments are
    * derived from one or more {@code eval()} methods. If the reflective 
information is not sufficient, it
    * can be supported and enriched with {@link DataTypeHint} and {@link 
FunctionHint} annotations. See
    * {@link TableFunction} for more examples how to annotate an implementation 
class.
    *
    * <p>Note: Currently, asynchronous table functions are only supported as 
the runtime implementation
    * of {@link LookupTableSource}s for performing temporal joins. By default, 
input and output {@link DataType}s
    * of {@link AsyncTableFunction} are derived similar to other {@link 
UserDefinedFunction}s using the
    * logic above. However, for convenience, in a {@link LookupTableSource} the 
output type can simply be
    * a {@link Row} or {@link RowData} in which case the input and output types 
are derived from the
    * table's schema with default conversion.
   ```
   
   ## Brief change log
   
   It updates the code base to use a unified extraction logic for all kinds of 
functions.
   
   ## Verifying this change
   
   This change is already covered by existing tests, such as `LookupJoinITCase` 
and `AsyncLookupJoinITCase`.
   
   This change added tests and can be verified as follows: 
`FunctionITCase.testLookupTableFunction`
   
   ## Does this pull request potentially affect one of the following parts:
   
     - Dependencies (does it add or upgrade a dependency): no
     - The public API, i.e., is any changed class annotated with 
`@Public(Evolving)`: yes
     - The serializers: no
     - The runtime per-record code paths (performance sensitive): no
     - Anything that affects deployment or recovery: JobManager (and its 
components), Checkpointing, Kubernetes/Yarn/Mesos, ZooKeeper: no
     - The S3 file system connector: no
   
   ## Documentation
   
     - Does this pull request introduce a new feature? yes
     - If yes, how is the feature documented? JavaDocs
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to