Java Doc for Port.java in » EJB-Server-resin-3.1.5 » resin » com » caucho » server » port » Java Source Code / Java DocumentationJava Source Code and Java Documentation
Java Source Code / Java Documentation
1.
6.0 JDK Core
2.
6.0 JDK Modules
3.
6.0 JDK Modules com.sun
4.
6.0 JDK Modules com.sun.java
5.
6.0 JDK Modules sun
6.
6.0 JDK Platform
7.
Ajax
8.
Apache Harmony Java SE
9.
Aspect oriented
10.
Authentication Authorization
11.
Blogger System
12.
Build
13.
Byte Code
14.
Cache
15.
Chart
16.
Chat
17.
Code Analyzer
18.
Collaboration
19.
Content Management System
20.
Database Client
21.
Database DBMS
22.
Database JDBC Connection Pool
23.
Database ORM
24.
Development
25.
EJB Server geronimo
26.
EJB Server GlassFish
27.
EJB Server JBoss 4.2.1
28.
EJB Server resin 3.1.5
29.
ERP CRM Financial
30.
ESB
31.
Forum
32.
GIS
33.
Graphic Library
34.
Groupware
35.
HTML Parser
36.
IDE
37.
IDE Eclipse
38.
IDE Netbeans
39.
Installer
40.
Internationalization Localization
41.
Inversion of Control
42.
Issue Tracking
43.
J2EE
44.
JBoss
45.
JMS
46.
JMX
47.
Library
48.
Mail Clients
49.
Net
50.
Parser
51.
PDF
52.
Portal
53.
Profiler
54.
Project Management
55.
Report
56.
RSS RDF
57.
Rule Engine
58.
Science
59.
Scripting
60.
Search Engine
61.
Security
62.
Sevlet Container
63.
Source Control
64.
Swing Library
65.
Template Engine
66.
Test Coverage
67.
Testing
68.
UML
69.
Web Crawler
70.
Web Framework
71.
Web Mail
72.
Web Server
73.
Web Services
74.
Web Services apache cxf 2.0.1
75.
Web Services AXIS2
76.
Wiki Engine
77.
Workflow Engines
78.
XML
79.
XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation
»
EJB Server resin 3.1.5
»
resin
»
com.caucho.server.port
Source Cross Reference
Class Diagram
Java Document (Java Doc)
java.lang
.Object
com.caucho.server.port
.Port
All known Subclasses:
com.caucho.server.resin
.SrunPort
,
com.caucho.server.cluster
.ClusterPort
,
Port
public
class Port implements
EnvironmentListener
,
Runnable
(Code)
Represents a protocol connection.
Inner Class :
public
class SuspendReaper implements AlarmListener
Constructor Summary
public
Port
()
public
Port
(
ClusterServer
server)
Method Summary
public
boolean
accept
(
TcpConnection
conn, boolean isFirst)
Accepts a new connection.
public
boolean
allowKeepalive
(long acceptStartTime)
public
void
bind
()
Starts the port listening.
public
void
bind
(QServerSocket ss)
Starts the port listening.
public
QServerSocket
bindForWatchdog
()
binds for the watchdog.
public
void
close
()
Shuts the Port down.
void
closeSocket
(QSocket socket)
Notification when a socket closes.
public
Object
createInit
()
public
JsseSSLFactory
createJsse
()
public
SSLFactory
createOpenssl
()
boolean
detach
(
TcpConnection
conn)
Remove from suspend list.
void
disable
()
Stops the port from listening for new connections.
void
enable
()
Starts the port listening for new connections.
public
void
environmentConfig
(
EnvironmentClassLoader
loader)
public
void
environmentStart
(
EnvironmentClassLoader
loader)
Handles the case where the environment is starting (after init).
public
void
environmentStop
(
EnvironmentClassLoader
loader)
void
free
(
TcpConnection
conn)
Frees the connection.
public
int
getAcceptListenBacklog
()
public
int
getAcceptThreadMax
()
The maximum spare threads.
public
int
getAcceptThreadMin
()
The minimum spare threads.
public
int
getActiveConnectionCount
()
Returns the active connections.
public
int
getActiveThreadCount
()
Returns the active thread count.
public
String
getAddress
()
public
PortMXBean
getAdmin
()
public
int
getCometIdleCount
()
Returns the number of comet connections.
public
int
getConnectionCount
()
public
int
getConnectionMax
()
Gets the connection max.
public
int
getFreeKeepalive
()
Returns the accept pool.
public
int
getIdleThreadCount
()
Returns the count of idle threads.
public
int
getKeepaliveConnectionCount
()
Returns the keepalive connections.
public
long
getKeepaliveConnectionTimeMax
()
Gets the keepalive max.
public
int
getKeepaliveCount
()
public
int
getKeepaliveMax
()
Gets the keepalive max.
public
long
getKeepaliveSelectThreadTimeout
()
public
int
getKeepaliveThreadCount
()
public
long
getKeepaliveTimeout
()
public
Lifecycle
getLifecycleState
()
public
long
getLifetimeClientDisconnectCount
()
public
long
getLifetimeKeepaliveCount
()
public
long
getLifetimeReadBytes
()
public
long
getLifetimeRequestCount
()
public
long
getLifetimeRequestTime
()
public
long
getLifetimeWriteBytes
()
public
int
getPort
()
Gets the port.
public
Protocol
getProtocol
()
Set protocol.
public
String
getProtocolName
()
Gets the protocol name.
public
SSLFactory
getSSL
()
Gets the SSL factory.
public
int
getSelectConnectionCount
()
Returns the number of connections in the select.
public
AbstractSelectManager
getSelectManager
()
returns the select manager.
public
ProtocolDispatchServer
getServer
()
Gets the server.
public
String
getServerId
()
Gets the server id.
public
long
getSocketTimeout
()
Gets the read timeout for the accepted sockets.
public
long
getSuspendTimeMax
()
Gets the suspend max.
public
boolean
getTcpNoDelay
()
public
int
getThreadCount
()
Returns the thread count.
public
long
getThrottleConcurrentMax
()
Configures the throttle.
public
String
getVirtualHost
()
Gets the virtual host for IP-based virtual host.
public
void
init
()
Initializes the port.
public
boolean
isActive
()
Returns true if the port is active.
public
boolean
isClosed
()
Returns true if the port is closed.
public
boolean
isIgnoreClientDisconnect
()
Returns true for ignore-client-disconnect.
public
boolean
isSSL
()
Returns true for ssl.
public
boolean
isSecure
()
boolean
keepaliveBegin
(
TcpConnection
conn, long acceptStartTime)
Marks a keepalive as starting running.
void
keepaliveEnd
(
TcpConnection
conn)
Marks the keepalive as ending.
void
keepaliveThreadBegin
()
Starts a keepalive thread.
void
keepaliveThreadEnd
()
Ends a keepalive thread.
void
kill
(
TcpConnection
conn)
Frees the connection.
public
boolean
matchesServerId
(
String
serverId)
Returns true if the port matches the server id.
public
void
postBind
()
boolean
resume
(
TcpConnection
conn)
public
void
run
()
The port thread is responsible for creating new connections.
public
void
setAcceptListenBacklog
(int listen)
public
void
setAcceptThreadMax
(int maxSpare)
Sets the minimum spare listen.
public
void
setAcceptThreadMin
(int minSpare)
Sets the minimum spare listen.
public
void
setAddress
(
String
address)
public
void
setClass
(
Class
cl)
Sets protocol class.
public
void
setConnectionMax
(int max)
Sets the connection max.
public
void
setHost
(
String
address)
public
void
setId
(
String
id)
Sets the id.
public
void
setJsseSsl
(
JsseSSLFactory
factory)
public
void
setKeepaliveConnectionTimeMax
(
Period
period)
Sets the keepalive max.
public
void
setKeepaliveMax
(int max)
Sets the keepalive max.
public
void
setKeepaliveTimeout
(
Period
period)
public
void
setMaxSpareListen
(int maxSpare)
Sets the maximum spare listen.
public
void
setMinSpareListen
(int minSpare)
Sets the minimum spare listen.
public
void
setParent
(
ProtocolDispatchServer
parent)
Sets the containing server.
public
void
setPort
(int port)
Sets the port.
public
void
setProtocol
(
Protocol
protocol)
Set protocol.
public
void
setReadTimeout
(
Period
period)
Sets the read timeout for the accepted sockets.
public
void
setSSL
(
SSLFactory
factory)
public
void
setSecure
(boolean isSecure)
public
void
setServer
(
ProtocolDispatchServer
protocolServer)
Sets the server.
public
void
setServerId
(
String
id)
Sets the server id.
public
void
setServerSocket
(QServerSocket socket)
Sets the server socket.
public
void
setSocketTimeout
(
Period
period)
Sets the read/write timeout for the accepted sockets.
public
void
setSuspendTimeMax
(
Period
period)
public
void
setTcpNoDelay
(boolean tcpNoDelay)
public
void
setThrottleConcurrentMax
(int max)
Configures the throttle.
public
void
setType
(
Class
cl)
Sets protocol class.
public
void
setVirtualHost
(
String
host)
Sets the virtual host for IP-based virtual host.
public
void
setWriteTimeout
(
Period
period)
Sets the write timeout for the accepted sockets.
public
void
start
()
Starts the port listening.
void
startConnection
(
TcpConnection
conn)
boolean
suspend
(
TcpConnection
conn)
void
threadBegin
(
TcpConnection
conn)
Marks a new thread as running.
void
threadEnd
(
TcpConnection
conn)
Marks a new thread as stopped.
public
String
toString
()
Constructor Detail
Port
public
Port()
(Code)
Port
public
Port(
ClusterServer
server)
(Code)
Method Detail
accept
public
boolean accept(
TcpConnection
conn, boolean isFirst)
(Code)
Accepts a new connection.
allowKeepalive
public
boolean allowKeepalive(long acceptStartTime)
(Code)
Returns true if the keepalive is allowed
bind
public
void bind() throws
Exception
(Code)
Starts the port listening.
bind
public
void bind(QServerSocket ss) throws
Exception
(Code)
Starts the port listening.
bindForWatchdog
public
QServerSocket bindForWatchdog() throws
java.io.IOException
(Code)
binds for the watchdog.
close
public
void close()
(Code)
Shuts the Port down. The server gives connections 30 seconds to complete.
closeSocket
void closeSocket(QSocket socket)
(Code)
Notification when a socket closes.
createInit
public
Object
createInit() throws ConfigException
(Code)
createJsse
public
JsseSSLFactory
createJsse()
(Code)
Sets the SSL factory
createOpenssl
public
SSLFactory
createOpenssl() throws ConfigException
(Code)
Sets the SSL factory
detach
boolean detach(
TcpConnection
conn)
(Code)
Remove from suspend list.
disable
void disable()
(Code)
Stops the port from listening for new connections.
enable
void enable()
(Code)
Starts the port listening for new connections.
environmentConfig
public
void environmentConfig(
EnvironmentClassLoader
loader)
(Code)
Handles the environment config phase
environmentStart
public
void environmentStart(
EnvironmentClassLoader
loader)
(Code)
Handles the case where the environment is starting (after init).
environmentStop
public
void environmentStop(
EnvironmentClassLoader
loader)
(Code)
Handles the case where the environment is stopping
free
void free(
TcpConnection
conn)
(Code)
Frees the connection. Called only from TcpConnection
getAcceptListenBacklog
public
int getAcceptListenBacklog()
(Code)
The operating system listen backlog
getAcceptThreadMax
public
int getAcceptThreadMax()
(Code)
The maximum spare threads.
getAcceptThreadMin
public
int getAcceptThreadMin()
(Code)
The minimum spare threads.
getActiveConnectionCount
public
int getActiveConnectionCount()
(Code)
Returns the active connections.
getActiveThreadCount
public
int getActiveThreadCount()
(Code)
Returns the active thread count.
getAddress
public
String
getAddress()
(Code)
Gets the IP address
getAdmin
public
PortMXBean
getAdmin()
(Code)
getCometIdleCount
public
int getCometIdleCount()
(Code)
Returns the number of comet connections.
getConnectionCount
public
int getConnectionCount()
(Code)
Returns the number of connections
getConnectionMax
public
int getConnectionMax()
(Code)
Gets the connection max.
getFreeKeepalive
public
int getFreeKeepalive()
(Code)
Returns the accept pool.
getIdleThreadCount
public
int getIdleThreadCount()
(Code)
Returns the count of idle threads.
getKeepaliveConnectionCount
public
int getKeepaliveConnectionCount()
(Code)
Returns the keepalive connections.
getKeepaliveConnectionTimeMax
public
long getKeepaliveConnectionTimeMax()
(Code)
Gets the keepalive max.
getKeepaliveCount
public
int getKeepaliveCount()
(Code)
Returns the number of keepalive connections
getKeepaliveMax
public
int getKeepaliveMax()
(Code)
Gets the keepalive max.
getKeepaliveSelectThreadTimeout
public
long getKeepaliveSelectThreadTimeout()
(Code)
getKeepaliveThreadCount
public
int getKeepaliveThreadCount()
(Code)
Returns the number of keepalive connections
getKeepaliveTimeout
public
long getKeepaliveTimeout()
(Code)
getLifecycleState
public
Lifecycle
getLifecycleState()
(Code)
getLifetimeClientDisconnectCount
public
long getLifetimeClientDisconnectCount()
(Code)
getLifetimeKeepaliveCount
public
long getLifetimeKeepaliveCount()
(Code)
getLifetimeReadBytes
public
long getLifetimeReadBytes()
(Code)
getLifetimeRequestCount
public
long getLifetimeRequestCount()
(Code)
getLifetimeRequestTime
public
long getLifetimeRequestTime()
(Code)
getLifetimeWriteBytes
public
long getLifetimeWriteBytes()
(Code)
getPort
public
int getPort()
(Code)
Gets the port.
getProtocol
public
Protocol
getProtocol()
(Code)
Set protocol.
getProtocolName
public
String
getProtocolName()
(Code)
Gets the protocol name.
getSSL
public
SSLFactory
getSSL()
(Code)
Gets the SSL factory.
getSelectConnectionCount
public
int getSelectConnectionCount()
(Code)
Returns the number of connections in the select.
getSelectManager
public
AbstractSelectManager
getSelectManager()
(Code)
returns the select manager.
getServer
public
ProtocolDispatchServer
getServer()
(Code)
Gets the server.
getServerId
public
String
getServerId()
(Code)
Gets the server id.
getSocketTimeout
public
long getSocketTimeout()
(Code)
Gets the read timeout for the accepted sockets.
getSuspendTimeMax
public
long getSuspendTimeMax()
(Code)
Gets the suspend max.
getTcpNoDelay
public
boolean getTcpNoDelay()
(Code)
Gets the tcp-no-delay property
getThreadCount
public
int getThreadCount()
(Code)
Returns the thread count.
getThrottleConcurrentMax
public
long getThrottleConcurrentMax()
(Code)
Configures the throttle.
getVirtualHost
public
String
getVirtualHost()
(Code)
Gets the virtual host for IP-based virtual host.
init
public
void init() throws ConfigException
(Code)
Initializes the port.
isActive
public
boolean isActive()
(Code)
Returns true if the port is active.
isClosed
public
boolean isClosed()
(Code)
Returns true if the port is closed.
isIgnoreClientDisconnect
public
boolean isIgnoreClientDisconnect()
(Code)
Returns true for ignore-client-disconnect.
isSSL
public
boolean isSSL()
(Code)
Returns true for ssl.
isSecure
public
boolean isSecure()
(Code)
Return true for secure
keepaliveBegin
boolean keepaliveBegin(
TcpConnection
conn, long acceptStartTime)
(Code)
Marks a keepalive as starting running. Called only from TcpConnection.
keepaliveEnd
void keepaliveEnd(
TcpConnection
conn)
(Code)
Marks the keepalive as ending. Called only from TcpConnection.
keepaliveThreadBegin
void keepaliveThreadBegin()
(Code)
Starts a keepalive thread.
keepaliveThreadEnd
void keepaliveThreadEnd()
(Code)
Ends a keepalive thread.
kill
void kill(
TcpConnection
conn)
(Code)
Frees the connection. Called only from TcpConnection
matchesServerId
public
boolean matchesServerId(
String
serverId)
(Code)
Returns true if the port matches the server id.
postBind
public
void postBind()
(Code)
resume
boolean resume(
TcpConnection
conn)
(Code)
Suspends the controller (for comet-style ajax)
run
public
void run()
(Code)
The port thread is responsible for creating new connections.
setAcceptListenBacklog
public
void setAcceptListenBacklog(int listen) throws ConfigException
(Code)
Sets the operating system listen backlog
setAcceptThreadMax
public
void setAcceptThreadMax(int maxSpare) throws ConfigException
(Code)
Sets the minimum spare listen.
setAcceptThreadMin
public
void setAcceptThreadMin(int minSpare) throws ConfigException
(Code)
Sets the minimum spare listen.
setAddress
public
void setAddress(
String
address) throws
UnknownHostException
(Code)
Sets the address
setClass
public
void setClass(
Class
cl) throws
InstantiationException
,
IllegalAccessException
(Code)
Sets protocol class.
setConnectionMax
public
void setConnectionMax(int max)
(Code)
Sets the connection max.
setHost
public
void setHost(
String
address) throws
UnknownHostException
(Code)
setId
public
void setId(
String
id)
(Code)
Sets the id.
setJsseSsl
public
void setJsseSsl(
JsseSSLFactory
factory)
(Code)
Sets the SSL factory
setKeepaliveConnectionTimeMax
public
void setKeepaliveConnectionTimeMax(
Period
period)
(Code)
Sets the keepalive max.
setKeepaliveMax
public
void setKeepaliveMax(int max)
(Code)
Sets the keepalive max.
setKeepaliveTimeout
public
void setKeepaliveTimeout(
Period
period)
(Code)
setMaxSpareListen
public
void setMaxSpareListen(int maxSpare) throws ConfigException
(Code)
Sets the maximum spare listen.
setMinSpareListen
public
void setMinSpareListen(int minSpare) throws ConfigException
(Code)
Sets the minimum spare listen.
setParent
public
void setParent(
ProtocolDispatchServer
parent)
(Code)
Sets the containing server.
setPort
public
void setPort(int port)
(Code)
Sets the port.
setProtocol
public
void setProtocol(
Protocol
protocol) throws ConfigException
(Code)
Set protocol.
setReadTimeout
public
void setReadTimeout(
Period
period)
(Code)
Sets the read timeout for the accepted sockets.
setSSL
public
void setSSL(
SSLFactory
factory)
(Code)
Sets the SSL factory
setSecure
public
void setSecure(boolean isSecure)
(Code)
Sets true for secure
setServer
public
void setServer(
ProtocolDispatchServer
protocolServer)
(Code)
Sets the server.
setServerId
public
void setServerId(
String
id)
(Code)
Sets the server id.
setServerSocket
public
void setServerSocket(QServerSocket socket)
(Code)
Sets the server socket.
setSocketTimeout
public
void setSocketTimeout(
Period
period)
(Code)
Sets the read/write timeout for the accepted sockets.
setSuspendTimeMax
public
void setSuspendTimeMax(
Period
period)
(Code)
setTcpNoDelay
public
void setTcpNoDelay(boolean tcpNoDelay)
(Code)
Sets the tcp-no-delay property
setThrottleConcurrentMax
public
void setThrottleConcurrentMax(int max)
(Code)
Configures the throttle.
setType
public
void setType(
Class
cl) throws
InstantiationException
,
IllegalAccessException
(Code)
Sets protocol class.
setVirtualHost
public
void setVirtualHost(
String
host)
(Code)
Sets the virtual host for IP-based virtual host.
setWriteTimeout
public
void setWriteTimeout(
Period
period)
(Code)
Sets the write timeout for the accepted sockets.
start
public
void start() throws
Exception
(Code)
Starts the port listening.
startConnection
void startConnection(
TcpConnection
conn)
(Code)
Registers the new connection as started
suspend
boolean suspend(
TcpConnection
conn)
(Code)
Suspends the controller (for comet-style ajax)
threadBegin
void threadBegin(
TcpConnection
conn)
(Code)
Marks a new thread as running.
threadEnd
void threadEnd(
TcpConnection
conn)
(Code)
Marks a new thread as stopped.
toString
public
String
toString()
(Code)
Methods inherited from
java.lang.Object
native
protected
Object
clone() throws
CloneNotSupportedException
(Code)
(Java Doc)
public
boolean equals(
Object
obj)
(Code)
(Java Doc)
protected
void finalize() throws
Throwable
(Code)
(Java Doc)
final native
public
Class
> getClass()
(Code)
(Java Doc)
native
public
int hashCode()
(Code)
(Java Doc)
final native
public
void notify()
(Code)
(Java Doc)
final native
public
void notifyAll()
(Code)
(Java Doc)
public
String
toString()
(Code)
(Java Doc)
final native
public
void wait(long timeout) throws
InterruptedException
(Code)
(Java Doc)
final
public
void wait(long timeout, int nanos) throws
InterruptedException
(Code)
(Java Doc)
final
public
void wait() throws
InterruptedException
(Code)
(Java Doc)
www.java2java.com
|
Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.