1 23 package com.sun.enterprise.resource; 24 import javax.resource.spi.*; 25 import java.util.logging.Logger ; 26 import java.util.logging.Level ; 27 import com.sun.logging.LogDomains; 28 29 39 public class UnpooledConnectionEventListener implements ConnectionEventListener { 40 41 42 static Logger _logger = LogDomains.getLogger(LogDomains.RSR_LOGGER); 43 44 public void connectionClosed(ConnectionEvent evt) { 45 ManagedConnection mc = (ManagedConnection) evt.getSource(); 46 try { 47 mc.destroy(); 48 } catch( Throwable re ) { 49 if (_logger.isLoggable(Level.FINE)) { 50 _logger.fine("error while closing testConnectionPool's mc"); 51 } 52 } 53 if (_logger.isLoggable(Level.FINE)) { 54 _logger.fine("UnpooledConnectionEventListener: Connection closed"); 55 } 56 } 57 58 public void connectionErrorOccurred(ConnectionEvent evt) { 59 } 61 62 public void localTransactionStarted(ConnectionEvent evt) { 63 } 65 66 public void localTransactionCommitted(ConnectionEvent evt) { 67 } 69 70 public void localTransactionRolledback(ConnectionEvent evt) { 71 } 73 74 } 75 76 | Popular Tags |