Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FLINK-7331] [futures] Replace Flink's Future with Java 8's CompletableFuture in ResourceManager #4444

Closed
wants to merge 1 commit into from

Conversation

tillrohrmann
Copy link
Contributor

What is the purpose of the change

Replace Flink's Future with Java 8's CompletableFuture in ResourceManager.

This PR is based on #4443.

Verifying this change

This change is a trivial rework / code cleanup without any test coverage.

Does this pull request potentially affect one of the following parts:

  • Dependencies (does it add or upgrade a dependency): (no)
  • The public API, i.e., is any changed class annotated with @Public(Evolving): (no)
  • The serializers: (no)
  • The runtime per-record code paths (performance sensitive): (no)
  • Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Yarn/Mesos, ZooKeeper: (no)

Documentation

  • Does this pull request introduce a new feature? (no)


final WorkerType newWorker = workerStarted(taskExecutorResourceId);

if(newWorker == null) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add space after if

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good catch. Will fix it.

@@ -401,74 +354,37 @@ public RegistrationResponse apply(RegistrationResponse registrationResponse, Thr
* @return The response by the ResourceManager.
*/
@RpcMethod
public Future<RegistrationResponse> registerTaskExecutor(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unintended renaming? This method is annotated with @RcpMethod, we need to change ResourceManagerGateway as well. Although this begs the question why we expose an internal method in the first place.

…leFuture in ResourceManager

Address PR comments

This closes apache#4444.
@tillrohrmann
Copy link
Contributor Author

Thanks for the review @zentol. I addressed your comments. Merging this PR now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants