|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objecttigase.server.BasicComponent
tigase.server.AbstractMessageReceiver
tigase.server.ConnectionManager<IO>
IO - public abstract class ConnectionManager<IO extends XMPPIOService<?>>
Describe class ConnectionManager here. Created: Sun Jan 22 22:52:58 2006
| Fields inherited from class tigase.server.AbstractMessageReceiver |
|---|
HOUR, INCOMING_FILTERS_PROP_KEY, INCOMING_FILTERS_PROP_VAL, MAX_QUEUE_SIZE_PROP_KEY, MAX_QUEUE_SIZE_PROP_VAL, maxInQueueSize, maxOutQueueSize, MINUTE, OUTGOING_FILTERS_PROP_KEY, OUTGOING_FILTERS_PROP_VAL, SECOND |
| Fields inherited from class tigase.server.BasicComponent |
|---|
admins, ALL_PROP_KEY, COMMAND_PROP_NODE, scriptCommands, SCRIPTS_DIR_PROP_DEF, SCRIPTS_DIR_PROP_KEY, vHostManager |
| Fields inherited from interface tigase.disco.XMPPService |
|---|
CMD_FEATURES, DEF_FEATURES, INFO_XMLNS, ITEMS_XMLNS |
| Constructor Summary | |
|---|---|
ConnectionManager()
|
|
| Method Summary | |
|---|---|
protected void |
addWaitingTask(Map<String,Object> conn)
|
protected int |
countIOServices()
Returns number of active network connections (IOServices). |
protected void |
doForAllServices(ServiceChecker<IO> checker)
Perform a given action defined by ServiceChecker for all active IOService objects (active network connections). |
void |
everyMinute()
Method description |
Map<String,Object> |
getDefaults(Map<String,Object> params)
Method description |
protected int[] |
getDefPlainPorts()
|
protected int[] |
getDefSSLPorts()
|
protected abstract long |
getMaxInactiveTime()
|
protected Map<String,Object> |
getParamsForPort(int port)
|
protected String |
getServiceId(tigase.xmpp.JID jid)
|
protected String |
getServiceId(Packet packet)
|
void |
getStatistics(StatisticsList list)
Generates the component statistics. |
protected String |
getUniqueId(IO serv)
|
protected IO |
getXMPPIOService(Packet p)
|
protected IO |
getXMPPIOService(String serviceId)
|
protected abstract IO |
getXMPPIOServiceInstance()
|
int |
hashCodeForPacket(Packet packet)
This method can be overwritten in extending classes to get a different packets distribution to different threads. |
void |
initBindings(Bindings binds)
Method description |
void |
initializationCompleted()
Method description |
protected boolean |
isHighThroughput()
|
void |
packetsReady(IO serv)
Method description |
int |
processingInThreads()
Method description |
int |
processingOutThreads()
|
void |
processPacket(Packet packet)
Method description |
abstract Queue<Packet> |
processSocketData(IO serv)
Method description |
abstract void |
reconnectionFailed(Map<String,Object> port_props)
Method description |
void |
release()
Method description |
void |
serviceStarted(IO service)
Method description |
boolean |
serviceStopped(IO service)
|
void |
setName(String name)
Method description |
void |
setProperties(Map<String,Object> props)
Method description |
void |
writePacketsToSocket(IO serv,
Queue<Packet> packets)
Method description |
boolean |
writePacketToSocket(IO ios,
Packet p)
Method description |
protected boolean |
writePacketToSocket(Packet p)
|
protected boolean |
writePacketToSocket(Packet p,
String serviceId)
|
protected void |
writeRawData(IO ios,
String data)
|
| Methods inherited from class tigase.server.AbstractMessageReceiver |
|---|
addOutPacket, addOutPacketNB, addOutPackets, addOutPacketWithTimeout, addPacket, addPacketNB, addPackets, addRegexRouting, addTimerTask, addTimerTask, clearRegexRoutings, everyHour, everySecond, getMaxQueueSize, getRegexRoutings, isInRegexRoutings, newPacketId, processingThreads, processOutPacket, processPacket, removeRegexRouting, setMaxQueueSize, setParent, start, stop |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface tigase.xmpp.XMPPIOServiceListener |
|---|
xmppStreamClosed, xmppStreamOpened |
| Methods inherited from interface tigase.net.IOServiceListener |
|---|
tlsHandshakeCompleted |
| Methods inherited from interface tigase.server.MessageReceiver |
|---|
getDefHostName |
| Methods inherited from interface tigase.server.ServerComponent |
|---|
getComponentId, getName |
| Field Detail |
|---|
public static final String NET_BUFFER_ST_PROP_KEY
public static final String NET_BUFFER_HT_PROP_KEY
protected static final String PORT_KEY
protected static final String PROP_KEY
protected static final String PORTS_PROP_KEY
protected static final String PORT_TYPE_PROP_KEY
protected static final String PORT_SOCKET_PROP_KEY
protected static final String PORT_IFC_PROP_KEY
protected static final String PORT_CLASS_PROP_KEY
protected static final String PORT_REMOTE_HOST_PROP_KEY
protected static final String PORT_REMOTE_HOST_PROP_VAL
protected static final String TLS_PROP_KEY
protected static final String TLS_USE_PROP_KEY
protected static final boolean TLS_USE_PROP_VAL
protected static final String TLS_REQUIRED_PROP_KEY
protected static final boolean TLS_REQUIRED_PROP_VAL
protected static final String MAX_RECONNECTS_PROP_KEY
protected static final String NET_BUFFER_PROP_KEY
protected static final int NET_BUFFER_ST_PROP_VAL
protected static final int NET_BUFFER_HT_PROP_VAL
public static final String PORT_LOCAL_HOST_PROP_KEY
public String[] PORT_IFC_PROP_VAL
protected int net_buffer
protected long connectionDelay
| Constructor Detail |
|---|
public ConnectionManager()
| Method Detail |
|---|
public abstract Queue<Packet> processSocketData(IO serv)
serv -
public abstract void reconnectionFailed(Map<String,Object> port_props)
port_props - protected abstract long getMaxInactiveTime()
protected abstract IO getXMPPIOServiceInstance()
public void everyMinute()
everyMinute in class AbstractMessageReceiverpublic Map<String,Object> getDefaults(Map<String,Object> params)
getDefaults in interface ConfigurablegetDefaults in class AbstractMessageReceiverparams -
public void getStatistics(StatisticsList list)
getStatistics in interface StatisticsContainergetStatistics in class AbstractMessageReceiverlist - is a collection to put the component statistics in.public int hashCodeForPacket(Packet packet)
hashCodeForPacket in class AbstractMessageReceiverpacket -
public void initBindings(Bindings binds)
initBindings in class BasicComponentbinds - public void initializationCompleted()
initializationCompleted in interface ServerComponentinitializationCompleted in class BasicComponent
public void packetsReady(IO serv)
throws IOException
packetsReady in interface IOServiceListener<IO extends XMPPIOService<?>>serv -
IOExceptionpublic void processPacket(Packet packet)
processPacket in class AbstractMessageReceiverpacket - public int processingInThreads()
processingInThreads in class AbstractMessageReceiverpublic int processingOutThreads()
processingOutThreads in class AbstractMessageReceiverpublic void release()
release in interface ServerComponentrelease in class AbstractMessageReceiver@TODO(note="Do something if service with the same unique ID is already started, possibly kill the old one...") public void serviceStarted(IO service)
service - public boolean serviceStopped(IO service)
serviceStopped in interface IOServiceListener<IO extends XMPPIOService<?>>service -
public void setName(String name)
setName in interface ServerComponentsetName in class AbstractMessageReceivername - public void setProperties(Map<String,Object> props)
setProperties in interface ConfigurablesetProperties in class AbstractMessageReceiverprops -
public boolean writePacketToSocket(IO ios,
Packet p)
ios - p -
public void writePacketsToSocket(IO serv,
Queue<Packet> packets)
serv - packets - protected void addWaitingTask(Map<String,Object> conn)
protected int countIOServices()
protected void doForAllServices(ServiceChecker<IO> checker)
checker - is a ServiceChecker instance defining an action to
perform for all IOService objects.protected int[] getDefPlainPorts()
protected int[] getDefSSLPorts()
protected Map<String,Object> getParamsForPort(int port)
protected String getServiceId(Packet packet)
protected String getServiceId(tigase.xmpp.JID jid)
protected String getUniqueId(IO serv)
protected IO getXMPPIOService(String serviceId)
protected IO getXMPPIOService(Packet p)
protected boolean isHighThroughput()
protected boolean writePacketToSocket(Packet p)
p -
protected boolean writePacketToSocket(Packet p,
String serviceId)
protected void writeRawData(IO ios,
String data)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||