/** * Release the protocol object back to the connection pool. */ void releaseProtocol(IMAPFolder folder, IMAPProtocol protocol) { synchronized (pool) { if (protocol != null) { // If the pool is not full, add the store as a response handler // and return the protocol object to the connection pool. if (!isConnectionPoolFull()) { protocol.addResponseHandler(this); pool.authenticatedConnections.addElement(protocol); if (logger.isLoggable(Level.FINE)) logger.fine( "added an Authenticated connection -- size: " + pool.authenticatedConnections.size()); } else { logger.fine( "pool is full, not adding an Authenticated connection"); try { protocol.logout(); } catch (ProtocolException pex) {}; } } if (pool.folders != null) pool.folders.removeElement(folder); timeoutConnections(); } }
/** * Release the protocol object back to the connection pool. */ void releaseProtocol(IMAPFolder folder, IMAPProtocol protocol) { synchronized (pool) { if (protocol != null) { // If the pool is not full, add the store as a response handler // and return the protocol object to the connection pool. if (!isConnectionPoolFull()) { protocol.addResponseHandler(this); pool.authenticatedConnections.addElement(protocol); if (logger.isLoggable(Level.FINE)) logger.fine( "added an Authenticated connection -- size: " + pool.authenticatedConnections.size()); } else { logger.fine( "pool is full, not adding an Authenticated connection"); try { protocol.logout(); } catch (ProtocolException pex) {}; } } if (pool.folders != null) pool.folders.removeElement(folder); timeoutConnections(); } }
if (protocol != null) protocol.disconnect(); } else if (((IMAPStore)store).isConnectionPoolFull()) {
if (protocol != null) protocol.disconnect(); } else if (((IMAPStore)store).isConnectionPoolFull()) {
/** * Release the protocol object back to the connection pool. */ void releaseProtocol(IMAPFolder folder, IMAPProtocol protocol) { synchronized (pool) { if (protocol != null) { // If the pool is not full, add the store as a response handler // and return the protocol object to the connection pool. if (!isConnectionPoolFull()) { protocol.addResponseHandler(this); pool.authenticatedConnections.addElement(protocol); if (debug) out.println("DEBUG: added an " + "Authenticated connection -- size: " + pool.authenticatedConnections.size()); } else { if (debug) out.println("DEBUG: pool is full, not adding " + "an Authenticated connection"); try { protocol.logout(); } catch (ProtocolException pex) {}; } } if (pool.folders != null) pool.folders.removeElement(folder); timeoutConnections(); } }
/** * Release the protocol object back to the connection pool. */ void releaseProtocol(IMAPFolder folder, IMAPProtocol protocol) { synchronized (pool) { if (protocol != null) { // If the pool is not full, add the store as a response handler // and return the protocol object to the connection pool. if (!isConnectionPoolFull()) { protocol.addResponseHandler(this); pool.authenticatedConnections.addElement(protocol); if (debug) out.println("DEBUG: added an " + "Authenticated connection -- size: " + pool.authenticatedConnections.size()); } else { if (debug) out.println("DEBUG: pool is full, not adding " + "an Authenticated connection"); try { protocol.logout(); } catch (ProtocolException pex) {}; } } if (pool.folders != null) pool.folders.removeElement(folder); timeoutConnections(); } }
/** * Release the protocol object back to the connection pool. */ void releaseProtocol(IMAPFolder folder, IMAPProtocol protocol) { synchronized (pool) { if (protocol != null) { // If the pool is not full, add the store as a response handler // and return the protocol object to the connection pool. if (!isConnectionPoolFull()) { protocol.addResponseHandler(this); pool.authenticatedConnections.addElement(protocol); if (logger.isLoggable(Level.FINE)) logger.fine( "added an Authenticated connection -- size: " + pool.authenticatedConnections.size()); } else { logger.fine( "pool is full, not adding an Authenticated connection"); try { protocol.logout(); } catch (ProtocolException pex) {}; } } if (pool.folders != null) pool.folders.removeElement(folder); timeoutConnections(); } }
/** * Release the protocol object back to the connection pool. */ void releaseProtocol(IMAPFolder folder, IMAPProtocol protocol) { synchronized (pool) { if (protocol != null) { // If the pool is not full, add the store as a response handler // and return the protocol object to the connection pool. if (!isConnectionPoolFull()) { protocol.addResponseHandler(this); pool.authenticatedConnections.addElement(protocol); if (logger.isLoggable(Level.FINE)) logger.fine( "added an Authenticated connection -- size: " + pool.authenticatedConnections.size()); } else { logger.fine( "pool is full, not adding an Authenticated connection"); try { protocol.logout(); } catch (ProtocolException pex) {}; } } if (pool.folders != null) pool.folders.removeElement(folder); timeoutConnections(); } }
/** * Release the protocol object back to the connection pool. */ void releaseProtocol(IMAPFolder folder, IMAPProtocol protocol) { synchronized (pool) { if (protocol != null) { // If the pool is not full, add the store as a response handler // and return the protocol object to the connection pool. if (!isConnectionPoolFull()) { protocol.addResponseHandler(this); pool.authenticatedConnections.addElement(protocol); if (logger.isLoggable(Level.FINE)) logger.fine( "added an Authenticated connection -- size: " + pool.authenticatedConnections.size()); } else { logger.fine( "pool is full, not adding an Authenticated connection"); try { protocol.logout(); } catch (ProtocolException pex) {}; } } if (pool.folders != null) pool.folders.removeElement(folder); timeoutConnections(); } }
/** * Release the protocol object back to the connection pool. */ void releaseProtocol(IMAPFolder folder, IMAPProtocol protocol) { synchronized (pool) { if (protocol != null) { // If the pool is not full, add the store as a response handler // and return the protocol object to the connection pool. if (!isConnectionPoolFull()) { protocol.addResponseHandler(this); pool.authenticatedConnections.addElement(protocol); if (logger.isLoggable(Level.FINE)) logger.fine( "added an Authenticated connection -- size: " + pool.authenticatedConnections.size()); } else { logger.fine( "pool is full, not adding an Authenticated connection"); try { protocol.logout(); } catch (ProtocolException pex) {}; } } if (pool.folders != null) pool.folders.removeElement(folder); timeoutConnections(); } }
if (protocol != null) protocol.disconnect(); } else if (((IMAPStore)store).isConnectionPoolFull()) {
if (protocol != null) protocol.disconnect(); } else if (((IMAPStore)store).isConnectionPoolFull()) {
if (protocol != null) protocol.disconnect(); } else if (((IMAPStore)store).isConnectionPoolFull()) {
if (protocol != null) protocol.disconnect(); } else if (((IMAPStore)store).isConnectionPoolFull()) {
if (protocol != null) protocol.disconnect(); } else if (((IMAPStore)store).isConnectionPoolFull()) {
if (protocol != null) protocol.disconnect(); } else if (((IMAPStore)store).isConnectionPoolFull()) {