FAQ
Anyone else seen this; Ant's JUnit test runner going OOM on a test?

[junit] Tests run: 4, Failures: 0, Errors: 0, Time elapsed: 7.987 sec
[junit] Exception in thread "Main Thread"
java.lang.OutOfMemoryError: allocLargeObjectOrArray - Object size:
30177672, Num elements: 30177650
[junit] at java.util.Arrays.copyOf(Arrays.java:2786)
[junit] at java.lang.StringCoding.safeTrim(StringCoding.java:64)
[junit] at java.lang.StringCoding.access$300(StringCoding.java:34)
[junit] at
java.lang.StringCoding$StringEncoder.encode(StringCoding.java:251)
[junit] at java.lang.StringCoding.encode(StringCoding.java:272)
[junit] at
java.lang.LangAccessImpl.stringCodingDefaultEncode(LangAccessImpl.java:39)
[junit] at java.lang.String.getBytes(String.java:987)
[junit] at
org.apache.tools.ant.taskdefs.optional.junit.PlainJUnitResultFormatter.endTestSuite(PlainJUnitResultFormatter.java:152)
[junit] at
org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.fireEndTestSuite(JUnitTestRunner.java:619)
[junit] at
org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.run(JUnitTestRunner.java:452)
[junit] at
org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.launch(JUnitTestRunner.java:911)
[junit] at
org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner.main(JUnitTestRunner.java:768)
[junit] Running org.apache.hadoop.mapred.TestKeyValueTextInputFormat
[junit] Tests run: 1, Failures: 0, Errors: 1, Time elapsed: 0 sec
[junit] Test org.apache.hadoop.mapred.TestKeyValueTextInputFormat
FAILED (crashed)


The line in question is just printing out the test run report; it must
have been too big for the JVM:
out.write(sb.toString().getBytes());

I'll file a bugrep with Ant but a fix won't show up until release 1.7.2

Search Discussions

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupcommon-dev @
categorieshadoop
postedAug 4, '08 at 2:53p
activeAug 4, '08 at 2:53p
posts1
users1
websitehadoop.apache.org...
irc#hadoop

1 user in discussion

Steve Loughran: 1 post

People

Translate

site design / logo © 2022 Grokbase