public class SenderResourcePool extends ResourcePool
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CLASS_VERSION
Class version string
|
mBlocking, mCheckoutBlockTime, mCreatingResources, mCreationTimeLimit, mFreeResources, mHealthy, mMax, mMaxFree, mMaxPendingCreations, mMaxStartupAttempts, mMin, mPool, mResourceClassName, mStartupSleepTime, mUnusedPoolSlots
SERVICE_INFO_KEY
RESOURCE_BUNDLE, RSRC_blockTimeout, RSRC_ciCreateFailure, RSRC_ciForeignResource, RSRC_ciWrongResource, RSRC_coNonRunning, RSRC_creationLimit, RSRC_creationTimeout, RSRC_failedInitialPopulation, RSRC_hitPoolMax, RSRC_maxResourcePerThread, RSRC_maxThreads, RSRC_misconfiguration, RSRC_nestedCheckout, RSRC_nonOwningThread, RSRC_notImplemented, RSRC_poolDisabled, RSRC_startupFailure, RSRC_usingClosedConnection
DEFAULT_LOG_TRACE_STATUS
DEFAULT_LOG_DEBUG_STATUS, DEFAULT_LOG_ERROR_STATUS, DEFAULT_LOG_INFO_STATUS, DEFAULT_LOG_WARNING_STATUS
Constructor and Description |
---|
SenderResourcePool()
Constructs an instanceof SenderResourcePool
|
Modifier and Type | Method and Description |
---|---|
void |
closeAllConnections()
Close all the socket connections to every remote server
|
java.lang.Object |
createResource()
Returns a DistributorSender instance connected to the remote servers
|
void |
destroyResource(java.lang.Object pResource)
Closes the connections to the remove server
|
long |
getConnectionTimeout()
Returns the length of time in milliseconds that this connection
will wait for a connection to its remote target.
|
java.lang.String |
getContentItemNameProperty()
Returns property ContentItemNameProperty
|
java.io.File |
getDocumentRoot()
Returns property DocumentRoot
|
java.lang.String |
getDocumentRootCachePath()
Returns property DocumentRootCachePath
|
java.lang.String |
getDocumentRootContextPath()
Get the context path to prepend to generated URI's that
refer to files in the document root.
|
int |
getMinReconnectInterval()
Returns property MinReconnectInterval, the minimum interval between connect retries in msec
(default 120000 msec)
|
int |
getReadTimeout()
Returns property ReadTimeout (default 30000 msec)
|
atg.distributor.RemoteServerCache |
getRemoteServerCache()
Returns property RemoteServerCache
|
java.lang.String[] |
getServerList()
Returns property ServerList, the list of
host:port combinations
that this client should connect to. |
int |
getWriteTimeout()
Returns property WriteTimeout (default 30000 msec)
|
void |
initializeAllConnections()
Attempts to close any open connections, then rebuilds and reconnects to the hosts
defined in the
serverList property. |
boolean |
isCacheLocally()
Returns property CacheLocally.
|
boolean |
isCreateCacheDirectories()
Returns property CreateCacheDirectories
|
boolean |
isEscapeURI()
Returns property EscapeURI
|
boolean |
isFlatten()
Returns property Flatten
|
boolean |
isPre61()
Returns property pre61
|
void |
openAllConnections()
Open all the socket connections to every remote server
|
void |
setCacheLocally(boolean pCacheLocally)
Sets property CacheLocally
|
void |
setConnectionTimeout(long pConnectionTimeout)
Set the time in milliseconds to wait for a socket when
attempting to connect to its remote target.
|
void |
setContentItemNameProperty(java.lang.String pContentItemNameProperty)
Sets property ContentItemNameProperty
|
void |
setCreateCacheDirectories(boolean pCreateCacheDirectories)
Sets property CreateCacheDirectories
|
void |
setDocumentRoot(java.io.File pDocumentRoot)
Sets property DocumentRoot
|
void |
setDocumentRootCachePath(java.lang.String pDocumentRootCachePath)
Sets property DocumentRootCachePath
|
void |
setDocumentRootContextPath(java.lang.String pDocumentRootContextPath)
Set the context path to prepend to generated URI's that refer to files
in the document root specified by
documentRoot . |
void |
setEscapeURI(boolean pEscapeURI)
Sets property EscapeURI
|
void |
setFlatten(boolean pFlatten)
Sets property Flatten
|
void |
setMinReconnectInterval(int pMinReconnectInterval)
Sets property MinReconnectInterval, the minimum interval between connect retries in msec
|
void |
setPre61(boolean pPre61)
Sets property pre61
|
void |
setReadTimeout(int pReadTimeout)
Sets property ReadTimeout
|
void |
setRemoteServerCache(atg.distributor.RemoteServerCache pRemoteServerCache)
Sets property RemoteServerCache
|
void |
setServerList(java.lang.String[] pServerList)
Sets property ServerList, the list of
host:port combinations
that this client should connect to. |
void |
setWriteTimeout(int pWriteTimeout)
Sets property WriteTimeout
|
addAdminInfo, block, checkIn, checkOut, createAdminServlet, doStartService, doStopService, finalize, getAverageResourceCreationTime, getBlocking, getCheckoutBlockTime, getCreationTimeLimit, getCurrentStack, getDebugConnections, getLastError, getMax, getMaxConcurrentResourcesPerThread, getMaxConcurrentThreads, getMaxFree, getMaxIdleAge, getMaxPendingCreations, getMaxResourceAge, getMaxResourcesPerThread, getMaxSimultaneousResourcesOut, getMaxThreadsWithResourcesOut, getMin, getNumCheckedOutResources, getNumFreeResources, getNumTotalResources, getResourceClassName, getStartupAttempts, getStartupFailureSleepTime, invalidateAllResources, isEnabled, isWarnOnNestedCheckouts, populateSlot, pruneFreeResources, reclaimResource, resetMaxConcurrentResourcesPerThread, resetMaxConcurrentThreads, resetMaxSimultaneousResourcesOut, setBlocking, setCheckoutBlockTime, setCreationTimeLimit, setDebugConnections, setLastError, setMax, setMaxFree, setMaxIdleAge, setMaxPendingCreations, setMaxResourceAge, setMaxResourcesPerThread, setMaxThreadsWithResourcesOut, setMin, setResourceClassName, setStartupAttempts, setStartupFailureSleepTime, setWarnOnNestedCheckouts, unblock, verifyResourceValidity
addLogListener, getAbsoluteName, getAdminServlet, getAdminServletOutputStreamEncoding, getLoggingForVlogging, getLogListenerCount, getLogListeners, getName, getNameContext, getNucleus, getRoot, getServiceConfiguration, getServiceInfo, isAdminServletUseServletOutputStream, isLoggingDebug, isLoggingError, isLoggingInfo, isLoggingTrace, isLoggingWarning, isRunning, logDebug, logDebug, logDebug, logError, logError, logError, logInfo, logInfo, logInfo, logTrace, logTrace, logTrace, logWarning, logWarning, logWarning, nameContextElementBound, nameContextElementUnbound, removeLogListener, reResolveThis, resolveName, resolveName, resolveName, resolveName, sendLogEvent, setAdminServletOutputStreamEncoding, setAdminServletUseServletOutputStream, setLoggingDebug, setLoggingError, setLoggingInfo, setLoggingTrace, setLoggingWarning, setNucleus, setServiceInfo, startService, stopService
vlogDebug, vlogDebug, vlogDebug, vlogDebug, vlogDebugTrace, vlogError, vlogError, vlogError, vlogError, vlogInfo, vlogInfo, vlogInfo, vlogInfo, vlogTrace, vlogTrace, vlogTrace, vlogTrace, vlogWarning, vlogWarning, vlogWarning, vlogWarning
public SenderResourcePool()
public void setRemoteServerCache(atg.distributor.RemoteServerCache pRemoteServerCache)
public atg.distributor.RemoteServerCache getRemoteServerCache()
public void setMinReconnectInterval(int pMinReconnectInterval)
public int getMinReconnectInterval()
public void setReadTimeout(int pReadTimeout)
public int getReadTimeout()
public void setWriteTimeout(int pWriteTimeout)
public int getWriteTimeout()
public void setServerList(java.lang.String[] pServerList)
host:port
combinations
that this client should connect to.public java.lang.String[] getServerList()
host:port
combinations
that this client should connect to.public void setContentItemNameProperty(java.lang.String pContentItemNameProperty)
public java.lang.String getContentItemNameProperty()
public void setDocumentRoot(java.io.File pDocumentRoot)
public java.io.File getDocumentRoot()
public void setDocumentRootCachePath(java.lang.String pDocumentRootCachePath)
public java.lang.String getDocumentRootCachePath()
public void setDocumentRootContextPath(java.lang.String pDocumentRootContextPath)
documentRoot
.
This will typically be null for applications running on the Dynamo Application Server and in the deployment configuration of applications running on DAF but writing files directly into an external HTTP server's document root, where no special handling is necessary to access files in the document root.
It will typically be "/dyn/dyn" in the development and staging configurations of applications running on DAF, where cached documents are stored in the Dynamo document root and served from the third party application server rather than an external HTTP server. In these environments using /dyn/dyn as the context path is required to access files that live in the Dynamo document root.
public java.lang.String getDocumentRootContextPath()
public void setCreateCacheDirectories(boolean pCreateCacheDirectories)
public boolean isCreateCacheDirectories()
public void setCacheLocally(boolean pCacheLocally)
public boolean isCacheLocally()
documentRoot
is null, then
this always returns falsepublic void setFlatten(boolean pFlatten)
public boolean isFlatten()
public void setConnectionTimeout(long pConnectionTimeout)
long
- the timeout (milliseconds)public long getConnectionTimeout()
public void setPre61(boolean pPre61)
public boolean isPre61()
public void setEscapeURI(boolean pEscapeURI)
public boolean isEscapeURI()
public java.lang.Object createResource() throws ResourcePoolException
createResource
in class ResourcePool
ResourcePoolException
- if there was a problem creating the resourcepublic void destroyResource(java.lang.Object pResource)
destroyResource
in class ResourcePool
pResource
- the Object to destroypublic void initializeAllConnections() throws ResourcePoolException
serverList
property. The doStartService
method is invoked to repopulate the minimum number of resources.ResourcePoolException
public void openAllConnections() throws ResourcePoolException
ResourcePoolException
public void closeAllConnections() throws ResourcePoolException
ResourcePoolException