|
Connection Manager 3.4.2 Javadoc | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jivesoftware.multiplexer.ServerSurrogate
public class ServerSurrogate
Surrogate of the main server where the Connection Manager is routing client packets. This class is responsible for keeping a pool of working threads to processing incoming clients traffic and forward it to the main server. Each working thread uses its own connection to the server. By default 5 threads/connections are established to the server. Use the system property xmpp.manager.connections to modify the default value.
ServerSurrogate is also responsible for caching the server configuration such as if non-sasl authentication or in-band registration are available.
Each connection to the server has its own ServerPacketReader
to read incoming
traffic from the server. Incoming server traffic is then handled by
ServerPacketHandler
.
Method Summary | |
---|---|
void |
clientSessionClosed(java.lang.String streamID)
Notification message indication that a client session has been closed. |
void |
clientSessionCreated(java.lang.String streamID)
Notification message indication that a new client session has been created. |
void |
deliveryFailed(org.dom4j.Element stanza,
java.lang.String streamID)
Notification message indicating that delivery of a stanza to a client has failed. |
Connection.CompressionPolicy |
getCompressionPolicy()
Returns whether compression is optional or is disabled. |
java.lang.String |
getSASLMechanisms(Session session)
Returns the SASL mechanisms supported by the server for client authentication. |
org.dom4j.Element |
getSASLMechanismsElement(Session session)
|
Connection.TLSPolicy |
getTlsPolicy()
Returns whether TLS is mandatory, optional or is disabled. |
boolean |
isInbandRegEnabled()
Returns true if in-band registration is supported by the server. |
boolean |
isNonSASLAuthEnabled()
Returns true if non-sasl authentication is supported by the server. |
void |
send(java.lang.String stanza,
java.lang.String streamID)
Forwards the specified stanza to the server. |
void |
setCompressionPolicy(Connection.CompressionPolicy compressionPolicy)
Sets whether compression is enabled or is disabled. |
void |
setInbandRegEnabled(boolean inbandRegEnabled)
Sets if in-band registration is supported by the server. |
void |
setNonSASLAuthEnabled(boolean nonSASLEnabled)
Sets if non-sasl authentication is supported by the server. |
void |
setSASLMechanisms(org.dom4j.Element mechanisms)
Returns the SASL mechanisms supported by the server for client authentication. |
void |
setTlsPolicy(Connection.TLSPolicy tlsPolicy)
Sets whether TLS is mandatory, optional or is disabled. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public void clientSessionCreated(java.lang.String streamID)
streamID
- the stream ID assigned by the connection manager to the new session.public void clientSessionClosed(java.lang.String streamID)
streamID
- the stream ID assigned by the connection manager to the session.public void deliveryFailed(org.dom4j.Element stanza, java.lang.String streamID)
stanza
- the stanza that was not sent to the client.streamID
- the stream ID assigned by the connection manager to the no
longer available session.public void send(java.lang.String stanza, java.lang.String streamID)
stanza
- the stanza to send to the server.streamID
- the stream ID assigned by the connection manager to the session.public java.lang.String getSASLMechanisms(Session session)
session
- the session connecting to the connection manager.
public org.dom4j.Element getSASLMechanismsElement(Session session)
public void setSASLMechanisms(org.dom4j.Element mechanisms)
mechanisms
- the SASL mechanisms supported by the server for client authentication.public Connection.TLSPolicy getTlsPolicy()
public void setTlsPolicy(Connection.TLSPolicy tlsPolicy)
tlsPolicy
- whether TLS is mandatory, optional or is disabled.public Connection.CompressionPolicy getCompressionPolicy()
public void setCompressionPolicy(Connection.CompressionPolicy compressionPolicy)
Note: Connection managers share the same code from Openfire so the same compression algorithms will be offered. // TODO When used with other server we need to store the available algorithms.
compressionPolicy
- whether Compression is enabled or is disabled.public boolean isNonSASLAuthEnabled()
public void setNonSASLAuthEnabled(boolean nonSASLEnabled)
nonSASLEnabled
- if non-sasl authentication is supported by the server.public boolean isInbandRegEnabled()
public void setInbandRegEnabled(boolean inbandRegEnabled)
inbandRegEnabled
- if in-band registration is supported by the server.
|
Connection Manager 3.4.2 Javadoc | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |