1 22 package org.jboss.ejb3.test.strictpool; 23 24 import org.jboss.logging.Logger; 25 import EDU.oswego.cs.dl.util.concurrent.CountDown; 26 27 32 public class SessionInvoker extends Thread 33 { 34 int id; 35 CountDown done; 36 public Exception runEx; 37 StrictlyPooledSession strictlyPooledSession; 38 39 public SessionInvoker(int id, CountDown done, StrictlyPooledSession strictlyPooledSession) 40 { 41 super("SessionInvoker#"+id); 42 this.id = id; 43 this.done = done; 44 this.strictlyPooledSession = strictlyPooledSession; 45 } 46 public void run() 47 { 48 System.out.println("Begin run, this="+this); 49 try 50 { 51 strictlyPooledSession.methodA(); 52 } 53 catch(Exception e) 54 { 55 runEx = e; 56 } 57 done.release(); 58 System.out.println("End run, this="+this); 59 } 60 61 } 62 | Popular Tags |