Announcement Announcement Module
Collapse
No announcement yet.
JVM crash mutexing with database writer Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • JVM crash mutexing with database writer

    Hi everyone,

    I ahve been using spring batch to read a file parse it into onject model do some business processing and write a row in Oracle per record.

    I need to be able to get through at least 100,000 objects.

    I have managed to get spring to perform these actions but upon trying to improve performance there has been a JVM error saying about JDBC mutexing issues.

    Code:
    #
    # An unexpected error has been detected by Java Runtime Environment:
    #
    #  EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x6d8c8f53, pid=6332, tid=3624
    #
    # Java VM: Java HotSpot(TM) Client VM (11.0-b15 mixed mode, sharing windows-x86)
    # Problematic frame:
    # V  [jvm.dll+0xc8f53]
    #
    # If you would like to submit a bug report, please visit:
    #   http://java.sun.com/webapps/bugreport/crash.jsp
    #
    
    ---------------  T H R E A D  ---------------
    
    Current thread (0x02a85c00):  JavaThread "SimpleAsyncTaskExecutor-48012" [_thread_in_vm, id=3624, stack(0x035b0000,0x03600000)]
    
    siginfo: ExceptionCode=0xc0000005, writing address 0x035fd9cc
    
    ---------------  P R O C E S S  ---------------
    
    Java Threads: ( => current thread )
      0x0308b000 JavaThread "SimpleAsyncTaskExecutor-48040" [_thread_blocked, id=5084, stack(0x04400000,0x04450000)]
      0x03390800 JavaThread "SimpleAsyncTaskExecutor-48039" [_thread_blocked, id=4724, stack(0x043b0000,0x04400000)]
      0x031ea800 JavaThread "SimpleAsyncTaskExecutor-48038" [_thread_blocked, id=6428, stack(0x04360000,0x043b0000)]
      0x0315c400 JavaThread "SimpleAsyncTaskExecutor-48037" [_thread_blocked, id=7408, stack(0x03ab0000,0x03b00000)]
      0x03272800 JavaThread "SimpleAsyncTaskExecutor-48036" [_thread_blocked, id=2456, stack(0x03a60000,0x03ab0000)]
      0x03221400 JavaThread "SimpleAsyncTaskExecutor-48035" [_thread_blocked, id=5896, stack(0x03a10000,0x03a60000)]
      0x0322d000 JavaThread "SimpleAsyncTaskExecutor-48034" [_thread_blocked, id=6356, stack(0x039c0000,0x03a10000)]
      0x0315d800 JavaThread "SimpleAsyncTaskExecutor-48033" [_thread_blocked, id=4680, stack(0x03970000,0x039c0000)]
      0x03218c00 JavaThread "SimpleAsyncTaskExecutor-48032" [_thread_blocked, id=2932, stack(0x037e0000,0x03830000)]
      0x02b3a400 JavaThread "SimpleAsyncTaskExecutor-48031" [_thread_blocked, id=6300, stack(0x03740000,0x03790000)]
      0x033bd400 JavaThread "SimpleAsyncTaskExecutor-48030" [_thread_blocked, id=1224, stack(0x036f0000,0x03740000)]
      0x0327d000 JavaThread "SimpleAsyncTaskExecutor-48029" [_thread_blocked, id=5092, stack(0x036a0000,0x036f0000)]
      0x02ed3400 JavaThread "SimpleAsyncTaskExecutor-48028" [_thread_blocked, id=6436, stack(0x03650000,0x036a0000)]
      0x02ef0400 JavaThread "SimpleAsyncTaskExecutor-48027" [_thread_blocked, id=204, stack(0x03600000,0x03650000)]
      0x0325e800 JavaThread "SimpleAsyncTaskExecutor-48026" [_thread_blocked, id=4900, stack(0x03560000,0x035b0000)]
      0x0314c400 JavaThread "SimpleAsyncTaskExecutor-48025" [_thread_blocked, id=6936, stack(0x03510000,0x03560000)]
      0x03169800 JavaThread "SimpleAsyncTaskExecutor-48024" [_thread_blocked, id=4064, stack(0x034c0000,0x03510000)]
      0x031edc00 JavaThread "SimpleAsyncTaskExecutor-48023" [_thread_blocked, id=4152, stack(0x03920000,0x03970000)]
      0x03267000 JavaThread "SimpleAsyncTaskExecutor-48022" [_thread_blocked, id=7792, stack(0x038d0000,0x03920000)]
      0x031f4400 JavaThread "SimpleAsyncTaskExecutor-48019" [_thread_blocked, id=3036, stack(0x03790000,0x037e0000)]
    =>0x02a85c00 JavaThread "SimpleAsyncTaskExecutor-48012" [_thread_in_vm, id=3624, stack(0x035b0000,0x03600000)]
      0x0309d800 JavaThread "task-scheduler-3" [_thread_blocked, id=8044, stack(0x03460000,0x034b0000)]
      0x030f5c00 JavaThread "task-scheduler-2" [_thread_blocked, id=4912, stack(0x03410000,0x03460000)]
      0x030e5c00 JavaThread "task-scheduler-1" [_thread_blocked, id=828, stack(0x033c0000,0x03410000)]
      0x02a6fc00 JavaThread "Low Memory Detector" daemon [_thread_blocked, id=1060, stack(0x02d20000,0x02d70000)]
      0x02a6cc00 JavaThread "CompilerThread0" daemon [_thread_blocked, id=5372, stack(0x02cd0000,0x02d20000)]
      0x02a6b400 JavaThread "Attach Listener" daemon [_thread_blocked, id=6500, stack(0x02c80000,0x02cd0000)]
      0x02a6a000 JavaThread "Signal Dispatcher" daemon [_thread_blocked, id=2076, stack(0x02c30000,0x02c80000)]
      0x02a64800 JavaThread "Finalizer" daemon [_thread_blocked, id=4980, stack(0x02be0000,0x02c30000)]
      0x02a5fc00 JavaThread "Reference Handler" daemon [_thread_blocked, id=7576, stack(0x02b90000,0x02be0000)]
      0x003a7400 JavaThread "main" [_thread_blocked, id=4268, stack(0x008c0000,0x00910000)]
    
    Other Threads:
      0x02a5e400 VMThread [stack: 0x02b40000,0x02b90000] [id=7656]
      0x02a71400 WatcherThread [stack: 0x02d70000,0x02dc0000] [id=2592]
    
    VM state:synchronizing (normal execution)
    
    VM Mutex/Monitor currently owned by a thread:  ([mutex/lock_event])
    [0x003a64d8] UNKNOWN - owner thread: 0x02a5e400
    [0x003a6938] UNKNOWN - owner thread: 0x02ed3400
    
    Heap
     def new generation   total 960K, used 959K [0x22990000, 0x22a90000, 0x22e70000)
      eden space 896K, 100% used [0x22990000, 0x22a70000, 0x22a70000)
      from space 64K,  99% used [0x22a80000, 0x22a8fff8, 0x22a90000)
      to   space 64K,   0% used [0x22a70000, 0x22a70000, 0x22a80000)
     tenured generation   total 6208K, used 2621K [0x22e70000, 0x23480000, 0x26990000)
       the space 6208K,  42% used [0x22e70000, 0x230ff4c8, 0x230ff600, 0x23480000)
     compacting perm gen  total 12288K, used 8315K [0x26990000, 0x27590000, 0x2a990000)
       the space 12288K,  67% used [0x26990000, 0x271aeee8, 0x271af000, 0x27590000)
        ro space 8192K,  63% used [0x2a990000, 0x2aea3888, 0x2aea3a00, 0x2b190000)
        rw space 12288K,  53% used [0x2b190000, 0x2b7f7c08, 0x2b7f7e00, 0x2bd90000)
    
    Dynamic libraries:
    0x00400000 - 0x00424000 	C:\Program Files\Java\jre6\bin\javaw.exe
    0x7c900000 - 0x7c9b2000 	C:\WINDOWS\system32\ntdll.dll
    0x7c800000 - 0x7c8f5000 	C:\WINDOWS\system32\kernel32.dll
    0x77dd0000 - 0x77e6b000 	C:\WINDOWS\system32\ADVAPI32.dll
    0x77e70000 - 0x77f02000 	C:\WINDOWS\system32\RPCRT4.dll
    0x77fe0000 - 0x77ff1000 	C:\WINDOWS\system32\Secur32.dll
    0x77d40000 - 0x77dd0000 	C:\WINDOWS\system32\USER32.dll
    0x77f10000 - 0x77f58000 	C:\WINDOWS\system32\GDI32.dll
    0x7c340000 - 0x7c396000 	C:\Program Files\Java\jre6\bin\msvcr71.dll
    0x6d800000 - 0x6da56000 	C:\Program Files\Java\jre6\bin\client\jvm.dll
    0x76b40000 - 0x76b6d000 	C:\WINDOWS\system32\WINMM.dll
    0x6d280000 - 0x6d288000 	C:\Program Files\Java\jre6\bin\hpi.dll
    0x76bf0000 - 0x76bfb000 	C:\WINDOWS\system32\PSAPI.DLL
    0x6d7b0000 - 0x6d7bc000 	C:\Program Files\Java\jre6\bin\verify.dll
    0x6d320000 - 0x6d33f000 	C:\Program Files\Java\jre6\bin\java.dll
    0x6d7f0000 - 0x6d7ff000 	C:\Program Files\Java\jre6\bin\zip.dll
    0x0ffd0000 - 0x0fff8000 	C:\WINDOWS\system32\rsaenh.dll
    0x77c10000 - 0x77c68000 	C:\WINDOWS\system32\msvcrt.dll
    0x769c0000 - 0x76a73000 	C:\WINDOWS\system32\USERENV.dll
    0x5b860000 - 0x5b8b4000 	C:\WINDOWS\system32\netapi32.dll
    0x6d610000 - 0x6d623000 	C:\Program Files\Java\jre6\bin\net.dll
    0x71ab0000 - 0x71ac7000 	C:\WINDOWS\system32\WS2_32.dll
    0x71aa0000 - 0x71aa8000 	C:\WINDOWS\system32\WS2HELP.dll
    0x71a50000 - 0x71a8f000 	C:\WINDOWS\System32\mswsock.dll
    0x76f20000 - 0x76f47000 	C:\WINDOWS\system32\DNSAPI.dll
    0x76fb0000 - 0x76fb8000 	C:\WINDOWS\System32\winrnr.dll
    0x76f60000 - 0x76f8c000 	C:\WINDOWS\system32\WLDAP32.dll
    0x76fc0000 - 0x76fc6000 	C:\WINDOWS\system32\rasadhlp.dll
    0x662b0000 - 0x66308000 	C:\WINDOWS\system32\hnetcfg.dll
    0x71a90000 - 0x71a98000 	C:\WINDOWS\System32\wshtcpip.dll
    
    VM Arguments:
    jvm_args: -Dfile.encoding=Cp1252 
    java_command: com.edfe.orchard.ppmip.ContextSetter
    Launcher Type: SUN_STANDARD
    
    Environment Variables:
    PATH=C:/Program Files/Java/jre6/bin/client;C:/Program Files/Java/jre6/bin;c:\oraclexe\app\oracle\product\10.2.0\server\bin;c:\XEClient\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program Files\Common Files\Artemis\;C:\Program Files\ARTEMIS\;C:\Program Files\Graphviz2.22\bin;c:\Program Files\Microsoft SQL Server\90\Tools\binn\;c:\Program Files\Microsoft Visual Studio 8\Common7\IDE\PrivateAssemblies\;c:\Program Files\Microsoft SQL Server\90\DTS\Binn\;c:\Program Files\Microsoft SQL Server\90\Tools\Binn\VSShell\Common7\IDE\;C:\instantclient_11_1
    USERNAME=Noake1j
    OS=Windows_NT
    PROCESSOR_IDENTIFIER=x86 Family 6 Model 15 Stepping 11, GenuineIntel
    
    
    
    ---------------  S Y S T E M  ---------------
    
    OS: Windows XP Build 2600 Service Pack 2
    
    CPU:total 2 (2 cores per cpu, 1 threads per core) family 6 model 15 stepping 11, cmov, cx8, fxsr, mmx, sse, sse2, sse3, ssse3
    
    Memory: 4k page, physical 2050280k(807352k free), swap 3987788k(2312200k free)
    
    vm_info: Java HotSpot(TM) Client VM (11.0-b15) for windows-x86 JRE (1.6.0_10-rc-b28), built on Jul 21 2008 00:52:03 by "java_re" with MS VC++ 7.1
    
    time: Fri Sep 18 11:07:57 2009
    elapsed time: 141 seconds

    My config is as follows

    Code:
    <beans:bean id="writer" class="com.edfe.orchard.ppmip.io.writing.SimpleWriter" >
    	         <beans:property name="nipDao" ref="nipDao" />
     	</beans:bean> 	  
    
    	<beans:bean id="nipDao" class="com.edfe.orchard.ppmip.io.writing.JdbcNipdao" >
    	
    		 <beans:property name="jdbcTemplate"> 
    		 <beans:ref bean="jdbcTemplate" /> 
    		 </beans:property>
    	</beans:bean> 
    	
     <beans:bean id="jdbcTemplate" class="org.springframework.jdbc.core.JdbcTemplate"> 
     <beans:constructor-arg> 
     <beans:ref bean="datasource" /> 
     </beans:constructor-arg> 
     </beans:bean>
    
    
    	
    	<beans:bean id="datasource" class="org.apache.commons.dbcp.BasicDataSource">
    	 <beans:property name="driverClassName" value="oracle.jdbc.driver.OracleDriver" />
    	 <beans:property name="url" value="jdbc:oracle:thin:@" /> 
    	 <beans:property name="username" value="" />
    	 <beans:property name="password" value="" /> 
    	 <beans:property name="maxActive" value="20"/>  </beans:bean>
Working...
X