| 
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface ConnectionFactory
Factory for creating instances of MemcachedConnection. This is used to provide more fine-grained configuration of connections.
| Method Summary | |
|---|---|
 MemcachedConnection | 
createConnection(List<InetSocketAddress> addrs)
Create a MemcachedConnection for the given SocketAddresses.  | 
 NodeLocator | 
createLocator(List<MemcachedNode> nodes)
Create a NodeLocator instance for the given list of nodes.  | 
 MemcachedNode | 
createMemcachedNode(SocketAddress sa,
                    SocketChannel c,
                    int bufSize)
Create a new memcached node.  | 
 BlockingQueue<Operation> | 
createOperationQueue()
Create a BlockingQueue for operations for a connection.  | 
 BlockingQueue<Operation> | 
createReadOperationQueue()
Create a BlockingQueue for the operations currently expecting to read responses from memcached.  | 
 BlockingQueue<Operation> | 
createWriteOperationQueue()
Create a BlockingQueue for the operations currently expecting to write requests to memcached.  | 
 Transcoder<Object> | 
getDefaultTranscoder()
Get the default transcoder to be used in connections created by this factory.  | 
 FailureMode | 
getFailureMode()
Get the default failure mode for the underlying connection.  | 
 HashAlgorithm | 
getHashAlg()
Get the hash algorithm to be used.  | 
 Collection<ConnectionObserver> | 
getInitialObservers()
Observers that should be established at the time of connection instantiation.  | 
 long | 
getMaxReconnectDelay()
Maximum number of milliseconds to wait between reconnect attempts.  | 
 OperationFactory | 
getOperationFactory()
Get the operation factory for connections built by this connection factory.  | 
 long | 
getOperationTimeout()
Get the operation timeout used by this connection.  | 
 int | 
getReadBufSize()
 | 
 boolean | 
isDaemon()
If true, the IO thread should be a daemon thread.  | 
 boolean | 
shouldOptimize()
If true, low-level optimization is in effect.  | 
 boolean | 
useNagleAlgorithm()
If true, the nagle algorithm will be used on connected sockets.  | 
| Method Detail | 
|---|
MemcachedConnection createConnection(List<InetSocketAddress> addrs)
                                     throws IOException
addrs - the addresses of the memcached servers
IOException - for problems initializing the memcached connections
MemcachedNode createMemcachedNode(SocketAddress sa,
                                  SocketChannel c,
                                  int bufSize)
BlockingQueue<Operation> createOperationQueue()
BlockingQueue<Operation> createReadOperationQueue()
BlockingQueue<Operation> createWriteOperationQueue()
NodeLocator createLocator(List<MemcachedNode> nodes)
OperationFactory getOperationFactory()
long getOperationTimeout()
boolean isDaemon()
boolean useNagleAlgorithm()
 See Socket.setTcpNoDelay(boolean) for more information.
 
Collection<ConnectionObserver> getInitialObservers()
FailureMode getFailureMode()
Transcoder<Object> getDefaultTranscoder()
boolean shouldOptimize()
int getReadBufSize()
HashAlgorithm getHashAlg()
long getMaxReconnectDelay()
  | 
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||