Explanation of J2C working threads
 Technote (troubleshooting)
 
Problem(Abstract)
The IBM® WebSphere® Application Server connection manager implements the Java™ 2 Connector (J2C) architecture. It creates threads to manage the connection pools. How does one identify these threads and what is the function of these threads?
 
Resolving the problem
These J2C threads are seen when javacores are generated for the WebSphere Application Server Java process. The connection manager allocates these threads. They will have a thread id of Thread-###. Not all threads with this sort of thread name are J2C threads. The thread name of Thread-### simply means that they are generated by a Java process but not given a specific thread name.
Below are some example threads that are created by the J2C code to manage the connection pools.

Type 1: TaskTimer thread

This thread is used to reclaim connections.  Typically, there is one such thread per J2C connection pool -- JDBC, JMS, or a resource adapter that implements the J2EE J2C specification.
Note: there is a problem in some versions of WebSphere AppServer in which the number of TaskTimer threads can grow over time.  This is due to a problem in IBM MQ.  

3XMTHREADINFO      "Thread-681" (TID:0xB08CED28, sys_thread_t:0x37A0B8A8, state:MW, native ID:0x30F5B) prio=5
4XESTACKTRACE          at com.ibm.ejs.j2c.poolmanager.TaskTimer.executeTask
                      (TaskTimer.java(Compiled Code))

4XESTACKTRACE          at com.ibm.ejs.j2c.poolmanager.TaskTimer.run(TaskTimer.java:113)
3XHNATIVESTACK       Native Stack
NULL                 ------------
3XHSTACKLINE         at 0xD004A36C in _global_lock_common
3XHSTACKLINE         at 0xD0048D74 in pthread_mutex_lock
3XHSTACKLINE         at 0xD0D5A344 in cooperative_mutex_lock
3XHSTACKLINE         at 0xD0D59F4C in sysMonitorEnter
3XHSTACKLINE         at 0xD0C756EC in atomicSetTLHAllocbits
3XHSTACKLINE         at 0xD0C73ABC in cacheFillBlock
3XHSTACKLINE         at 0xD0C7A090 in cacheAllocWithInitialization
NULL  


Type 2: PoolQuiesce thread
       
This thread is waiting to clean up a pool. It typically runs while the Application Server JVM is stopping. It is alive while the transaction in which the connection was obtained is active.

3XMTHREADINFO      "Thread-680" (TID:0xB08CED98, sys_thread_t:0x3784FAA8, state:CW, native ID:0x30E5A) prio=5
4XESTACKTRACE          at java.lang.Thread.sleep(Native Method)
4XESTACKTRACE          at com.ibm.ejs.j2c.poolmanager.PoolQuiesceThread.run
                      (PoolQuiesceThread.java(Compiled Code))

3XHNATIVESTACK       Native Stack
NULL                 ------------
3XHSTACKLINE         at 0xD0055BCC in _event_sleep
3XHSTACKLINE         at 0xD00560BC in _event_wait
3XHSTACKLINE         at 0xD0062184 in _cond_wait_local
3XHSTACKLINE         at 0xD0062748 in _cond_wait
3XHSTACKLINE         at 0xD00631B8 in pthread_cond_timedwait
3XHSTACKLINE         at 0xD0D5A5F8 in condvarTimedWaitUpTo248Days
3XHSTACKLINE         at 0xD0D5A830 in condvarTimedWait
3XHSTACKLINE         at 0xD0D59740 in sysMonitorWait
3XHSTACKLINE         at 0xD0CF9A90 in xmThreadSleep
3XHSTACKLINE         at 0xD0B91070 in JVM_Sleep
 
 
Cross Reference information
Segment Product Component Platform Version Edition
Application Servers Runtimes for Java Technology Java SDK
 
 


Document Information


Product categories: Software > Application Servers > Distributed Application & Web Servers > WebSphere Application Server > DB Connections/Connection Pooling
Operating system(s): Windows
Software version: 5.1.1.1
Software edition:
Reference #: 1180624
IBM Group: Software Group
Modified date: Aug 16, 2004