zhengcanbin commented on a change in pull request #11489: [FLINK-15640][k8s] 
Support to set labels and node-selector for jobmanager and taskmanager pod
URL: https://github.com/apache/flink/pull/11489#discussion_r396906346
 
 

 ##########
 File path: 
flink-kubernetes/src/main/java/org/apache/flink/kubernetes/configuration/KubernetesConfigOptions.java
 ##########
 @@ -111,6 +112,34 @@
        // The following config options could be overridden by 
KubernetesCliOptions.
        // 
---------------------------------------------------------------------------------
 
+       public static final ConfigOption<Map<String, String>> 
JOB_MANAGER_LABELS =
+               key("kubernetes.jobmanager.labels")
+               .mapType()
+               .noDefaultValue()
+               .withDescription("The labels to be set for JobManager pod. 
Specified as key:value pairs separated by commas. " +
+                       "For example, version:alphav1,deploy:test.");
+
+       public static final ConfigOption<Map<String, String>> 
TASK_MANAGER_LABELS =
+               key("kubernetes.taskmanager.labels")
+               .mapType()
+               .noDefaultValue()
+               .withDescription("The labels to be set for TaskManager pods. 
Specified as key:value pairs separated by commas. " +
+                       "For example, version:alphav1,deploy:test.");
+
+       public static final ConfigOption<Map<String, String>> 
JOB_MANAGER_NODE_SELECTOR =
+               key("kubernetes.jobmanager.node-selector")
 
 Review comment:
   How about changing the key from `kubernetes.jobmanager.node-selector` to 
`kubernetes.jobmanager.node-selectors`? We use the plural for the 
user-specified annotations and labels, in the meantime use the singular for the 
node-selector. Could we use a consistent key naming convention for these kind 
of config options?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to