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-1925] Fixes blocking method submitTask on the TM #622

Closed
wants to merge 6 commits into from

Conversation

tillrohrmann
Copy link
Contributor

The submitTask method which processes the SubmitTask message blocks while downloading the task jars from the JobManager. Depending on the number of TMs and jars, this can take a long time.

In order to get rid of the blocking call the submitTask method is split up into two phases: TDD reception with eager acknowledgement and TDD instantiation with a subsequent state update message. The TDD instantiation is executed concurrently in a future. Upon finishing the instantiation, an UpdateTaskExecutionState message with ExecutionState.RUNNING is sent to the JM. This implies that the state of the Execution is not directly set to RUNNING by the SubmitTask future handler which is created in Execution.deployToSlot.

…e into two phases: TDD reception with eager acknowledgement and TDD instantiation with a subsequent state update message.
@tillrohrmann tillrohrmann changed the title [FLINK-1925] Fixes blocked method submitTask on the TM [FLINK-1925] Fixes blocking method submitTask on the TM Apr 24, 2015
.description()));
}
} else {
if (!(success instanceof Messages.Acknowledge$)) {
Copy link
Contributor

Choose a reason for hiding this comment

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

I think this line is not parsable in Eclipse (the $ mess with the Java parser).
A workaround is to expose the case object class and object via a utility method and check against that.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Will do.

@StephanEwen
Copy link
Contributor

Looks god modulo some comments. The most critical being the concurrent Map one.

…n.concurrent.ConcurrentHashMap, refactors submitTask method into extra initializeTask method, makes message type test eclipse compatible.
@tillrohrmann
Copy link
Contributor Author

Thanks for reviewing the code @StephanEwen. I addressed your comments and updated the PR.

@StephanEwen
Copy link
Contributor

Looks good. Will merge this in my next batch, since I am building code on top anyways...

@asfgit asfgit closed this in 4cb5b72 Apr 29, 2015
bhatsachin pushed a commit to bhatsachin/flink that referenced this pull request May 5, 2015
…e into two phases:

  1. TDD reception with eager acknowledgement and
  2. TDD instantiation with a subsequent state update message.

This closes apache#622
marthavk pushed a commit to marthavk/flink that referenced this pull request Jun 9, 2015
…e into two phases:

  1. TDD reception with eager acknowledgement and
  2. TDD instantiation with a subsequent state update message.

This closes apache#622
@tillrohrmann tillrohrmann deleted the fixSubmitTask branch September 16, 2015 13:07
nltran pushed a commit to nltran/flink that referenced this pull request Jan 8, 2016
…e into two phases:

  1. TDD reception with eager acknowledgement and
  2. TDD instantiation with a subsequent state update message.

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