Handshake begin message exchanged between the server and the client.
First of all, when the connection between the client and the server is established the server sends this message to the client with all the server's supported profiles and the server version of the JMXMP protocol.
The first thing the client does is to compare the version of the JMXMP protocol supported by the server against the version supported by the client. As a result of this comparison the following things can happen:
Once the JMXMP protocol versions to use have been negotiated, the client and the server start the profile negotiation phase. The server's supported profiles are configured by specifying the jmx.remote.profiles
property in the environment map passed into the {@link javax.management.remote.JMXConnectorServer JMXConnectorServer}. Upon reception of the {@link HandshakeBeginMessage HandshakeBeginMessage} the client verifiesthat the profiles it wants to use, namely the ones specified through the jmx.remote.profiles
property in the environment map passed into the {@link javax.management.remote.JMXConnector JMXConnector} are all present in the server's supported profilelist. If false, the client sends a {@link HandshakeErrorMessage HandshakeErrorMessage} to the server and closesthe connection. Otherwise, the client starts exchanging profile messages with the server for the selected profiles following the order specified in the client's profile list. Once the profile exchanges between the client and the server are completed the client sends a {@link HandshakeEndMessage HandshakeEndMessage}to notify the server that the handshake exchanges have been successfully completed with regards to the client. Then the server verifies that the negotiated profiles do not compromise the server's minimum required security level and if the server agrees it sends a {@link HandshakeEndMessage HandshakeEndMessage} to notify theclient that the handshake exchanges have been successfully completed with regards to the server. If the server does not agree on the negotiated profiles it sends a {@link HandshakeErrorMessage HandshakeErrorMessage} to the client and closes the connection.
If an error is encountered at any time, either on the client or the server side, either peer can then send an {@link HandshakeErrorMessage indication} as to why the operation failed.
The server's supported profiles contained in this message are formatted as a space-separated list.
The server's JMXMP protocol version describes the version of the JMXMP protocol supported by the server.
|
|