This is an implementation of the
org.apache.derby.mbeans.drda.NetworkServerMBean,
providing management and monitoring capabilities related to the Network
Server through JMX.
This bean uses callbacks to the NetworkServerControlImpl class instead of invoking NetworkServerControl, as it is the impl class that contains most of the information we want to expose via JMX.
org.apache.derby.mbeans.drda.NetworkServerMBean
| Modifier and Type | Field and Description |
|---|---|
| private static final SystemPermission | |
| private long | |
| private long | |
| private long | |
| private long | |
| private static final SystemPermission | |
| private int | |
| private int | |
| private NetworkServerControlImpl | |
| private final long |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| private static void | |
| private static void | |
| private static void | |
| public int | getAccumulatedConnectionCount()
Implements org. Gets the accumulated number of connections. |
| public int | getActiveConnectionCount()
Implements org. Gets the number of currently active connections. |
| public long | getBytesReceived()
Implements org. Gets the total number of bytes read by the server since it was started. |
| public synchronized int | getBytesReceivedPerSecond()
Implements org. Gets the number of bytes received per second by the Network Server. |
| public long | getBytesSent()
Implements org. Gets the total number of bytes written by the server since it was started. |
| public synchronized int | getBytesSentPerSecond()
Implements org. Gets the number of bytes sent per second by the Network Server. |
| public int | getConnectionCount()
Implements org. Gets the total number of current connections (waiting or active) to the Network Server. |
| public int | getConnectionThreadPoolSize()
Implements org. Get the size of the connection thread pool. |
| public String | getDrdaHost()
Implements org. Gets the network interface address on which the Network Server is listening. |
| public boolean | getDrdaKeepAlive()
Implements org.
Reports whether or not the Derby Network Server will send keep-alive
probes and attempt to clean up connections for disconnected clients (the
value of the |
| public int | getDrdaMaxThreads()
Implements org. Reports the maximum number of client connection threads the Network Server will allocate at any given time. |
| public int | getDrdaPortNumber()
Implements org. Gets the port number on which the Network Server is listening for client connections. |
| public String | getDrdaSecurityMechanism()
Implements org. The Derby security mechanism required by the Network Server for all client connections. |
| public String | getDrdaSslMode()
Implements org. Reports whether client connections must be encrypted using Secure Sockets Layer (SSL), and whether certificate based peer authentication is enabled. |
| public int | getDrdaStreamOutBufferSize()
Implements org. The size of the buffer used for streaming BLOB and CLOB from server to client. |
| public int | getDrdaTimeSlice()
Implements org.
If the server property |
| public boolean | getDrdaTraceAll()
Implements org. Whether server-side tracing is enabled for all client connections (sessions). |
| public String | getDrdaTraceDirectory()
Implements org. Indicates the location of tracing files on the server host, if server tracing has been enabled. |
| private String | Returns: the value of the given server propertythe name of the server property property)Gets the value of a specific network server setting (property). |
| public long | getStartTime()
Implements org. |
| public long | getUptime()
Implements org. |
| public int | getWaitingConnectionCount()
Implements org. Gets the number of currently waiting connections. |
| public void |
| CONTROL | back to summary |
|---|---|
| private static final SystemPermission CONTROL | |
| lastReceiveBytes | back to summary |
|---|---|
| private long lastReceiveBytes | |
| lastReceiveTime | back to summary |
|---|---|
| private long lastReceiveTime | |
| lastSentBytes | back to summary |
|---|---|
| private long lastSentBytes | |
| lastSentTime | back to summary |
|---|---|
| private long lastSentTime | |
| MONITOR | back to summary |
|---|---|
| private static final SystemPermission MONITOR | |
| receiveResult | back to summary |
|---|---|
| private int receiveResult | |
| sentResult | back to summary |
|---|---|
| private int sentResult | |
| server | back to summary |
|---|---|
| private NetworkServerControlImpl server | |
| startTime | back to summary |
|---|---|
| private final long startTime | |
| NetworkServerMBeanImpl | back to summary |
|---|---|
| pack-priv NetworkServerMBeanImpl(NetworkServerControlImpl nsc) | |
| checkControl | back to summary |
|---|---|
| private static void checkControl() Ensure the caller has permission to control the network server. | |
| checkMonitor | back to summary |
|---|---|
| private static void checkMonitor() Ensure the caller has permission to monitor the network server. | |
| checkPermission | back to summary |
|---|---|
| private static void checkPermission(SystemPermission permission) | |
| getAccumulatedConnectionCount | back to summary |
|---|---|
| public int getAccumulatedConnectionCount() Implements org. Doc from org. Gets the accumulated number of connections. This includes all active and waiting connections since the Network Server was started. This number will not decrease as long as the Network Server is running.
Require
| |
| getActiveConnectionCount | back to summary |
|---|---|
| public int getActiveConnectionCount() Implements org. Doc from org.
Gets the number of currently active connections. All connections are
active if the DrdaMaxThreads attribute ( If DrdaMaxThreads is > 0 and DrdaTimeSlice is 0, connections remain active until they are closed. If there are more than DrdaMaxThreads connections, inactive connections will be waiting for some active connection to close. The connection request will return when the connection becomes active. If DrdaMaxThreads is > 0 and DrdaTimeSlice > 0, connections will be alternating beetween active and waiting according to Derby's time slicing algorithm.
Requires
| |
| getBytesReceived | back to summary |
|---|---|
| public long getBytesReceived() Implements org. Doc from org. Gets the total number of bytes read by the server since it was started.
Require
| |
| getBytesReceivedPerSecond | back to summary |
|---|---|
| public synchronized int getBytesReceivedPerSecond() Implements org. Doc from org. Gets the number of bytes received per second by the Network Server. This number is calculated by taking into account the number of bytes received since the last calculation (or since MBean startup if it is the first time this attibute is being read). The shortest interval measured is 1 second. This means that a new value will not be calculated unless there has been at least 1 second since the last calculation.
Requires
| |
| getBytesSent | back to summary |
|---|---|
| public long getBytesSent() Implements org. Doc from org. Gets the total number of bytes written by the server since it was started.
Requires
| |
| getBytesSentPerSecond | back to summary |
|---|---|
| public synchronized int getBytesSentPerSecond() Implements org. Doc from org. Gets the number of bytes sent per second by the Network Server. This number is calculated by taking into account the number of bytes sent since the last calculation (or since MBean startup if it is the first time this attibute is being read). The shortest interval measured is 1 second. This means that a new value will not be calculated unless there has been at least 1 second since the last calculation.
Requires
| |
| getConnectionCount | back to summary |
|---|---|
| public int getConnectionCount() Implements org. Doc from org. Gets the total number of current connections (waiting or active) to the Network Server.
Requires
| |
| getConnectionThreadPoolSize | back to summary |
|---|---|
| public int getConnectionThreadPoolSize() Implements org. Doc from org.
Get the size of the connection thread pool. If DrdaMaxThreads
(
Requires
| |
| getDrdaHost | back to summary |
|---|---|
| public String getDrdaHost() Implements org. Doc from org.
Gets the network interface address on which the Network Server is
listening. This corresponds to the value of the
For example, the value "
The special value "
Requires
| |
| getDrdaKeepAlive | back to summary |
|---|---|
| public boolean getDrdaKeepAlive() Implements org. Doc from org.
Reports whether or not the Derby Network Server will send keep-alive
probes and attempt to clean up connections for disconnected clients (the
value of the
If
If
Requires
See also the documentation for the property
| |
| getDrdaMaxThreads | back to summary |
|---|---|
| public int getDrdaMaxThreads() Implements org. Doc from org.
Reports the maximum number of client connection threads the Network
Server will allocate at any given time. This corresponds to the
Requires
| |
| getDrdaPortNumber | back to summary |
|---|---|
| public int getDrdaPortNumber() Implements org. Doc from org.
Gets the port number on which the Network Server is listening for client
connections. This corresponds to the value of the
Requires
| |
| getDrdaSecurityMechanism | back to summary |
|---|---|
| public String getDrdaSecurityMechanism() Implements org. Doc from org.
The Derby security mechanism required by the Network Server for all
client connections. This corresponds to the value of the
If not set, the empty String will be returned, which means that the Network Server accepts any connection which uses a valid security mechanism.
For a list of valid security mechanisms, refer to the
documentation for the
Requires
| |
| getDrdaSslMode | back to summary |
|---|---|
| public String getDrdaSslMode() Implements org. Doc from org.
Reports whether client connections must be encrypted using Secure
Sockets Layer (SSL), and whether certificate based peer authentication
is enabled. Refers to the Peer authentication means that the other side of the SSL connection is authenticated based on a trusted certificate installed locally.
The value returned is one of "
Requires
| |
| getDrdaStreamOutBufferSize | back to summary |
|---|---|
| public int getDrdaStreamOutBufferSize() Implements org. Doc from org.
The size of the buffer used for streaming BLOB and CLOB from server to
client. Refers to the This setting may improve streaming performance when the default sizes of packets being sent are significantly smaller than the maximum allowed packet size in the network.
Requires
| |
| getDrdaTimeSlice | back to summary |
|---|---|
| public int getDrdaTimeSlice() Implements org. Doc from org.
If the server property
Refers to the
Requires
| |
| getDrdaTraceAll | back to summary |
|---|---|
| public boolean getDrdaTraceAll() Implements org. Doc from org.
Whether server-side tracing is enabled for all client connections
(sessions). Refers to the Tracing may for example be useful when providing technical support information. The Network Server also supports tracing for individual connections (sessions), see the Derby Server and Administration Guide ("Controlling tracing by using the trace facility") for details. When tracing is enabled, tracing information from each client connection will be written to a separate trace file.
Requires
| |
| getDrdaTraceDirectory | back to summary |
|---|---|
| public String getDrdaTraceDirectory() Implements org. Doc from org. Indicates the location of tracing files on the server host, if server tracing has been enabled.
If the server setting
Requires
| |
| getServerProperty | back to summary |
|---|---|
| private String getServerProperty(String property) Gets the value of a specific network server setting (property).
Most server-related property keys have the prefix
| |
| getStartTime | back to summary |
|---|---|
| public long getStartTime() Implements org. Return start time.
| |
| getUptime | back to summary |
|---|---|
| public long getUptime() Implements org. Return time server has been running.
| |
| getWaitingConnectionCount | back to summary |
|---|---|
| public int getWaitingConnectionCount() Implements org. Doc from org. Gets the number of currently waiting connections. This number will always be 0 if DrdaMaxThreads is 0. Otherwise, if the total number of connections is less than or equal to DrdaMaxThreads, then no connections are waiting.
Requires
| |
| ping | back to summary |
|---|---|
| public void ping() throws Exception Implements org. Pings the Network Server.
| |