You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Fabian Hueske (JIRA)" <ji...@apache.org> on 2016/04/18 12:15:26 UTC

[jira] [Commented] (FLINK-3777) Add open and close methods to manage IF lifecycle

    [ https://issues.apache.org/jira/browse/FLINK-3777?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15245420#comment-15245420 ] 

Fabian Hueske commented on FLINK-3777:
--------------------------------------

I agree that the naming of {{configure()}} could be better, but I think that a better name does not justify a new method. 

So, +1 for adding a closeInputFormat() method but I would stick to {{configure()}} because it does exactly what {{openInputFormat()}} would do.

It is not possible to rename {{InputFormat.open()}} and {{InputFormat.close()}} since these have been declared as stable API.


> Add open and close methods to manage IF lifecycle
> -------------------------------------------------
>
>                 Key: FLINK-3777
>                 URL: https://issues.apache.org/jira/browse/FLINK-3777
>             Project: Flink
>          Issue Type: Sub-task
>          Components: Core
>    Affects Versions: 1.0.1
>            Reporter: Flavio Pompermaier
>              Labels: inputformat, lifecycle
>
> At the moment the opening and closing of an inputFormat are not managed, although open() could be (improperly IMHO) simulated by configure().
> This limits the possibility to reuse expensive resources (like database connections) and manage their release. 
> Probably the best option would be to add 2 methods (i.e. openInputformat() and closeInputFormat() ) to RichInputFormat*
> * NOTE: the best option from a "semantic" point of view would be to rename the current open() and close() to openSplit() and closeSplit() respectively while using open() and close() methods for the IF lifecycle management, but this would cause a backward compatibility issue...



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)