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  booleanaccept(TcpConnection conn, boolean isFirst)
     Accepts a new connection.
public  booleanallowKeepalive(long acceptStartTime)
    
public  voidbind()
     Starts the port listening.
public  voidbind(QServerSocket ss)
     Starts the port listening.
public  QServerSocketbindForWatchdog()
     binds for the watchdog.
public  voidclose()
     Shuts the Port down.
 voidcloseSocket(QSocket socket)
     Notification when a socket closes.
public  ObjectcreateInit()
    
public  JsseSSLFactorycreateJsse()
    
public  SSLFactorycreateOpenssl()
    
 booleandetach(TcpConnection conn)
     Remove from suspend list.
 voiddisable()
     Stops the port from listening for new connections.
 voidenable()
     Starts the port listening for new connections.
public  voidenvironmentConfig(EnvironmentClassLoader loader)
    
public  voidenvironmentStart(EnvironmentClassLoader loader)
     Handles the case where the environment is starting (after init).
public  voidenvironmentStop(EnvironmentClassLoader loader)
    
 voidfree(TcpConnection conn)
     Frees the connection.
public  intgetAcceptListenBacklog()
    
public  intgetAcceptThreadMax()
     The maximum spare threads.
public  intgetAcceptThreadMin()
     The minimum spare threads.
public  intgetActiveConnectionCount()
     Returns the active connections.
public  intgetActiveThreadCount()
     Returns the active thread count.
public  StringgetAddress()
    
public  PortMXBeangetAdmin()
    
public  intgetCometIdleCount()
     Returns the number of comet connections.
public  intgetConnectionCount()
    
public  intgetConnectionMax()
     Gets the connection max.
public  intgetFreeKeepalive()
     Returns the accept pool.
public  intgetIdleThreadCount()
     Returns the count of idle threads.
public  intgetKeepaliveConnectionCount()
     Returns the keepalive connections.
public  longgetKeepaliveConnectionTimeMax()
     Gets the keepalive max.
public  intgetKeepaliveCount()
    
public  intgetKeepaliveMax()
     Gets the keepalive max.
public  longgetKeepaliveSelectThreadTimeout()
    
public  intgetKeepaliveThreadCount()
    
public  longgetKeepaliveTimeout()
    
public  LifecyclegetLifecycleState()
    
public  longgetLifetimeClientDisconnectCount()
    
public  longgetLifetimeKeepaliveCount()
    
public  longgetLifetimeReadBytes()
    
public  longgetLifetimeRequestCount()
    
public  longgetLifetimeRequestTime()
    
public  longgetLifetimeWriteBytes()
    
public  intgetPort()
     Gets the port.
public  ProtocolgetProtocol()
     Set protocol.
public  StringgetProtocolName()
     Gets the protocol name.
public  SSLFactorygetSSL()
     Gets the SSL factory.
public  intgetSelectConnectionCount()
     Returns the number of connections in the select.
public  AbstractSelectManagergetSelectManager()
     returns the select manager.
public  ProtocolDispatchServergetServer()
     Gets the server.
public  StringgetServerId()
     Gets the server id.
public  longgetSocketTimeout()
     Gets the read timeout for the accepted sockets.
public  longgetSuspendTimeMax()
     Gets the suspend max.
public  booleangetTcpNoDelay()
    
public  intgetThreadCount()
     Returns the thread count.
public  longgetThrottleConcurrentMax()
     Configures the throttle.
public  StringgetVirtualHost()
     Gets the virtual host for IP-based virtual host.
public  voidinit()
     Initializes the port.
public  booleanisActive()
     Returns true if the port is active.
public  booleanisClosed()
     Returns true if the port is closed.
public  booleanisIgnoreClientDisconnect()
     Returns true for ignore-client-disconnect.
public  booleanisSSL()
     Returns true for ssl.
public  booleanisSecure()
    
 booleankeepaliveBegin(TcpConnection conn, long acceptStartTime)
     Marks a keepalive as starting running.
 voidkeepaliveEnd(TcpConnection conn)
     Marks the keepalive as ending.
 voidkeepaliveThreadBegin()
     Starts a keepalive thread.
 voidkeepaliveThreadEnd()
     Ends a keepalive thread.
 voidkill(TcpConnection conn)
     Frees the connection.
public  booleanmatchesServerId(String serverId)
     Returns true if the port matches the server id.
public  voidpostBind()
    
 booleanresume(TcpConnection conn)
    
public  voidrun()
     The port thread is responsible for creating new connections.
public  voidsetAcceptListenBacklog(int listen)
    
public  voidsetAcceptThreadMax(int maxSpare)
     Sets the minimum spare listen.
public  voidsetAcceptThreadMin(int minSpare)
     Sets the minimum spare listen.
public  voidsetAddress(String address)
    
public  voidsetClass(Class cl)
     Sets protocol class.
public  voidsetConnectionMax(int max)
     Sets the connection max.
public  voidsetHost(String address)
    
public  voidsetId(String id)
     Sets the id.
public  voidsetJsseSsl(JsseSSLFactory factory)
    
public  voidsetKeepaliveConnectionTimeMax(Period period)
     Sets the keepalive max.
public  voidsetKeepaliveMax(int max)
     Sets the keepalive max.
public  voidsetKeepaliveTimeout(Period period)
    
public  voidsetMaxSpareListen(int maxSpare)
     Sets the maximum spare listen.
public  voidsetMinSpareListen(int minSpare)
     Sets the minimum spare listen.
public  voidsetParent(ProtocolDispatchServer parent)
     Sets the containing server.
public  voidsetPort(int port)
     Sets the port.
public  voidsetProtocol(Protocol protocol)
     Set protocol.
public  voidsetReadTimeout(Period period)
     Sets the read timeout for the accepted sockets.
public  voidsetSSL(SSLFactory factory)
    
public  voidsetSecure(boolean isSecure)
    
public  voidsetServer(ProtocolDispatchServer protocolServer)
     Sets the server.
public  voidsetServerId(String id)
     Sets the server id.
public  voidsetServerSocket(QServerSocket socket)
     Sets the server socket.
public  voidsetSocketTimeout(Period period)
     Sets the read/write timeout for the accepted sockets.
public  voidsetSuspendTimeMax(Period period)
    
public  voidsetTcpNoDelay(boolean tcpNoDelay)
    
public  voidsetThrottleConcurrentMax(int max)
     Configures the throttle.
public  voidsetType(Class cl)
     Sets protocol class.
public  voidsetVirtualHost(String host)
     Sets the virtual host for IP-based virtual host.
public  voidsetWriteTimeout(Period period)
     Sets the write timeout for the accepted sockets.
public  voidstart()
     Starts the port listening.
 voidstartConnection(TcpConnection conn)
    
 booleansuspend(TcpConnection conn)
    
 voidthreadBegin(TcpConnection conn)
     Marks a new thread as running.
 voidthreadEnd(TcpConnection conn)
     Marks a new thread as stopped.
public  StringtoString()
    


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.