You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by twalthr <gi...@git.apache.org> on 2016/07/26 15:30:38 UTC

[GitHub] flink pull request #2298: [FLINK-4247] [table] CsvTableSource.getDataSet() e...

GitHub user twalthr opened a pull request:

    https://github.com/apache/flink/pull/2298

    [FLINK-4247] [table] CsvTableSource.getDataSet() expects Java ExecutionEnvironment

    Thanks for contributing to Apache Flink. Before you open your pull request, please take the following check list into consideration.
    If your changes take all of the items into account, feel free to open your pull request. For more information and/or questions please refer to the [How To Contribute guide](http://flink.apache.org/how-to-contribute.html).
    In addition to going through the list, please provide a meaningful description of your changes.
    
    - [x] General
      - The pull request references the related JIRA issue ("[FLINK-XXX] Jira title text")
      - The pull request addresses only one issue
      - Each commit in the PR has a meaningful commit message (including the JIRA id)
    
    - [x] Documentation
      - Documentation has been added for new functionality
      - Old documentation affected by the pull request has been updated
      - JavaDoc for public methods has been added
    
    - [x] Tests & Build
      - Functionality added by the pull request is covered by tests
      - `mvn clean verify` has been executed successfully locally or a Travis build has passed
    
    Adds explicit notice to `getDataSet/getDataStream` methods of `TableSource`.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/twalthr/flink FLINK-4247

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/flink/pull/2298.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #2298
    
----
commit 03325bc1afa65566b4ee06dca5362e283052deb0
Author: twalthr <tw...@apache.org>
Date:   2016-07-26T15:27:02Z

    [FLINK-4247] [table] CsvTableSource.getDataSet() expects Java ExecutionEnvironment

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink issue #2298: [FLINK-4247] [table] CsvTableSource.getDataSet() expects ...

Posted by twalthr <gi...@git.apache.org>.
Github user twalthr commented on the issue:

    https://github.com/apache/flink/pull/2298
  
    Yes, good idea. We can not restrict it as it is defined in an interface. If we would make it `protected`, we could not call it from the outside.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink issue #2298: [FLINK-4247] [table] CsvTableSource.getDataSet() expects ...

Posted by twalthr <gi...@git.apache.org>.
Github user twalthr commented on the issue:

    https://github.com/apache/flink/pull/2298
  
    I think adding some comments the methods doesn't hurt. I would merge this PR as it is.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink pull request #2298: [FLINK-4247] [table] CsvTableSource.getDataSet() e...

Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:

    https://github.com/apache/flink/pull/2298


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink issue #2298: [FLINK-4247] [table] CsvTableSource.getDataSet() expects ...

Posted by fhueske <gi...@git.apache.org>.
Github user fhueske commented on the issue:

    https://github.com/apache/flink/pull/2298
  
    +1 for sticking to Java DataSet / DataStream for the reasons @twalthr gave. The methods should be tagged with the `@Internal` annotation when we add them to the Table API.
    
    I would not rename `TableSource` to `TableInputFormat` because 1) it has no relationship to the `InputFormat` interface and 2) there is already a `TableInputFormat` for HBase tables (name is not very fortunate though...).



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink issue #2298: [FLINK-4247] [table] CsvTableSource.getDataSet() expects ...

Posted by twalthr <gi...@git.apache.org>.
Github user twalthr commented on the issue:

    https://github.com/apache/flink/pull/2298
  
    @StephanEwen A user can also call `CsvInputFormat.nextRecord()` because it is public, but this was never a problem. If we want to restrict visibility of `TableSource` interface methods, we have to convert the interfaces to classes and provide 3 class for batch, stream, batch&stream. Also not very nice.
    
    In general, the Scala classes hide the Java API streams and environments within the Table API. But in this case the user wants to implement a custom TableSource and since the Table API is internally using the Java API I think it is ok, if Java API and not Scala API is used for that.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink issue #2298: [FLINK-4247] [table] CsvTableSource.getDataSet() expects ...

Posted by fhueske <gi...@git.apache.org>.
Github user fhueske commented on the issue:

    https://github.com/apache/flink/pull/2298
  
    Agreed @twalthr. 
    IMO, +1 to merge


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink issue #2298: [FLINK-4247] [table] CsvTableSource.getDataSet() expects ...

Posted by zentol <gi...@git.apache.org>.
Github user zentol commented on the issue:

    https://github.com/apache/flink/pull/2298
  
    +1. We could also use the `@Internal` annotations for this.
    
    Out of curiosity, could you explain we can't just restrict access to the methods?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink issue #2298: [FLINK-4247] [table] CsvTableSource.getDataSet() expects ...

Posted by StephanEwen <gi...@git.apache.org>.
Github user StephanEwen commented on the issue:

    https://github.com/apache/flink/pull/2298
  
    Would be great to reflect the "do not use" with proper visibility. A JavaDoc comment is usually not helping at all.
    
    Also, the dependency on the java API classes in the Scala classes does not seem right. Usually the Scala classes hide the Java API streams and environments.
    
    Both of these things are usually strong indicators that there are some abstraction issues.
    Would be good to get that right, while the API is fresh and malleable.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] flink issue #2298: [FLINK-4247] [table] CsvTableSource.getDataSet() expects ...

Posted by fhueske <gi...@git.apache.org>.
Github user fhueske commented on the issue:

    https://github.com/apache/flink/pull/2298
  
    Do we agree to stick with the current implementation? If yes, let's close this PR.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---