MAPREDUCE-6879. TestDFSIO#sequentialTest throws java.lang.NullPointerException due to uninitialized IOStream #215
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
https://issues.apache.org/jira/browse/MAPREDUCE-6879
When I use -seq arg to write files, TestDFSIO#sequentialTest throws java.lang.NullPointerException due to uninitialized stream inherited from IOMapperBase:
[root@7b65290f2609 hadoop-3.0.0-alpha3-SNAPSHOT]# bin/hadoop jar share/hadoop/mapreduce/hadoop-mapreduce-client-jobclient-3.0.0-alpha3-SNAPSHOT-tests.jar TestDFSIO -seq -write
2017-04-20 15:50:43,505 INFO fs.TestDFSIO: TestDFSIO.1.8
2017-04-20 15:50:43,510 INFO fs.TestDFSIO: nrFiles = 1
2017-04-20 15:50:43,510 INFO fs.TestDFSIO: nrBytes (MB) = 1.0
2017-04-20 15:50:43,510 INFO fs.TestDFSIO: bufferSize = 1000000
2017-04-20 15:50:43,510 INFO fs.TestDFSIO: baseDir = /benchmarks/TestDFSIO
2017-04-20 15:50:43,655 WARN util.NativeCodeLoader: Unable to load native-hadoop library for your platform... using builtin-java classes where applicable
java.lang.NullPointerException
at org.apache.hadoop.fs.TestDFSIO$WriteMapper.doIO(TestDFSIO.java:427)
at org.apache.hadoop.fs.TestDFSIO$WriteMapper.doIO(TestDFSIO.java:395)
at org.apache.hadoop.fs.TestDFSIO.sequentialTest(TestDFSIO.java:722)
at org.apache.hadoop.fs.TestDFSIO.run(TestDFSIO.java:846)
at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:76)
at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:90)
at org.apache.hadoop.fs.TestDFSIO.main(TestDFSIO.java:731)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.apache.hadoop.util.ProgramDriver$ProgramDescription.invoke(ProgramDriver.java:71)
at org.apache.hadoop.util.ProgramDriver.run(ProgramDriver.java:144)
at org.apache.hadoop.test.MapredTestDriver.run(MapredTestDriver.java:136)
at org.apache.hadoop.test.MapredTestDriver.main(MapredTestDriver.java:144)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.apache.hadoop.util.RunJar.run(RunJar.java:239)
at org.apache.hadoop.util.RunJar.main(RunJar.java:153)