Github user JoshRosen commented on a diff in the pull request:
https://github.com/apache/spark/pull/11502#discussion_r54972851
--- Diff: core/src/main/scala/org/apache/spark/storage/BlockManager.scala
---
@@ -734,9 +740,9 @@ private[spark] class BlockManager(
* @param keepReadLock if true, this method will hold the read lock when
it returns (even if the
* block already exists). If false, this method will
hold no locks when it
* returns.
- * @return `Some(PutResult)` if the block did not exist and could not be
successfully cached,
- * or None if the block already existed or was successfully
stored (fully consuming
- * the input data / input iterator).
+ * @return `Some(Option[Iterator[Any])` if the block did not exist and
could not be successfully
--- End diff --
Basically, the problem is that we need to distinguish between three
outcomes: success, failure while storing bytes, and failure while storing an
iterator. This is only called in one place internally, so I got lazy and
neglected to make a simpler return type to capture this distinction.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]