@Override public Set<ActiveMQDestination> doGetDestinations(TransactionContext c) throws SQLException, IOException { HashSet<ActiveMQDestination> rc = new HashSet<ActiveMQDestination>(); PreparedStatement s = null; ResultSet rs = null; try { s = c.getConnection().prepareStatement(this.statements.getFindAllDestinationsStatement()); rs = s.executeQuery(); while (rs.next()) { rc.add(ActiveMQDestination.createDestination(rs.getString(1), ActiveMQDestination.QUEUE_TYPE)); } } finally { close(rs); close(s); } return rc; }
public Set<ActiveMQDestination> doGetDestinations(TransactionContext c) throws SQLException, IOException { HashSet<ActiveMQDestination> rc = new HashSet<ActiveMQDestination>(); PreparedStatement s = null; ResultSet rs = null; cleanupExclusiveLock.readLock().lock(); try { s = c.getConnection().prepareStatement(this.statements.getFindAllDestinationsStatement()); rs = s.executeQuery(); while (rs.next()) { rc.add(ActiveMQDestination.createDestination(rs.getString(1), ActiveMQDestination.QUEUE_TYPE)); } } finally { cleanupExclusiveLock.readLock().unlock(); close(rs); close(s); } return rc; }
@Override public Set<ActiveMQDestination> doGetDestinations(TransactionContext c) throws SQLException, IOException { HashSet<ActiveMQDestination> rc = new HashSet<ActiveMQDestination>(); PreparedStatement s = null; ResultSet rs = null; try { s = c.getConnection().prepareStatement(this.statements.getFindAllDestinationsStatement()); rs = s.executeQuery(); while (rs.next()) { rc.add(ActiveMQDestination.createDestination(rs.getString(1), ActiveMQDestination.QUEUE_TYPE)); } } finally { close(rs); close(s); } return rc; }
@Override public Set<ActiveMQDestination> doGetDestinations(TransactionContext c) throws SQLException, IOException { HashSet<ActiveMQDestination> rc = new HashSet<ActiveMQDestination>(); PreparedStatement s = null; ResultSet rs = null; try { s = c.getConnection().prepareStatement(this.statements.getFindAllDestinationsStatement()); rs = s.executeQuery(); while (rs.next()) { rc.add(ActiveMQDestination.createDestination(rs.getString(1), ActiveMQDestination.QUEUE_TYPE)); } } finally { close(rs); close(s); } return rc; }
@Override public Set<ActiveMQDestination> doGetDestinations(TransactionContext c) throws SQLException, IOException { HashSet<ActiveMQDestination> rc = new HashSet<ActiveMQDestination>(); PreparedStatement s = null; ResultSet rs = null; try { s = c.getConnection().prepareStatement(this.statements.getFindAllDestinationsStatement()); rs = s.executeQuery(); while (rs.next()) { rc.add(ActiveMQDestination.createDestination(rs.getString(1), ActiveMQDestination.QUEUE_TYPE)); } } finally { close(rs); close(s); } return rc; }