You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2020/04/20 08:46:07 UTC

[GitHub] [flink] xintongsong commented on a change in pull request #11817: [FLINK-17257][yarn][test] Fix AbstractYarnClusterTest not compiling with hadoop 2.10.

xintongsong commented on a change in pull request #11817:
URL: https://github.com/apache/flink/pull/11817#discussion_r411202251



##########
File path: flink-yarn/src/test/java/org/apache/flink/yarn/AbstractYarnClusterTest.java
##########
@@ -82,26 +83,21 @@ private ApplicationReport createApplicationReport(
 		ApplicationId applicationId,
 		YarnApplicationState yarnApplicationState,
 		FinalApplicationStatus finalApplicationStatus) {
-		return ApplicationReport.newInstance(
-			applicationId,
-			ApplicationAttemptId.newInstance(applicationId, 0),
-			"user",
-			"queue",
-			"name",
-			"localhost",
-			42,
-			null,
-			yarnApplicationState,
-			null,
-			null,
-			1L,
-			2L,
-			finalApplicationStatus,
-			null,
-			null,
-			1.0f,
-			null,
-			null);
+
+		ApplicationReport applicationReport = Records.newRecord(ApplicationReport.class);

Review comment:
       Not that I'm aware of.
   I admit that this is not a perfect solution and is not guaranteed compatible with all future hadoop versions. This approach only works with the current known hadoop versions.




----------------------------------------------------------------
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:
users@infra.apache.org