|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jboss.remoting.AbstractInvoker
org.jboss.remoting.ServerInvoker
org.jboss.remoting.transport.socket.SocketServerInvoker
SocketServerInvoker is the server-side of a SOCKET based transport
Field Summary | |
protected java.lang.Thread[] |
acceptThreads
|
protected int |
backlog
|
static java.lang.String |
CHECK_CONNECTION_KEY
|
protected LRUPool |
clientpool
|
protected int |
maxPoolSize
|
protected int |
numAcceptThreads
|
protected boolean |
running
|
static java.lang.String |
SERVER_SOCKET_CLASS_FLAG
Property value to set if want a custom socket wrapper for providing custom streams. |
protected java.net.ServerSocket |
serverSocket
|
protected java.util.LinkedList |
threadpool
|
protected boolean |
trace
The logging trace level flag |
Fields inherited from class org.jboss.remoting.AbstractInvoker |
classbyteloader, configuration, localServerLocators, locator, log, serializationType |
Constructor Summary | |
SocketServerInvoker(InvokerLocator locator)
|
|
SocketServerInvoker(InvokerLocator locator,
java.util.Map configuration)
|
Method Summary | |
protected void |
cleanup()
|
protected java.net.ServerSocket |
createServerSocket(int serverBindPort,
int backlog,
java.net.InetAddress bindAddress)
|
void |
destroy()
destory the invoker permanently |
protected void |
finalize()
|
int |
getBacklog()
|
int |
getCurrentClientPoolSize()
|
int |
getCurrentThreadPoolSize()
|
protected java.lang.String |
getDefaultDataType()
Each implementation of the remote client invoker should have a default data type that is uses in the case it is not specified in the invoker locator uri. |
int |
getMaxPoolSize()
Setter for max pool size. |
int |
getNumAcceptThreads()
Getter for property numAcceptThreads |
protected java.lang.String |
getThreadName(int i)
|
boolean |
isTransportBiDirectional()
returns true if the transport is bi-directional in nature, for example, SOAP in unidirectional and SOCKETs are bi-directional (unless behind a firewall for example). |
protected void |
processInvocation(java.net.Socket socket)
|
void |
run()
|
void |
setBacklog(int backlog)
|
void |
setMaxPoolSize(int maxPoolSize)
The number of server threads for processing client. |
void |
setNumAcceptThreads(int size)
Setter for property numAcceptThreads |
protected void |
setup()
|
void |
start()
Starts the invoker. |
void |
stop()
Stops the invoker. |
Methods inherited from class org.jboss.remoting.AbstractInvoker |
addClientLocator, getClassLoader, getClientLocator, getLocator, getSerializationType, setClassLoader, setSerializationType |
Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.jboss.remoting.transport.socket.SocketServerInvokerMBean |
getServerBindPort |
Methods inherited from interface org.jboss.remoting.ServerInvokerMBean |
create, getClientConnectAddress, getClientConnectPort, getConfiguration, getDataType, getServerBindAddress, getTimeout, isStarted, setClientConnectAddress, setClientConnectPort, setConfiguration, setTimeout |
Field Detail |
public static final java.lang.String CHECK_CONNECTION_KEY
public static final java.lang.String SERVER_SOCKET_CLASS_FLAG
protected java.net.ServerSocket serverSocket
protected boolean running
protected int backlog
protected java.lang.Thread[] acceptThreads
protected int numAcceptThreads
protected int maxPoolSize
protected LRUPool clientpool
protected java.util.LinkedList threadpool
protected boolean trace
Constructor Detail |
public SocketServerInvoker(InvokerLocator locator)
public SocketServerInvoker(InvokerLocator locator, java.util.Map configuration)
Method Detail |
protected void setup() throws java.lang.Exception
setup
in class ServerInvoker
java.lang.Exception
protected void finalize() throws java.lang.Throwable
java.lang.Throwable
public void start() throws java.io.IOException
start
in interface SocketServerInvokerMBean
start
in class ServerInvoker
java.io.IOException
protected java.net.ServerSocket createServerSocket(int serverBindPort, int backlog, java.net.InetAddress bindAddress) throws java.io.IOException
java.io.IOException
protected java.lang.String getThreadName(int i)
public void destroy()
ServerInvokerMBean
destroy
in interface ServerInvokerMBean
destroy
in class ServerInvoker
public void stop()
stop
in interface SocketServerInvokerMBean
stop
in class ServerInvoker
protected void cleanup()
public int getCurrentThreadPoolSize()
getCurrentThreadPoolSize
in interface SocketServerInvokerMBean
public int getCurrentClientPoolSize()
getCurrentClientPoolSize
in interface SocketServerInvokerMBean
public int getNumAcceptThreads()
getNumAcceptThreads
in interface SocketServerInvokerMBean
public void setNumAcceptThreads(int size)
setNumAcceptThreads
in interface SocketServerInvokerMBean
size
- The number of threads that exist for accepting client connectionspublic int getMaxPoolSize()
getMaxPoolSize
in interface SocketServerInvokerMBean
public void setMaxPoolSize(int maxPoolSize)
setMaxPoolSize
in interface SocketServerInvokerMBean
maxPoolSize
- public int getBacklog()
getBacklog
in interface SocketServerInvokerMBean
public void setBacklog(int backlog)
setBacklog
in interface SocketServerInvokerMBean
public void run()
run
in interface java.lang.Runnable
protected void processInvocation(java.net.Socket socket) throws java.lang.Exception
java.lang.Exception
public boolean isTransportBiDirectional()
isTransportBiDirectional
in interface ServerInvokerMBean
protected java.lang.String getDefaultDataType()
getDefaultDataType
in class ServerInvoker
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |