You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by pnowojski <gi...@git.apache.org> on 2018/01/30 14:07:34 UTC

[GitHub] flink pull request #5383: [hotfix][kafka-tests] Do not hide original excepti...

GitHub user pnowojski opened a pull request:

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

    [hotfix][kafka-tests] Do not hide original exception in FlinkKafkaProducer011ITCase

    This is a simple change in tests. Old code in case of failure was hiding/overwriting original exception.

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

    $ git pull https://github.com/pnowojski/flink kafka

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

    https://github.com/apache/flink/pull/5383.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 #5383
    
----
commit 56c8e225af5cf4ad7a461f597f7e7f95e9ab82bd
Author: Piotr Nowojski <pi...@...>
Date:   2018-01-30T13:56:43Z

    [hotfix][kafka-tests] Do not hide original exception in FlinkKafkaProducer011ITCase

----


---

[GitHub] flink pull request #5383: [hotfix][kafka-tests] Do not hide original excepti...

Posted by pnowojski <gi...@git.apache.org>.
Github user pnowojski commented on a diff in the pull request:

    https://github.com/apache/flink/pull/5383#discussion_r167224057
  
    --- Diff: flink-connectors/flink-connector-kafka-0.11/src/test/java/org/apache/flink/streaming/connectors/kafka/FlinkKafkaProducer011ITCase.java ---
    @@ -592,24 +595,21 @@ private Properties createProperties() {
     		return properties;
     	}
     
    -	private void assertIsCausedBy(Class<?> clazz, Throwable ex) {
    +	private static <T> Optional<T> isCausedBy(Class<T> clazz, Throwable ex) {
    --- End diff --
    
    Changed to `findThrowable` :)


---

[GitHub] flink pull request #5383: [hotfix][kafka-tests] Do not hide original excepti...

Posted by tillrohrmann <gi...@git.apache.org>.
Github user tillrohrmann commented on a diff in the pull request:

    https://github.com/apache/flink/pull/5383#discussion_r164754175
  
    --- Diff: flink-connectors/flink-connector-kafka-0.11/src/test/java/org/apache/flink/streaming/connectors/kafka/FlinkKafkaProducer011ITCase.java ---
    @@ -592,24 +595,21 @@ private Properties createProperties() {
     		return properties;
     	}
     
    -	private void assertIsCausedBy(Class<?> clazz, Throwable ex) {
    +	private static <T> Optional<T> isCausedBy(Class<T> clazz, Throwable ex) {
    --- End diff --
    
    Better to use `ExceptionUtils#findThrowable`.


---

[GitHub] flink issue #5383: [hotfix][kafka-tests] Do not hide original exception in F...

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

    https://github.com/apache/flink/pull/5383
  
    Changes look good to me. Thanks for the fix @pnowojski. Merging this PR.


---

[GitHub] flink pull request #5383: [hotfix][kafka-tests] Do not hide original excepti...

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

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


---