wanglijie95 commented on code in PR #20056:
URL: https://github.com/apache/flink/pull/20056#discussion_r909314999
##########
flink-runtime/src/main/java/org/apache/flink/runtime/taskmanager/TaskManagerLocation.java:
##########
@@ -76,20 +84,41 @@ public class TaskManagerLocation implements
Comparable<TaskManagerLocation>, jav
* @param dataPort the port instance's task manager expects to receive
transfer envelopes on
* @param hostNameSupplier the supplier for obtaining fully-qualified
domain name and pure
* hostname of the task manager
+ * @param nodeId the ID of node where the task manager is located.
*/
@VisibleForTesting
public TaskManagerLocation(
ResourceID resourceID,
InetAddress inetAddress,
int dataPort,
- HostNameSupplier hostNameSupplier) {
+ HostNameSupplier hostNameSupplier,
+ String nodeId) {
// -1 indicates a local instance connection info
checkArgument(dataPort > 0 || dataPort == -1, "dataPort must be > 0,
or -1 (local)");
this.resourceID = checkNotNull(resourceID);
this.inetAddress = checkNotNull(inetAddress);
this.dataPort = dataPort;
this.hostNameSupplier = checkNotNull(hostNameSupplier);
+ this.nodeId = checkNotNull(nodeId);
+ }
+
+ /**
+ * Constructs a new instance connection info object. The constructor will
attempt to retrieve
+ * the instance's host name and domain name through the operating system's
lookup mechanisms.
+ *
+ * @param inetAddress the network address the instance's task manager
binds its sockets to
+ * @param dataPort the port instance's task manager expects to receive
transfer envelopes on
+ * @param hostNameSupplier the supplier for obtaining fully-qualified
domain name and pure
+ * hostname of the task manager
+ */
+ @VisibleForTesting
+ public TaskManagerLocation(
Review Comment:
Fixed
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]