You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by GitBox <gi...@apache.org> on 2021/11/04 18:10:17 UTC
[GitHub] [spark] tgravescs opened a new pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
tgravescs opened a new pull request #34485:
URL: https://github.com/apache/spark/pull/34485
### What changes were proposed in this pull request?
Add configs to allow mapping the Spark gpu/fpga resource type to a custom YARN resource type.
Currently Spark hardcodes the mapping of resource "gpu" to "yarn.io/gpu" and "fpga" to "yarn.io/fpga". This PR just allows the user to specify the "yarn.io/*" resource side.
Note it would be nice to put this in 3.2.1 as well, let me know if any objections.
### Why are the changes needed?
YARN supports custom resource types and in Hadoop 3.3.1 made it easier for users to plugin in custom resource types. This means users may create a custom resource type that represents a GPU or FPGAs because they want additional logic that the YARN built in versions don't have. Ideally Spark users still just use the generic "gpu" or "fpga" types in Spark. So this adds that ability so Spark end users don't need to know about changes to YARN resource types.
### Does this PR introduce _any_ user-facing change?
<!--
Note that it means *any* user-facing change including all aspects such as the documentation fix.
If yes, please clarify the previous behavior and the change this PR proposes - provide the console output, description and/or an example to show the behavior difference if possible.
If possible, please also clarify if this is a user-facing change compared to the released Spark versions or within the unreleased branches such as master.
If no, write 'No'.
-->
Configs added.
### How was this patch tested?
<!--
If tests were added, say they were added here. Please make sure to add some test cases that check the changes thoroughly including negative and positive cases if possible.
If it was tested in a way different from regular unit tests, please clarify how you tested step by step, ideally copy and paste-able, so that other reviewers can test and check, and descendants can verify in the future.
If tests were not added, please describe why they were not added and/or why it was difficult to add.
If benchmark tests were added, please run the benchmarks in GitHub Actions for the consistent environment, and the instructions could accord to: https://spark.apache.org/developer-tools.html#github-workflow-benchmarks.
-->
Tested manually with Hadoop 3.3.1 plugin https://hadoop.apache.org/docs/current/hadoop-yarn/hadoop-yarn-site/DevelopYourOwnDevicePlugin.html
and unit tests added here.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] tgravescs commented on a change in pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
tgravescs commented on a change in pull request #34485:
URL: https://github.com/apache/spark/pull/34485#discussion_r743661268
##########
File path: docs/running-on-yarn.md
##########
@@ -205,6 +205,28 @@ To use a custom metrics.properties for the application master and executors, upd
</td>
<td>3.0.0</td>
</tr>
+<tr>
+ <td><code>spark.yarn.resourceGpuDeviceName</code></td>
+ <td><code>yarn.io/gpu</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>gpu</code> to the YARN resource
+ representing a GPU. By default YARN uses <code>yarn.io/gpu</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.gpu.*</code> configs.
+ </td>
+ <td>3.2.1</td>
+</tr>
+<tr>
+ <td><code>spark.yarn.resourceFpgaDeviceName</code></td>
+ <td><code>yarn.io/fpga</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>fpga</code> to the YARN resource
+ representing a FPGA. By default YARN uses <code>yarn.io/fpga</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.fpga.*</code> configs.
+ </td>
+ <td>3.2.1</td>
Review comment:
It would be nice to get it in a 3.2.1 so users can get it sooner to work with existing hadoop 3.3.1. Its a pretty small change so impact should be small, but it is an improvement so it you (or others) think its best not to, I'll update to just target master
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] dongjoon-hyun closed pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
dongjoon-hyun closed pull request #34485:
URL: https://github.com/apache/spark/pull/34485
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] tgravescs commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
tgravescs commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961397061
k8s failure not related:
Error: package or namespace load failed for ‘SparkR’:
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961359912
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] tgravescs commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
tgravescs commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-963232252
thanks @mridulm @dongjoon-hyun
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961401554
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/49377/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961318564
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961350692
Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/49377/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-962004830
**[Test build #144935 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/144935/testReport)** for PR 34485 at commit [`c68b268`](https://github.com/apache/spark/commit/c68b268a1f67c5cd23aa246a01f53531fc1d8aed).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961359912
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961359912
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] tgravescs commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
tgravescs commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961397061
k8s failure not related:
Error: package or namespace load failed for ‘SparkR’:
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961359912
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-962040764
Kubernetes integration test starting
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/49407/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] mridulm commented on a change in pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
mridulm commented on a change in pull request #34485:
URL: https://github.com/apache/spark/pull/34485#discussion_r743377519
##########
File path: docs/running-on-yarn.md
##########
@@ -205,6 +205,28 @@ To use a custom metrics.properties for the application master and executors, upd
</td>
<td>3.0.0</td>
</tr>
+<tr>
+ <td><code>spark.yarn.resourceGpuDeviceName</code></td>
+ <td><code>yarn.io/gpu</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>gpu</code> to the YARN resource
+ representing a GPU. By default YARN uses <code>yarn.io/gpu</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.gpu.*</code> configs.
+ </td>
+ <td>3.2.1</td>
+</tr>
+<tr>
+ <td><code>spark.yarn.resourceFpgaDeviceName</code></td>
+ <td><code>yarn.io/fpga</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>fpga</code> to the YARN resource
+ representing a FPGA. By default YARN uses <code>yarn.io/fpga</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.fpga.*</code> configs.
+ </td>
+ <td>3.2.1</td>
Review comment:
Is this targetting 3.2.1 ? Or master ?
##########
File path: resource-managers/yarn/src/main/scala/org/apache/spark/deploy/yarn/YarnAllocator.scala
##########
@@ -281,7 +281,7 @@ private[yarn] class YarnAllocator(
val resourcesWithDefaults =
ResourceProfile.getResourcesForClusterManager(rp.id, rp.executorResources,
MEMORY_OVERHEAD_FACTOR, sparkConf, isPythonApp,
- ResourceRequestHelper.resourceNameMapping)
+ ResourceRequestHelper.getResourceNameMapping(sparkConf))
Review comment:
nit: Given this should not change, do we want to make it a field and reference that here ?
##########
File path: docs/running-on-yarn.md
##########
@@ -205,6 +205,28 @@ To use a custom metrics.properties for the application master and executors, upd
</td>
<td>3.0.0</td>
</tr>
+<tr>
+ <td><code>spark.yarn.resourceGpuDeviceName</code></td>
+ <td><code>yarn.io/gpu</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>gpu</code> to the YARN resource
+ representing a GPU. By default YARN uses <code>yarn.io/gpu</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.gpu.*</code> configs.
+ </td>
+ <td>3.2.1</td>
+</tr>
+<tr>
+ <td><code>spark.yarn.resourceFpgaDeviceName</code></td>
+ <td><code>yarn.io/fpga</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>fpga</code> to the YARN resource
+ representing a FPGA. By default YARN uses <code>yarn.io/fpga</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.fpga.*</code> configs.
+ </td>
+ <td>3.2.1</td>
Review comment:
Given the scope of the change, and given it is backwardly compatible, I am fine with adding to 3.2.1 as well.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961318564
**[Test build #144907 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/144907/testReport)** for PR 34485 at commit [`f964990`](https://github.com/apache/spark/commit/f9649909fc842cd38cd5b78606a048ed721f3bd9).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-962092164
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/49407/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961336085
**[Test build #144907 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/144907/testReport)** for PR 34485 at commit [`f964990`](https://github.com/apache/spark/commit/f9649909fc842cd38cd5b78606a048ed721f3bd9).
* This patch passes all tests.
* This patch merges cleanly.
* This patch adds no public classes.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961359912
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/144907/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] mridulm commented on a change in pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
mridulm commented on a change in pull request #34485:
URL: https://github.com/apache/spark/pull/34485#discussion_r743377519
##########
File path: docs/running-on-yarn.md
##########
@@ -205,6 +205,28 @@ To use a custom metrics.properties for the application master and executors, upd
</td>
<td>3.0.0</td>
</tr>
+<tr>
+ <td><code>spark.yarn.resourceGpuDeviceName</code></td>
+ <td><code>yarn.io/gpu</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>gpu</code> to the YARN resource
+ representing a GPU. By default YARN uses <code>yarn.io/gpu</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.gpu.*</code> configs.
+ </td>
+ <td>3.2.1</td>
+</tr>
+<tr>
+ <td><code>spark.yarn.resourceFpgaDeviceName</code></td>
+ <td><code>yarn.io/fpga</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>fpga</code> to the YARN resource
+ representing a FPGA. By default YARN uses <code>yarn.io/fpga</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.fpga.*</code> configs.
+ </td>
+ <td>3.2.1</td>
Review comment:
Is this targetting 3.2.1 ? Or master ?
##########
File path: resource-managers/yarn/src/main/scala/org/apache/spark/deploy/yarn/YarnAllocator.scala
##########
@@ -281,7 +281,7 @@ private[yarn] class YarnAllocator(
val resourcesWithDefaults =
ResourceProfile.getResourcesForClusterManager(rp.id, rp.executorResources,
MEMORY_OVERHEAD_FACTOR, sparkConf, isPythonApp,
- ResourceRequestHelper.resourceNameMapping)
+ ResourceRequestHelper.getResourceNameMapping(sparkConf))
Review comment:
nit: Given this should not change, do we want to make it a field and reference that here ?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] mridulm commented on a change in pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
mridulm commented on a change in pull request #34485:
URL: https://github.com/apache/spark/pull/34485#discussion_r743377519
##########
File path: docs/running-on-yarn.md
##########
@@ -205,6 +205,28 @@ To use a custom metrics.properties for the application master and executors, upd
</td>
<td>3.0.0</td>
</tr>
+<tr>
+ <td><code>spark.yarn.resourceGpuDeviceName</code></td>
+ <td><code>yarn.io/gpu</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>gpu</code> to the YARN resource
+ representing a GPU. By default YARN uses <code>yarn.io/gpu</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.gpu.*</code> configs.
+ </td>
+ <td>3.2.1</td>
+</tr>
+<tr>
+ <td><code>spark.yarn.resourceFpgaDeviceName</code></td>
+ <td><code>yarn.io/fpga</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>fpga</code> to the YARN resource
+ representing a FPGA. By default YARN uses <code>yarn.io/fpga</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.fpga.*</code> configs.
+ </td>
+ <td>3.2.1</td>
Review comment:
Is this targetting 3.2.1 ? Or master ?
##########
File path: resource-managers/yarn/src/main/scala/org/apache/spark/deploy/yarn/YarnAllocator.scala
##########
@@ -281,7 +281,7 @@ private[yarn] class YarnAllocator(
val resourcesWithDefaults =
ResourceProfile.getResourcesForClusterManager(rp.id, rp.executorResources,
MEMORY_OVERHEAD_FACTOR, sparkConf, isPythonApp,
- ResourceRequestHelper.resourceNameMapping)
+ ResourceRequestHelper.getResourceNameMapping(sparkConf))
Review comment:
nit: Given this should not change, do we want to make it a field and reference that here ?
##########
File path: docs/running-on-yarn.md
##########
@@ -205,6 +205,28 @@ To use a custom metrics.properties for the application master and executors, upd
</td>
<td>3.0.0</td>
</tr>
+<tr>
+ <td><code>spark.yarn.resourceGpuDeviceName</code></td>
+ <td><code>yarn.io/gpu</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>gpu</code> to the YARN resource
+ representing a GPU. By default YARN uses <code>yarn.io/gpu</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.gpu.*</code> configs.
+ </td>
+ <td>3.2.1</td>
+</tr>
+<tr>
+ <td><code>spark.yarn.resourceFpgaDeviceName</code></td>
+ <td><code>yarn.io/fpga</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>fpga</code> to the YARN resource
+ representing a FPGA. By default YARN uses <code>yarn.io/fpga</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.fpga.*</code> configs.
+ </td>
+ <td>3.2.1</td>
Review comment:
Given the scope of the change, and given it is backwardly compatible, I am fine with adding to 3.2.1 as well.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-962025259
**[Test build #144935 has finished](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/144935/testReport)** for PR 34485 at commit [`c68b268`](https://github.com/apache/spark/commit/c68b268a1f67c5cd23aa246a01f53531fc1d8aed).
* This patch passes all tests.
* This patch merges cleanly.
* This patch adds no public classes.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] mridulm commented on a change in pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
mridulm commented on a change in pull request #34485:
URL: https://github.com/apache/spark/pull/34485#discussion_r743867198
##########
File path: docs/running-on-yarn.md
##########
@@ -205,6 +205,28 @@ To use a custom metrics.properties for the application master and executors, upd
</td>
<td>3.0.0</td>
</tr>
+<tr>
+ <td><code>spark.yarn.resourceGpuDeviceName</code></td>
+ <td><code>yarn.io/gpu</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>gpu</code> to the YARN resource
+ representing a GPU. By default YARN uses <code>yarn.io/gpu</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.gpu.*</code> configs.
+ </td>
+ <td>3.2.1</td>
+</tr>
+<tr>
+ <td><code>spark.yarn.resourceFpgaDeviceName</code></td>
+ <td><code>yarn.io/fpga</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>fpga</code> to the YARN resource
+ representing a FPGA. By default YARN uses <code>yarn.io/fpga</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.fpga.*</code> configs.
+ </td>
+ <td>3.2.1</td>
Review comment:
Given the scope of the change, and given it is backwardly compatible, I am fine with adding to 3.2.1 as well.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-962004830
**[Test build #144935 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/144935/testReport)** for PR 34485 at commit [`c68b268`](https://github.com/apache/spark/commit/c68b268a1f67c5cd23aa246a01f53531fc1d8aed).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
AmplabJenkins commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-962049617
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/144935/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA removed a comment on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
SparkQA removed a comment on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961318564
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961318564
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-962084230
Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/49407/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] tgravescs commented on a change in pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
tgravescs commented on a change in pull request #34485:
URL: https://github.com/apache/spark/pull/34485#discussion_r743661268
##########
File path: docs/running-on-yarn.md
##########
@@ -205,6 +205,28 @@ To use a custom metrics.properties for the application master and executors, upd
</td>
<td>3.0.0</td>
</tr>
+<tr>
+ <td><code>spark.yarn.resourceGpuDeviceName</code></td>
+ <td><code>yarn.io/gpu</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>gpu</code> to the YARN resource
+ representing a GPU. By default YARN uses <code>yarn.io/gpu</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.gpu.*</code> configs.
+ </td>
+ <td>3.2.1</td>
+</tr>
+<tr>
+ <td><code>spark.yarn.resourceFpgaDeviceName</code></td>
+ <td><code>yarn.io/fpga</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>fpga</code> to the YARN resource
+ representing a FPGA. By default YARN uses <code>yarn.io/fpga</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.fpga.*</code> configs.
+ </td>
+ <td>3.2.1</td>
Review comment:
It would be nice to get it in a 3.2.1 so users can get it sooner to work with existing hadoop 3.3.1. Its a pretty small change so impact should be small, but it is an improvement so it you (or others) think its best not to, I'll update to just target master
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] tgravescs commented on a change in pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
tgravescs commented on a change in pull request #34485:
URL: https://github.com/apache/spark/pull/34485#discussion_r743661268
##########
File path: docs/running-on-yarn.md
##########
@@ -205,6 +205,28 @@ To use a custom metrics.properties for the application master and executors, upd
</td>
<td>3.0.0</td>
</tr>
+<tr>
+ <td><code>spark.yarn.resourceGpuDeviceName</code></td>
+ <td><code>yarn.io/gpu</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>gpu</code> to the YARN resource
+ representing a GPU. By default YARN uses <code>yarn.io/gpu</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.gpu.*</code> configs.
+ </td>
+ <td>3.2.1</td>
+</tr>
+<tr>
+ <td><code>spark.yarn.resourceFpgaDeviceName</code></td>
+ <td><code>yarn.io/fpga</code></td>
+ <td>
+ Specify the mapping of the Spark resource type of <code>fpga</code> to the YARN resource
+ representing a FPGA. By default YARN uses <code>yarn.io/fpga</code> but if YARN has been
+ configured with a custom resource type, this allows remapping it.
+ Applies when using the <code>spark.{driver/executor}.resource.fpga.*</code> configs.
+ </td>
+ <td>3.2.1</td>
Review comment:
It would be nice to get it in a 3.2.1 so users can get it sooner to work with existing hadoop 3.3.1. Its a pretty small change so impact should be small, but it is an improvement so it you (or others) think its best not to, I'll update to just target master
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961390941
Kubernetes integration test status failure
URL: https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder-K8s/49377/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-962092164
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder-K8s/49407/
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] AmplabJenkins removed a comment on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
AmplabJenkins removed a comment on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961359912
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961318564
**[Test build #144907 has started](https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/144907/testReport)** for PR 34485 at commit [`f964990`](https://github.com/apache/spark/commit/f9649909fc842cd38cd5b78606a048ed721f3bd9).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] SparkQA commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
SparkQA commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961318564
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org
[GitHub] [spark] tgravescs commented on pull request #34485: [SPARK-37208][YARN]Support mapping Spark gpu/fpga resource types to custom YARN resource types
Posted by GitBox <gi...@apache.org>.
tgravescs commented on pull request #34485:
URL: https://github.com/apache/spark/pull/34485#issuecomment-961397061
k8s failure not related:
Error: package or namespace load failed for ‘SparkR’:
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org