116117118119120121122123
public JRedis getResource() { try { return internalPool.borrowObject(); } catch (Exception e) { throw new PoolException("Could not get a resource from the pool", e); } }
124125126127128129130131
public void returnBrokenResource(final JRedis resource) { try { internalPool.invalidateObject(resource); } catch (Exception e) { throw new PoolException("Could not invalidate the broken resource", e); } }
132133134135136137138139
public void returnResource(final JRedis resource) { try { internalPool.returnObject(resource); } catch (Exception e) { throw new PoolException("Could not return the resource to the pool", e); } }
140141142143144145146147
public void destroy() { try { internalPool.close(); } catch (Exception e) { throw new PoolException("Could not destroy the pool", e); } }
8788899091929394
@SuppressWarnings("unchecked") public RedisAsyncConnection<byte[], byte[]> getResource() { try { return internalPool.borrowObject(); } catch (Exception e) { throw new PoolException("Could not get a resource from the pool", e); } }
9596979899100101102
public void returnBrokenResource(final RedisAsyncConnection<byte[], byte[]> resource) { try { internalPool.invalidateObject(resource); } catch (Exception e) { throw new PoolException("Could not invalidate the broken resource", e); } }
103104105106107108109110
public void returnResource(final RedisAsyncConnection<byte[], byte[]> resource) { try { internalPool.returnObject(resource); } catch (Exception e) { throw new PoolException("Could not return the resource to the pool", e); } }
112113114115116117118119
public void destroy() { try { client.shutdown(); internalPool.close(); } catch (Exception e) { throw new PoolException("Could not destroy the pool", e); } }