Skip to content

Conversation

@dongjoon-hyun
Copy link
Member

What changes were proposed in this pull request?

This updates K8s document to describe new dynamic PVC features.

Why are the changes needed?

This will help the user use the new features easily.

Does this PR introduce any user-facing change?

Yes, but it's a doc updates.

How was this patch tested?

Manual.

Screen Shot 2020-09-28 at 3 54 53 PM

Screen Shot 2020-09-28 at 3 55 07 PM

@dongjoon-hyun dongjoon-hyun changed the title [SPARK-33006][DOCS] Add dynamic PVC usage example into K8s doc [SPARK-33006][K8S][DOCS] Add dynamic PVC usage example into K8s doc Sep 28, 2020
@SparkQA
Copy link

SparkQA commented Sep 28, 2020

Test build #129197 has finished for PR 29897 at commit 6e9c1cf.

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

@SparkQA
Copy link

SparkQA commented Sep 29, 2020

Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/33812/

@SparkQA
Copy link

SparkQA commented Sep 29, 2020

Kubernetes integration test status success
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/33812/

@dongjoon-hyun
Copy link
Member Author

cc @holdenk , @viirya , @dbtsai

The configuration properties for mounting volumes into the executor pods use prefix `spark.kubernetes.executor.` instead of `spark.kubernetes.driver.`. For a complete list of available options for each supported type of volumes, please refer to the [Spark Properties](#spark-properties) section below.
The configuration properties for mounting volumes into the executor pods use prefix `spark.kubernetes.executor.` instead of `spark.kubernetes.driver.`.

For example, you can mount a dynamically-created persistent volume claim per executor by using `OnDemand` as a claim name and `storageClass` and `sizeLimit` options like the following. This is useful in case of [Dynamic Allocation](configuration.html#dynamic-allocation).
Copy link
Member

Choose a reason for hiding this comment

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

Can you explain why it's useful for DA? Currently, this doesn't support DA yet. I think the use-case will be for people to use larger shuffle disks in Kube where larger local disks are not allowed.

Copy link
Member Author

@dongjoon-hyun dongjoon-hyun Sep 30, 2020

Choose a reason for hiding this comment

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

@dbtsai . What do you mean by the following?

Currently, this doesn't support DA yet.

Since Apache Spark 3.0.0, dynamic allocation with K8s has been supported with shuffle data tracking. And, this feature is also developed for both additional large disk requirement and dynamic allocation scenario. For example, in case of dynamic allocation, the executor id increases monotonically and indefinitely, so users cannot prepare unlimited pre-populated PVCs. With this feature, the PVC is created and deleted dynamically with the same lifecycle with the executor pod.

Copy link
Member Author

Choose a reason for hiding this comment

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

In short, I made the PVC(and PV) be created at every pod creation in ExecutorPodsAllocator.scala. Please see the original code. For example, if you kill some pod, new executor is going to be created with a new PVC.

cc @viirya

Copy link
Member

Choose a reason for hiding this comment

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

Get you. Thanks!

Copy link
Member

@viirya viirya left a comment

Choose a reason for hiding this comment

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

Looks okay after clarifying Dynamic Allocation case.

@dongjoon-hyun
Copy link
Member Author

@dongjoon-hyun
Copy link
Member Author

Thank you, @dbtsai and @viirya . Merged to master.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants