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

[Spark Load] Redirect the spark launcher's log to a separated log file #4470

Merged
merged 5 commits into from
Aug 30, 2020

Conversation

xy720
Copy link
Member

@xy720 xy720 commented Aug 27, 2020

Proposed changes

#4469

Types of changes

What types of changes does your code introduce to Doris?
Put an x in the boxes that apply

  • New feature (non-breaking change which adds functionality)

Checklist

Put an x in the boxes that apply. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

  • I have create an issue on (Fix #ISSUE), and have described the bug/feature there in detail
  • Compiling and unit tests pass locally with my changes
  • I have added tests that prove my fix is effective or that my feature works

@@ -103,7 +114,7 @@ public void run() {
try {
outReader = new BufferedReader(new InputStreamReader(process.getInputStream()));
while (!isStop && (line = outReader.readLine()) != null) {
LOG.info("monitor log: " + line);
outputBuffer.append(line + '\n');
Copy link
Contributor

Choose a reason for hiding this comment

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

why not just output to the outputStream? So that we don't need to buffer a log of content in memory?

Copy link
Member Author

Choose a reason for hiding this comment

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

ok. I changed it

}

public void clearSparkLauncherLog() {
String logPath = sparkLoadAppHandle.getLogPath();
Copy link
Contributor

Choose a reason for hiding this comment

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

Are you sure the sparkLoadAppHandle is not null here?

Copy link
Member Author

Choose a reason for hiding this comment

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

Not sure. So I made a new check here.

@morningman morningman self-assigned this Aug 27, 2020
@morningman morningman added area/spark-load Issues or PRs related to the spark load kind/improvement labels Aug 27, 2020
Copy link
Contributor

@morningman morningman left a comment

Choose a reason for hiding this comment

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

LGTM

@morningman morningman added the approved Indicates a PR has been approved by one committer. label Aug 29, 2020
@morningman morningman merged commit 7b67da3 into apache:master Aug 30, 2020
@yangzhg yangzhg mentioned this pull request Feb 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by one committer. area/spark-load Issues or PRs related to the spark load kind/improvement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants