Github user JoshRosen commented on a diff in the pull request:
https://github.com/apache/spark/pull/9382#discussion_r43567987
--- Diff: core/src/main/scala/org/apache/spark/rdd/SqlNewHadoopRDD.scala ---
@@ -189,32 +189,34 @@ private[spark] class SqlNewHadoopRDD[V: ClassTag](
}
private def close() {
- try {
- if (reader != null) {
+ if (reader != null) {
+ // Close the reader and release it. Note: it's very important
that we don't close the
+ // reader more than once, since that exposes us to
MAPREDUCE-5918 when running against
+ // Hadoop 1.x and older Hadoop 2.x releases. That bug can lead
to non-deterministic
+ // corruption issues when reading compressed input.
+ try {
reader.close()
- reader = null
-
- SqlNewHadoopRDD.unsetInputFileName()
--- End diff --
Whoops, this is why the test was failing.
---
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]