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-18220][runtime] Extended OutOfMemoryError message. #13111
Conversation
@tillrohrmann The PR is ready to be reviewed. |
Thanks a lot for your contribution to the Apache Flink project. I'm the @flinkbot. I help the community Automated ChecksLast check on commit 8401a49 (Mon Aug 10 21:18:21 UTC 2020) Warnings:
Mention the bot in a comment to re-run the automated checks. Review Progress
Please see the Pull Request Review Guide for a full explanation of the review process. The Bot is tracking the review progress through labels. Labels are applied according to the order of the review items. For consensus, approval by a Flink committer of PMC member is required Bot commandsThe @flinkbot bot supports the following commands:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for creating this PR @XComp. I had a couple of comments. Please take a look.
flink-runtime/src/main/java/org/apache/flink/runtime/jobgraph/InputOutputFormatVertex.java
Outdated
Show resolved
Hide resolved
...ntime/src/main/java/org/apache/flink/runtime/entrypoint/ClusterEntryPointExceptionUtils.java
Outdated
Show resolved
Hide resolved
...ntime/src/main/java/org/apache/flink/runtime/entrypoint/ClusterEntryPointExceptionUtils.java
Outdated
Show resolved
Hide resolved
flink-runtime/src/main/java/org/apache/flink/runtime/jobgraph/InputOutputFormatVertex.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for updating this PR @XComp. I had a couple of comments. Please take a look.
flink-core/src/main/java/org/apache/flink/util/ExceptionUtils.java
Outdated
Show resolved
Hide resolved
flink-core/src/main/java/org/apache/flink/util/ExceptionUtils.java
Outdated
Show resolved
Hide resolved
...ntime/src/main/java/org/apache/flink/runtime/entrypoint/ClusterEntryPointExceptionUtils.java
Outdated
Show resolved
Hide resolved
flink-runtime/src/main/java/org/apache/flink/runtime/executiongraph/ExecutionGraph.java
Outdated
Show resolved
Hide resolved
flink-runtime/src/main/java/org/apache/flink/runtime/taskmanager/Task.java
Outdated
Show resolved
Hide resolved
flink-runtime/src/main/java/org/apache/flink/runtime/jobmaster/JobManagerRunnerImpl.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for updating the PR @XComp. The changes look good. I will resolve the comment about the missing license header while rebasing onto the latest master. Once AZP gives green light, I will merge the PR.
@@ -0,0 +1,48 @@ | |||
package org.apache.flink.runtime.entrypoint; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This file misses a license header:
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
…on information Provide the user with hints how to configure Flink in order to increase the heap space of the JobManager process in case that Java heap space OutOfMemory errors are encountered. [FLINK-18220][runtime] Changed the visibility of ClusterEntryPointExceptionUtils and its utility method to enable using it also in other packages. [FLINK-18220][runtime] Adapted signature of JobVertex.finalizeOnMaster and JobVertex.initializeOnMaster to indicate that not only Exceptions might occur. [FLINK-18220][runtime] Added OOM-enrichment to InputOutputFormatVertex.initializeOnMaster and InputOutputFormatVertex.finalizeOnMaster. [FLINK-18220][runtime] Extended ExceptionUtils adding a method for manipulating the error message within the cause tree of a passed Throwable. More specifically, this method is used to change the message of a OutOfMemoryError buried within a Throwable's cause tree. [FLINK-18220][runtime] Refactored newly added utility method by generalizing its purpose. The previous version was referring to a concrete use case already which is not the purpose of ExceptionUtils. Corresponding testcases were added as well. [FLINK-18220][runtime] Refactored newly added utility method by enabling to update multiple messages at once. This way, we avoid traversing the cause tree multiple times. [FLINK-18220][runtime] Made use of newly added ExceptionUtils.updateDetailMessage and cleaning up unused code. [FLINK-18220][runtime] Refactored code to not support deleting an error message. This was done in favor of simplifying the code over supporting a feature that was not requested. [FLINK-18220][runtime] Fixed missed out compiler errors. Revert "[FLINK-18220][runtime] Adapted signature of JobVertex.finalizeOnMaster and JobVertex.initializeOnMaster to indicate that not only Exceptions might occur." This reverts commit dc23b3a. [FLINK-18220][runtime] Moved OOM message handling into more exposed code segments. [FLINK-18220][runtime] JavaDoc fix. [FLINK-18220][runtime] Extended ExceptionUtils.tryEnrichOutOfMemoryError to cover also heap space-related OutOfMemoryErrors. [FLINK-18220][runtime] Added error message for heap-space-related OutOfMemoryErrors. [FLINK-18220][runtime] Fixed compilation error. [FLINK-18220][runtime] Reverted the formatting changes accidentally pushed in 93d9627 but left the TaskManagerExceptionUtils.tryEnrichTaskManagerError(Throwable) change untouched. [FLINK-18220][runtime] Updated Exception methods to be more descriptive. [FLINK-18220][runtime] Typo fix in newly added exception message for JM heap space errors. [FLINK-18220][runtime] Updated JavaDoc to comply the actual implementation. [FLINK-18220][runtime] Added @nullable constaints. [FLINK-18220][runtime] Moved OOM handling up the call hierarchy into the Dispatcher. [FLINK-18220][runtime] Moved OOM handling down from the generic failGlobal(Throwable) into vertexFinished(). [FLINK-18220][runtime] Moved OOM handling up the call hierarchy into internalSubmitJob(JobGraph). [FLINK-18220][runtime] Added test class that checks whether the right error message prefix to extended error message mapping is applied. [FLINK-18220][runtime] Added IT testing that OOM error message enrichment is happening when an OutOfMemoryError occurs during initialization or finalization of a vertex.
e575fa0
to
ed988e8
Compare
What is the purpose of the change
Brief change log
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:
@Public(Evolving)
: noDocumentation