[
https://issues.apache.org/jira/browse/FLINK-7836?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16380026#comment-16380026
]
ASF GitHub Bot commented on FLINK-7836:
---------------------------------------
Github user yanghua commented on a diff in the pull request:
https://github.com/apache/flink/pull/5593#discussion_r171182303
--- Diff:
flink-yarn/src/main/java/org/apache/flink/yarn/AbstractYarnClusterDescriptor.java
---
@@ -979,6 +989,16 @@ public ApplicationReport startAppMaster(
appContext.setApplicationType("Apache Flink");
appContext.setAMContainerSpec(amContainer);
appContext.setResource(capability);
+
+ if (nodeLabel != null) {
+ try {
+ Method method =
appContext.getClass().getMethod("setNodeLabelExpression", String.class);
+ method.invoke(appContext, nodeLabel);
+ } catch (NoSuchMethodException e) {
+ LOG.warn("Ignoring node label setting because
the version of YARN does not support it");
+ }
+ }
--- End diff --
Do you mean wrap this code segment to a new method named this?
> specifying node label for flink job to run on yarn
> --------------------------------------------------
>
> Key: FLINK-7836
> URL: https://issues.apache.org/jira/browse/FLINK-7836
> Project: Flink
> Issue Type: New Feature
> Components: Client
> Affects Versions: 1.3.2
> Reporter: zhaibaba
> Assignee: vinoyang
> Priority: Major
>
> flink client cannot specify node label for flink job to run on yarn
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)