Flink10 Per-JOB Could not build the program from JAR file.


【問題の説明】:
   Could not build the program from JAR file.    Use the help option (-h or --help) to get help on the command.
【原因】:以前per-jobが起動したとき、flink 1.8を使用していたので、次のコマンドを使用しました.
[root@hadoop1 flink-1.10.1]# bin/flink run -m yarn-cluster -yn 2 -d ./examples/streaming/WordCount.jar 

【問題解決】:ログcat flink-root-client-hadoop 1.logを表示すると、次のエラーが発生します.
org.apache.flink.client.cli.CliArgsException: Could not build the program from JAR file.
	at org.apache.flink.client.cli.CliFrontend.run(CliFrontend.java:200)
	at org.apache.flink.client.cli.CliFrontend.parseParameters(CliFrontend.java:893)
	at org.apache.flink.client.cli.CliFrontend.lambda$main$10(CliFrontend.java:966)
	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:1754)
	at org.apache.flink.runtime.security.HadoopSecurityContext.runSecured(HadoopSecurityContext.java:41)
	at org.apache.flink.client.cli.CliFrontend.main(CliFrontend.java:966)
Caused by: java.io.FileNotFoundException: JAR file does not exist: -yn
	at org.apache.flink.client.cli.CliFrontend.getJarFile(CliFrontend.java:717)
	at org.apache.flink.client.cli.CliFrontend.buildProgram(CliFrontend.java:693)
	at org.apache.flink.client.cli.CliFrontend.run(CliFrontend.java:197)
	... 7 more

-yn(yarncontainerはTaskManagerの個数を表します)をデフォルトのTaskManagerの個数を削除します.正常に起動します.
[root@hadoop1 flink-1.10.1]# bin/flink run -m yarn-cluster -d ./examples/streaming/WordCount.jar