public class ORemoteConnectionManager extends Object implements OChannelListener
| Modifier and Type | Field and Description |
|---|---|
protected ConcurrentHashMap<String,com.orientechnologies.common.concur.resource.OResourcePool<String,OChannelBinaryAsynchClient>> |
connections |
static String |
PARAM_MAX_POOL |
protected long |
timeout |
| Constructor and Description |
|---|
ORemoteConnectionManager(int iMaxConnectionPerURL,
long iTimeout) |
| Modifier and Type | Method and Description |
|---|---|
OChannelBinaryAsynchClient |
acquire(String iServerURL,
com.orientechnologies.orient.core.config.OContextConfiguration clientConfiguration,
Map<String,Object> iConfiguration,
ORemoteServerEventListener iListener) |
void |
close() |
protected void |
closePool(com.orientechnologies.common.concur.resource.OResourcePool<String,OChannelBinaryAsynchClient> pool) |
void |
closePool(String url) |
protected OChannelBinaryAsynchClient |
createNetworkConnection(String iServerURL,
com.orientechnologies.orient.core.config.OContextConfiguration clientConfiguration,
Map<String,Object> iAdditionalArg,
ORemoteServerEventListener asynchEventListener) |
int |
getAvailableConnections(String url) |
int |
getCreatedInstancesInPool(String url) |
int |
getMaxResources(String url) |
Set<String> |
getURLs() |
void |
onChannelClose(OChannel channel) |
void |
release(OChannelBinaryAsynchClient conn) |
void |
remove(OChannelBinaryAsynchClient conn) |
public static final String PARAM_MAX_POOL
protected final ConcurrentHashMap<String,com.orientechnologies.common.concur.resource.OResourcePool<String,OChannelBinaryAsynchClient>> connections
protected final long timeout
public ORemoteConnectionManager(int iMaxConnectionPerURL,
long iTimeout)
public void close()
public OChannelBinaryAsynchClient acquire(String iServerURL, com.orientechnologies.orient.core.config.OContextConfiguration clientConfiguration, Map<String,Object> iConfiguration, ORemoteServerEventListener iListener)
public void release(OChannelBinaryAsynchClient conn)
public void remove(OChannelBinaryAsynchClient conn)
public void onChannelClose(OChannel channel)
onChannelClose in interface OChannelListenerpublic int getMaxResources(String url)
public int getAvailableConnections(String url)
public int getCreatedInstancesInPool(String url)
public void closePool(String url)
protected void closePool(com.orientechnologies.common.concur.resource.OResourcePool<String,OChannelBinaryAsynchClient> pool)
protected OChannelBinaryAsynchClient createNetworkConnection(String iServerURL, com.orientechnologies.orient.core.config.OContextConfiguration clientConfiguration, Map<String,Object> iAdditionalArg, ORemoteServerEventListener asynchEventListener) throws com.orientechnologies.common.io.OIOException
com.orientechnologies.common.io.OIOExceptionCopyright © 2009–2015 Orient Technologies. All rights reserved.