I'm writing a webcrawler using HTMLUnit, and for speed purposes I've multithreaded it. The crawler takes in a series of webpages and extracts the same bit of text from each of them. Each thread has its own text file to which it writes these extracted bits. I've set it up so I can make N threads writing to N files. When I set N to 1, I don't get the error above, but when I set it to anything else, I get the extended error pasted below in all its glory. My suspicion is that the error comes from simultaneous requests to write, but I'm really not sure. If someone could offer some guidance for dealing with these error messages that would be great. Both understanding what they mean, and fixing the problem. I can post my code if need be. Thanks in advance.
#
# A fatal error has been detected by the Java Runtime Environment:
#
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x00000000678932f5, pid=6264, tid=3912
#
# JRE version: 7.0_07-b11
# Java VM: Java HotSpot(TM) 64-Bit Server VM (23.3-b01 mixed mode windows-amd64 compressed oops)
# Problematic frame:
# V [jvm.dll+0x732f5]
#
# Failed to write core dump. Minidumps are not enabled by default on client versions of Windows
#
# If you would like to submit a bug report, please visit:
# http://bugreport.sun.com/bugreport/crash.jsp
#
--------------- T H R E A D ---------------
Current thread (0x000000000e033000): JavaThread "2" [_thread_in_vm, id=3912, \stack(0x000000000ef20000,0x000000000f020000)]
siginfo: ExceptionCode=0xc0000005, reading address 0x000000068000000c
Registers:
RAX=0x000000077ffffffd, RBX=0x0000000000002e95, RCX=0x000000000f01ce50, RDX=0xffffffff0000000f
RSP=0x000000000f01ce28, RBP=0x000000000f01ce60, RSI=0x0000000000000020, RDI=0x0000000000000000
R8 =0x000000007ffffffd, R9 =0x000000007ffffffd, R10=0x0000000000002e95, R11=0x000000077ffffffd
R12=0x0000000011ed7610, R13=0x0000000000000002, R14=0x000000078060ae80, R15=0x000000000e00d028
RIP=0x00000000678932f5, EFLAGS=0x0000000000010296
Top of Stack: (sp=0x000000000f01ce28)
0x000000000f01ce28: 0000000067905704 0000000000000002
0x000000000f01ce38: 00000000678c3339 000000000f01ce60
0x000000000f01ce48: 000000000e003dd0 000000077ffffffd
0x000000000f01ce58: 00000000000000aa 000000000e00cc50
0x000000000f01ce68: 000000000f01cf10 000000000e00cc40
0x000000000f01ce78: 0000000011ed7610 000000078060ae80
0x000000000f01ce88: 0000000780611698 000000000e003dd0
0x000000000f01ce98: 0000000067904f2c 000000000e003dd0
0x000000000f01cea8: 0000000001000000 000000000f01cf10
0x000000000f01ceb8: 0000000002000000 0000000000000002
0x000000000f01cec8: 000000000000a548 0000000000000003
0x000000000f01ced8: 000000000e00cc40 000000000e003dd0
0x000000000f01cee8: 0000000067905173 000000078060ae80
0x000000000f01cef8: 0000000000000328 000000000000a7e8
0x000000000f01cf08: 000000000000a4c0 000000000e00d068
0x000000000f01cf18: 00002eac00002e95 000000aa00005144
Instructions: (pc=0x00000000678932f5)
0x00000000678932d5: 40 48 83 c4 20 5f e9 f0 ff 03 00 4c 63 01 41 8d
0x00000000678932e5: 44 90 10 48 63 d0 48 8b 01 48 83 e2 fc 49 2b d0
0x00000000678932f5: 8b 0c 02 0f b6 c1 89 4c 24 10 0f b6 4c 24 11 c1
0x0000000067893305: e0 08 0b c1 0f b6 4c 24 12 c1 e0 08 0b c1 0f b6
Register to memory mapping:
RAX=0x000000077ffffffd is an oop
{constMethod}
- klass: {other class}
- method: 0x00000007800022b0 {method} 'getParamOrVarName' '(I)Ljava/lang/String;' in 'net/sourceforge/htmlunit/corejs/javascript/gen/http___www_phila_gov_water_swmap_client_lib_jquery_1_10_2_min_js_30104'
- exceptions: 0x000000077ca01d50
bci_from(000000077FFFFFFD) = 11925; print_codes():
RBX=0x0000000000002e95 is an unknown value
RCX=0x000000000f01ce50 is pointing into the stack for thread: 0x000000000e033000
RDX=0xffffffff0000000f is an unknown value
RSP=0x000000000f01ce28 is pointing into the stack for thread: 0x000000000e033000
RBP=0x000000000f01ce60 is pointing into the stack for thread: 0x000000000e033000
RSI=0x0000000000000020 is an unknown value
RDI=0x0000000000000000 is an unknown value
R8 =0x000000007ffffffd is an unknown value
R9 =0x000000007ffffffd is an unknown value
R10=0x0000000000002e95 is an unknown value
R11=0x000000077ffffffd is an oop
{constMethod}
- klass: {other class}
- method: 0x00000007800022b0 {method} 'getParamOrVarName' '(I)Ljava/lang/String;' in 'net/sourceforge/htmlunit/corejs/javascript/gen/http___www_phila_gov_water_swmap_client_lib_jquery_1_10_2_min_js_30104'
- exceptions: 0x000000077ca01d50
bci_from(000000077FFFFFFD) = 11925; print_codes():
R12=0x0000000011ed7610 is an unknown value
R13=0x0000000000000002 is an unknown value
R14=