tgravescs commented on a change in pull request #26078: [SPARK-29151][CORE]
Support fractional resources for task resource scheduling
URL: https://github.com/apache/spark/pull/26078#discussion_r342089932
##########
File path:
core/src/main/scala/org/apache/spark/resource/ResourceAllocator.scala
##########
@@ -86,8 +103,8 @@ trait ResourceAllocator {
s"address $address doesn't exist.")
}
val isAvailable = addressAvailabilityMap(address)
- if (!isAvailable) {
- addressAvailabilityMap(address) = true
+ if (isAvailable < slotsPerAddress) {
+ addressAvailabilityMap(address) = addressAvailabilityMap(address) + 1
Review comment:
yeah I think the only issue here are with UI accessing, and I probably
missed this in the reviews for the standalone support. I was thinking it was
just read but its doing a flatMap in there.
But I do think we should protect that. That said it is a separate issue not
introduced by this so I think we should file a separate jira for it,
@jiangxb1987 are you ok with that?
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]