com.googlecode.hibernate.memcached.spymemcached
Class SpyMemcacheClientFactory

java.lang.Object
  extended by com.googlecode.hibernate.memcached.spymemcached.SpyMemcacheClientFactory
All Implemented Interfaces:
MemcacheClientFactory

public class SpyMemcacheClientFactory
extends Object
implements MemcacheClientFactory

Parses hibernate properties to produce a MemcachedClient.
See MemcachedCacheProvider for property details.

Author:
Ray Krueger

Field Summary
static String PROP_CONNECTION_FACTORY
           
static String PROP_DAEMON_MODE
           
static String PROP_HASH_ALGORITHM
           
static String PROP_OPERATION_QUEUE_LENGTH
           
static String PROP_OPERATION_TIMEOUT
           
static String PROP_PASSWORD
           
static String PROP_READ_BUFFER_SIZE
           
static String PROP_SERVERS
           
static String PROP_USERNAME
           
 
Constructor Summary
SpyMemcacheClientFactory(PropertiesHelper properties)
           
 
Method Summary
protected  net.spy.memcached.auth.AuthDescriptor createAuthDescriptor()
           
 Memcache createMemcacheClient()
           
protected  net.spy.memcached.ConnectionFactory getConnectionFactory()
           
 String getConnectionFactoryName()
           
 net.spy.memcached.HashAlgorithm getHashAlgorithm()
           
 int getOperationQueueLength()
           
 long getOperationTimeoutMillis()
           
protected  PropertiesHelper getProperties()
           
 int getReadBufferSize()
           
 String getServerList()
           
 boolean isDaemonMode()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PROP_SERVERS

public static final String PROP_SERVERS
See Also:
Constant Field Values

PROP_OPERATION_QUEUE_LENGTH

public static final String PROP_OPERATION_QUEUE_LENGTH
See Also:
Constant Field Values

PROP_READ_BUFFER_SIZE

public static final String PROP_READ_BUFFER_SIZE
See Also:
Constant Field Values

PROP_OPERATION_TIMEOUT

public static final String PROP_OPERATION_TIMEOUT
See Also:
Constant Field Values

PROP_HASH_ALGORITHM

public static final String PROP_HASH_ALGORITHM
See Also:
Constant Field Values

PROP_CONNECTION_FACTORY

public static final String PROP_CONNECTION_FACTORY
See Also:
Constant Field Values

PROP_DAEMON_MODE

public static final String PROP_DAEMON_MODE
See Also:
Constant Field Values

PROP_USERNAME

public static final String PROP_USERNAME
See Also:
Constant Field Values

PROP_PASSWORD

public static final String PROP_PASSWORD
See Also:
Constant Field Values
Constructor Detail

SpyMemcacheClientFactory

public SpyMemcacheClientFactory(PropertiesHelper properties)
Method Detail

createMemcacheClient

public Memcache createMemcacheClient()
                              throws Exception
Specified by:
createMemcacheClient in interface MemcacheClientFactory
Throws:
Exception

getConnectionFactory

protected net.spy.memcached.ConnectionFactory getConnectionFactory()

createAuthDescriptor

protected net.spy.memcached.auth.AuthDescriptor createAuthDescriptor()

getServerList

public String getServerList()

getOperationQueueLength

public int getOperationQueueLength()

getReadBufferSize

public int getReadBufferSize()

getOperationTimeoutMillis

public long getOperationTimeoutMillis()

isDaemonMode

public boolean isDaemonMode()

getHashAlgorithm

public net.spy.memcached.HashAlgorithm getHashAlgorithm()

getConnectionFactoryName

public String getConnectionFactoryName()

getProperties

protected PropertiesHelper getProperties()


Copyright © 2015. All rights reserved.