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

ASF GitHub Bot commented on FLINK-4824:
---------------------------------------

GitHub user greghogan opened a pull request:

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

    [FLINK-4824] [client] CliFrontend shows misleading error message

    When a Flink program throws `ProgramParametrizationException` the optional 
message is printed to stderr and the stacktrace is ignored.
    
    I modified Gelly's `JaccardIndex` driver to use this functionality as an 
example.

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

    $ git pull https://github.com/greghogan/flink 
4824_clifrontend_shows_misleading_error_message_when_main_method_returns_before_env_execute

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

    https://github.com/apache/flink/pull/2662.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 #2662
    
----
commit af0b2223a4fe03016f223e2605e12d00e177999c
Author: Greg Hogan <[email protected]>
Date:   2016-10-13T16:40:53Z

    [FLINK-4824] [client] CliFrontend shows misleading error message
    
    When a Flink program throws ProgramParametrizationException the
    optional message is printed to stderr and the stacktrace is ignored.

----


> CliFrontend shows misleading error message when main() method returns before 
> env.execute()
> ------------------------------------------------------------------------------------------
>
>                 Key: FLINK-4824
>                 URL: https://issues.apache.org/jira/browse/FLINK-4824
>             Project: Flink
>          Issue Type: Bug
>          Components: Client
>    Affects Versions: 1.2.0
>            Reporter: Robert Metzger
>            Assignee: Greg Hogan
>
> While testing Flink by running the 
> {{./examples/streaming/SocketWindowWordCount.jar}} example, I got the 
> following error message:
> {code}
> ./bin/flink run ./examples/streaming/SocketWindowWordCount.jar 
> Cluster configuration: Standalone cluster with JobManager at /127.0.0.1:6123
> Using address 127.0.0.1:6123 to connect to JobManager.
> JobManager web interface address http://127.0.0.1:8081
> Starting execution of program
> No port specified. Please run 'SocketWindowWordCount --port <port>', where 
> port is the address of the text server
> To start a simple text server, run 'netcat -l <port>' and type the input text 
> into the command line
> ------------------------------------------------------------
>  The program finished with the following exception:
> org.apache.flink.client.program.ProgramInvocationException: The program 
> didn't contain Flink jobs. Perhaps you forgot to call execute() on the 
> execution environment.
>       at 
> org.apache.flink.client.program.ClusterClient.run(ClusterClient.java:324)
>       at 
> org.apache.flink.client.CliFrontend.executeProgram(CliFrontend.java:774)
>       at org.apache.flink.client.CliFrontend.run(CliFrontend.java:250)
>       at 
> org.apache.flink.client.CliFrontend.parseParameters(CliFrontend.java:985)
>       at org.apache.flink.client.CliFrontend$2.run(CliFrontend.java:1032)
>       at org.apache.flink.client.CliFrontend$2.run(CliFrontend.java:1029)
>       at 
> org.apache.flink.runtime.security.SecurityContext$1.run(SecurityContext.java:82)
>       at java.security.AccessController.doPrivileged(Native Method)
>       at javax.security.auth.Subject.doAs(Subject.java:422)
>       at 
> org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1548)
>       at 
> org.apache.flink.runtime.security.SecurityContext.runSecured(SecurityContext.java:79)
>       at org.apache.flink.client.CliFrontend.main(CliFrontend.java:1029)
> {code}
> I think the error message is misleading, because I tried executing a valid 
> Flink job.



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

Reply via email to