Skip to content

Conversation

@vanzin
Copy link
Contributor

@vanzin vanzin commented Feb 24, 2015

Cache the value of the local root dirs to use for storing local data,
so that the same directories are reused.

Also, to avoid an extra level of nesting, use a different env variable
to propagate the local dirs from the Worker to the executors. And make
the executor directory use a different name.

Cache the value of the local root dirs to use for storing local data,
so that the same directory is reused.

Also, to avoid an extra level of nesting, use a different env variable
to propagate the local dirs from the Worker to the executors. And make
the executor directory use a different name.
@SparkQA
Copy link

SparkQA commented Feb 24, 2015

Test build #27903 has started for PR 4747 at commit 18ee0a7.

  • This patch merges cleanly.

Copy link
Member

Choose a reason for hiding this comment

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

I think these are dumb questions, but why does the fix entail setting a different env variable? and should dirs be joined with a path separator?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Without this, Utils.scala would always create a subdirectory for the executor under the directory already created by the Worker. So you'd always have "spark-xxxxx/spark-yyyyy" for every executor. It would be always like that (no extra nesting), but, since I'm changing this, sounded like a good enhancement.

And dirs should be joined with a path separator because that's the right way to do it.

Copy link
Member

Choose a reason for hiding this comment

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

Oh right, this is path.separator not file.separator, : not /.

Yes that's exactly the fix that needs to be made.

EDIT: I see it. I swear it didn't show the last file changed earlier. But it was probably user error.

@vanzin
Copy link
Contributor Author

vanzin commented Feb 24, 2015

Hold off a little bit on this; let me see how to handle the SparkConf issue (I think Josh added that for the unit tests).

@SparkQA
Copy link

SparkQA commented Feb 24, 2015

Test build #27903 has finished for PR 4747 at commit 18ee0a7.

  • This patch fails Spark unit tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@AmplabJenkins
Copy link

Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/27903/
Test FAILed.

@andrewor14
Copy link
Contributor

retest this please. We really need to fix the JavaAPISuite at some point.

@SparkQA
Copy link

SparkQA commented Feb 24, 2015

Test build #27908 has started for PR 4747 at commit 18ee0a7.

  • This patch merges cleanly.

Add a way for the test to work around the cache (even though the test
was passing without this). Also add a comment that explains the new
behavior of the `getOrCreateLocalRootDirs()`.
@SparkQA
Copy link

SparkQA commented Feb 24, 2015

Test build #27909 has started for PR 4747 at commit e0114e1.

  • This patch merges cleanly.

@SparkQA
Copy link

SparkQA commented Feb 24, 2015

Test build #27908 has finished for PR 4747 at commit 18ee0a7.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@AmplabJenkins
Copy link

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/27908/
Test PASSed.

@SparkQA
Copy link

SparkQA commented Feb 24, 2015

Test build #27909 has finished for PR 4747 at commit e0114e1.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@AmplabJenkins
Copy link

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/27909/
Test PASSed.

Copy link
Contributor

Choose a reason for hiding this comment

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

May be we can call this function to delete the local root directory in non-yarn mode when application is exited or SparkContext is stoped.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Note this method doesn't delete anything. There's a separate PR to clean up the root directories (#4759).

Copy link
Member

Choose a reason for hiding this comment

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

Do we need to register these for cleanup at shutdown? cf. #4759 (comment)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Not needed (see SPARK-4834). That's done by the maybeCleanupApplication in this file when the application finishes.

@asfgit asfgit closed this in df3d559 Feb 26, 2015
@vanzin vanzin deleted the SPARK-5801 branch March 9, 2015 17:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants