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-2368 Making FileServerHandler sends gracefully to prevent OOM #1303

Closed
wants to merge 4 commits into from

Conversation

ngbinh
Copy link
Contributor

@ngbinh ngbinh commented Jul 4, 2014

Busy wait for the channel to be ready before writing to it to prevent
the buffer from exploding.

Also making some small code changes to improve clarity.

Busy wait for the channel to be ready before writing to it to prevent
the buffer from exploding.

Also making some small code changes for clarity.
@AmplabJenkins
Copy link

Merged build triggered.

@AmplabJenkins
Copy link

Merged build started.

while (!channel.isWritable()) {
channel.writeAndFlush(object);
}
}
Copy link
Contributor

Choose a reason for hiding this comment

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

This method is incorrect - if channel was writable initially, it will exit immediately without any write.

Has this patch been tested ?

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 test it.

@mridulm
Copy link
Contributor

mridulm commented Jul 4, 2014

The config changes look promising (btw, you will need to read them from SparkConf and not hardcode values) - rest can be ommitted.

@AmplabJenkins
Copy link

Merged build finished.

@AmplabJenkins
Copy link

Refer to this link for build results: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/16345/

@AmplabJenkins
Copy link

Merged build triggered.

@AmplabJenkins
Copy link

Merged build started.

@AmplabJenkins
Copy link

Merged build finished. All automated tests passed.

@AmplabJenkins
Copy link

All automated tests passed.
Refer to this link for build results: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/16348/

@AmplabJenkins
Copy link

Merged build triggered.

@AmplabJenkins
Copy link

Merged build started.

@AmplabJenkins
Copy link

Merged build finished. All automated tests passed.

@AmplabJenkins
Copy link

All automated tests passed.
Refer to this link for build results: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/16352/

@ngbinh
Copy link
Contributor Author

ngbinh commented Jul 8, 2014

@mridulm please take another look. Thanks

@andrewor14
Copy link
Contributor

Hi @ngbinh, thanks for your PR. It appears that we are exposing a lot of configs to the user, and this might be confusing if there are all these extra knobs that we can tune. I think it's ok to keep the configs, but I wonder whether we should actually document them. Also, many of these configs are under the spark.shuffle.fileserver.* prefix. However, the file server can be used for other things as well, so maybe it makes more sense to simplify the configs by stripping out the shuffle part.

Can you up merge this once you have the chance?

@shivaram
Copy link
Contributor

shivaram commented Sep 4, 2014

@andrewor14 -- Reynold has changed a lot of these files as a part of the shuffle refactoring (In fact I think most of these java files don't exist anymore).

@rxin Could you incorporate these options as a part of your netty changes ?

@ngbinh
Copy link
Contributor Author

ngbinh commented Sep 4, 2014

I agree that these changes look outdated now. I believe Akka-http streaming http://typesafe.com/blog/typesafe-announces-akka-streams is the future.

I remember seeing a ticket where @rxin listed a number of improvements on Spark network code that should cover these changes. Close for now.

@ngbinh ngbinh closed this Sep 4, 2014
wangyum pushed a commit that referenced this pull request May 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
5 participants