org.glassfish.grizzly.web
Class WebFilterConfig

java.lang.Object
  extended by org.glassfish.grizzly.web.WebFilterConfig
Direct Known Subclasses:
AsyncWebFilterConfig

public class WebFilterConfig
extends Object


Field Summary
protected  Adapter adapter
          Associated adapter.
protected  String compressableMimeTypes
           
protected  String compression
          Compression value.
protected  int compressionMinSize
           
protected  String defaultResponseType
          The default response-type
protected  boolean disableUploadTimeout
          Flag to disable setting a different time-out on uploads.
protected  boolean displayConfiguration
          If true, display the NIO configuration information.
protected  FileCache fileCache
          The FileCache associated with this Selector
protected  String forcedRequestType
          The forced request-type
protected  Interceptor interceptor
           
protected  boolean isAsyncHttpWriteEnabled
          Is Async HTTP write enabled.
protected  boolean isBufferResponse
          Buffer the response until the buffer is full.
protected  boolean isMonitoringEnabled
          Is monitoring already started.
protected  int keepAliveThreadCount
           
protected  int keepAliveTimeoutInSeconds
           
protected  int maxHttpHeaderSize
          Default HTTP header buffer size.
protected  int maxKeepAliveRequests
           
protected  int maxPostSize
           
protected  MemoryManager memoryManager
           
protected  String noCompressionUserAgents
           
protected  int requestBufferSize
          The input request buffer size.
protected  String restrictedUserAgents
           
protected  String rootFolder
          The root folder where application are deployed
protected  ScheduledExecutorService scheduledThreadPool
           
static String SERVER_NAME
           
protected  String serverName
          HTTP server name
protected  int transactionTimeout
          The timeout used by the thread when processing a request.
protected  int uploadTimeout
          Maximum timeout on uploads.
protected  ExecutorService workerThreadPool
           
 
Constructor Summary
WebFilterConfig()
           
 
Method Summary
 Adapter getAdapter()
           
 ClassLoader getClassLoader()
           
 String getCompressableMimeTypes()
           
 String getCompression()
           
 int getCompressionMinSize()
           
 String getDefaultResponseType()
           
 FileCache getFileCache()
           
 String getForcedRequestType()
           
 Interceptor getInterceptor()
           
 int getKeepAliveTimeoutInSeconds()
          Gets the number of seconds before a keep-alive connection that has been idle times out and is closed.
 int getMaxHttpHeaderSize()
           
 int getMaxKeepAliveRequests()
           
 int getMaxPostSize()
           
 MemoryManager getMemoryManager()
           
 String getNoCompressionUserAgents()
           
 Properties getProperties()
           
 int getRequestBufferSize()
          Return the request input buffer size
 String getRestrictedUserAgents()
           
 String getRootFolder()
           
 ScheduledExecutorService getScheduledThreadPool()
           
 String getServerName()
           
 int getTransactionTimeout()
          Set the maximum time, in milliseconds, a WorkerThread executing an instance of this class can execute.
 int getUploadTimeout()
          Get the upload timeout.
 String getWebAppRootPath()
          Return the folder's root where application are deployed.
 ExecutorService getWorkerThreadPool()
           
 void initializeCompression(ProcessorTask processorTask)
           
 ProcessorTask initializeProcessorTask(ProcessorTask task)
           
 boolean isAsyncHttpWriteEnabled()
          Is async HTTP write enabled
 boolean isBufferResponse()
          Return true if the reponse is buffered.
 boolean isDisableUploadTimeout()
          Get the flag that controls upload time-outs.
 boolean isDisplayConfiguration()
           
 boolean isEnableNioLogging()
           
 boolean isMonitoringEnabled()
          Returns true if monitoring has been enabled, false otherwise.
 boolean isUseChunking()
          Is chunking encoding used.
 void setAdapter(Adapter adapter)
           
 void setAsyncHttpWriteEnabled(boolean isAsyncHttpWriteEnabled)
          Set if async HTTP write enabled
 void setBufferResponse(boolean isBufferResponse)
          trueif the reponse willk be buffered.
 void setClassLoader(ClassLoader classLoader)
          Set the ClassLoader used to load configurable classes (ExecutorService, StreamAlgorithm).
 void setCompressableMimeTypes(String compressableMimeTypes)
           
 void setCompression(String compression)
           
 void setCompressionMinSize(int compressionMinSize)
           
 void setDefaultResponseType(String defaultResponseType)
           
 void setDisableUploadTimeout(boolean isDisabled)
          Set the flag to control upload time-outs.
 void setDisplayConfiguration(boolean displayConfiguration)
           
 void setEnableNioLogging(boolean enableNioLogging)
           
 void setFileCache(FileCache fileCache)
           
 void setForcedRequestType(String forcedRequestType)
           
 void setInterceptor(Interceptor interceptor)
           
 void setKeepAliveTimeoutInSeconds(int timeout)
          Sets the number of seconds before a keep-alive connection that has been idle times out and is closed.
 void setMaxHttpHeaderSize(int maxHttpHeaderSize)
           
 void setMaxKeepAliveRequests(int mkar)
          Set the maximum number of Keep-Alive requests that we will honor.
 void setMaxPostSize(int maxPostSize)
           
 void setMemoryManager(MemoryManager memoryManager)
           
 void setMonitoringEnabled(boolean isMonitoringEnabled)
           
 void setNoCompressionUserAgents(String noCompressionUserAgents)
           
 void setRequestBufferSize(int requestBufferSize)
          Set the request input buffer size
 void setRestrictedUserAgents(String restrictedUserAgents)
           
 void setRootFolder(String rootFolder)
           
 void setScheduledThreadPool(ScheduledExecutorService scheduledThreadPool)
           
 void setServerName(String serverName)
           
 void setTransactionTimeout(int transactionTimeout)
          Set the maximum time, in milliseconds, a WrokerThread processing an instance of this class.
 void setUploadTimeout(int uploadTimeout)
          Set the upload timeout.
 void setUseChunking(boolean useChunking)
          Enable chunking the http response.
 void setWebAppRootPath(String rf)
          Set the document root folder
 void setWorkerThreadPool(ExecutorService workerThreadPool)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SERVER_NAME

public static final String SERVER_NAME

fileCache

protected FileCache fileCache
The FileCache associated with this Selector


adapter

protected Adapter adapter
Associated adapter.


interceptor

protected Interceptor interceptor

memoryManager

protected MemoryManager memoryManager

workerThreadPool

protected ExecutorService workerThreadPool

scheduledThreadPool

protected ScheduledExecutorService scheduledThreadPool

maxKeepAliveRequests

protected int maxKeepAliveRequests

keepAliveThreadCount

protected int keepAliveThreadCount

compression

protected String compression
Compression value.


noCompressionUserAgents

protected String noCompressionUserAgents

restrictedUserAgents

protected String restrictedUserAgents

compressableMimeTypes

protected String compressableMimeTypes

compressionMinSize

protected int compressionMinSize

isMonitoringEnabled

protected boolean isMonitoringEnabled
Is monitoring already started.


isBufferResponse

protected boolean isBufferResponse
Buffer the response until the buffer is full.


maxHttpHeaderSize

protected int maxHttpHeaderSize
Default HTTP header buffer size.


isAsyncHttpWriteEnabled

protected boolean isAsyncHttpWriteEnabled
Is Async HTTP write enabled.


maxPostSize

protected int maxPostSize

transactionTimeout

protected int transactionTimeout
The timeout used by the thread when processing a request.


displayConfiguration

protected boolean displayConfiguration
If true, display the NIO configuration information.


requestBufferSize

protected int requestBufferSize
The input request buffer size.


keepAliveTimeoutInSeconds

protected int keepAliveTimeoutInSeconds

defaultResponseType

protected String defaultResponseType
The default response-type


forcedRequestType

protected String forcedRequestType
The forced request-type


rootFolder

protected String rootFolder
The root folder where application are deployed


serverName

protected String serverName
HTTP server name


disableUploadTimeout

protected boolean disableUploadTimeout
Flag to disable setting a different time-out on uploads.


uploadTimeout

protected int uploadTimeout
Maximum timeout on uploads. 5 minutes as in Apache HTTPD server.

Constructor Detail

WebFilterConfig

public WebFilterConfig()
Method Detail

initializeProcessorTask

public ProcessorTask initializeProcessorTask(ProcessorTask task)

initializeCompression

public void initializeCompression(ProcessorTask processorTask)

getAdapter

public Adapter getAdapter()

setAdapter

public void setAdapter(Adapter adapter)

getFileCache

public FileCache getFileCache()

setFileCache

public void setFileCache(FileCache fileCache)

getInterceptor

public Interceptor getInterceptor()

setInterceptor

public void setInterceptor(Interceptor interceptor)

getMemoryManager

public MemoryManager getMemoryManager()

setMemoryManager

public void setMemoryManager(MemoryManager memoryManager)

getScheduledThreadPool

public ScheduledExecutorService getScheduledThreadPool()

setScheduledThreadPool

public void setScheduledThreadPool(ScheduledExecutorService scheduledThreadPool)

getWorkerThreadPool

public ExecutorService getWorkerThreadPool()

setWorkerThreadPool

public void setWorkerThreadPool(ExecutorService workerThreadPool)

getServerName

public String getServerName()

setServerName

public void setServerName(String serverName)

getRootFolder

public String getRootFolder()

setRootFolder

public void setRootFolder(String rootFolder)

getMaxKeepAliveRequests

public int getMaxKeepAliveRequests()

setMaxKeepAliveRequests

public void setMaxKeepAliveRequests(int mkar)
Set the maximum number of Keep-Alive requests that we will honor.


setKeepAliveTimeoutInSeconds

public void setKeepAliveTimeoutInSeconds(int timeout)
Sets the number of seconds before a keep-alive connection that has been idle times out and is closed.

Parameters:
timeout - Keep-alive timeout in number of seconds

getKeepAliveTimeoutInSeconds

public int getKeepAliveTimeoutInSeconds()
Gets the number of seconds before a keep-alive connection that has been idle times out and is closed.

Returns:
Keep-alive timeout in number of seconds

isMonitoringEnabled

public boolean isMonitoringEnabled()
Returns true if monitoring has been enabled, false otherwise.


setMonitoringEnabled

public void setMonitoringEnabled(boolean isMonitoringEnabled)

getProperties

public Properties getProperties()

getMaxHttpHeaderSize

public int getMaxHttpHeaderSize()

setMaxHttpHeaderSize

public void setMaxHttpHeaderSize(int maxHttpHeaderSize)

isAsyncHttpWriteEnabled

public boolean isAsyncHttpWriteEnabled()
Is async HTTP write enabled

Returns:
true, if async HTTP write enabled, or false otherwise.

setAsyncHttpWriteEnabled

public void setAsyncHttpWriteEnabled(boolean isAsyncHttpWriteEnabled)
Set if async HTTP write enabled

Parameters:
isAsyncHttpWriteEnabled - true, if async HTTP write enabled, or false otherwise.

setRequestBufferSize

public void setRequestBufferSize(int requestBufferSize)
Set the request input buffer size


getRequestBufferSize

public int getRequestBufferSize()
Return the request input buffer size


setWebAppRootPath

public void setWebAppRootPath(String rf)
Set the document root folder


getWebAppRootPath

public String getWebAppRootPath()
Return the folder's root where application are deployed.


isBufferResponse

public boolean isBufferResponse()
Return true if the reponse is buffered.


setBufferResponse

public void setBufferResponse(boolean isBufferResponse)
trueif the reponse willk be buffered.


getCompression

public String getCompression()

setCompression

public void setCompression(String compression)

getNoCompressionUserAgents

public String getNoCompressionUserAgents()

setNoCompressionUserAgents

public void setNoCompressionUserAgents(String noCompressionUserAgents)

getRestrictedUserAgents

public String getRestrictedUserAgents()

setRestrictedUserAgents

public void setRestrictedUserAgents(String restrictedUserAgents)

getCompressableMimeTypes

public String getCompressableMimeTypes()

setCompressableMimeTypes

public void setCompressableMimeTypes(String compressableMimeTypes)

getCompressionMinSize

public int getCompressionMinSize()

setCompressionMinSize

public void setCompressionMinSize(int compressionMinSize)

isDisplayConfiguration

public boolean isDisplayConfiguration()

setDisplayConfiguration

public void setDisplayConfiguration(boolean displayConfiguration)

getDefaultResponseType

public String getDefaultResponseType()

setDefaultResponseType

public void setDefaultResponseType(String defaultResponseType)

getForcedRequestType

public String getForcedRequestType()

setForcedRequestType

public void setForcedRequestType(String forcedRequestType)

getClassLoader

public ClassLoader getClassLoader()

setClassLoader

public void setClassLoader(ClassLoader classLoader)
Set the ClassLoader used to load configurable classes (ExecutorService, StreamAlgorithm).


getMaxPostSize

public int getMaxPostSize()

setMaxPostSize

public void setMaxPostSize(int maxPostSize)

setDisableUploadTimeout

public void setDisableUploadTimeout(boolean isDisabled)
Set the flag to control upload time-outs.


isDisableUploadTimeout

public boolean isDisableUploadTimeout()
Get the flag that controls upload time-outs.


setUploadTimeout

public void setUploadTimeout(int uploadTimeout)
Set the upload timeout.


getUploadTimeout

public int getUploadTimeout()
Get the upload timeout.


getTransactionTimeout

public int getTransactionTimeout()
Set the maximum time, in milliseconds, a WorkerThread executing an instance of this class can execute.

Returns:
the maximum time, in milliseconds

setTransactionTimeout

public void setTransactionTimeout(int transactionTimeout)
Set the maximum time, in milliseconds, a WrokerThread processing an instance of this class.

Parameters:
transactionTimeout - the maximum time, in milliseconds.

isUseChunking

public boolean isUseChunking()
Is chunking encoding used. Default is true;

Returns:
Is chunking encoding used.

setUseChunking

public void setUseChunking(boolean useChunking)
Enable chunking the http response. Default is true.

Parameters:
useChunking -

isEnableNioLogging

public boolean isEnableNioLogging()

setEnableNioLogging

public void setEnableNioLogging(boolean enableNioLogging)


Copyright © 2009 SUN Microsystems. All Rights Reserved.