Ports Management
This function is implemented in the J2EE Engine Ports Manager and is used to manage ports on which sockets are opened. It stores information about the mapping between a port and a service that uses it, collects data about all Sockets and ServerSockets, and registers listeners to the TCP port.
All transport services are using Ports Manager through their context to open ServerSocket or Socket, as well as to close sockets.
When a client socket is created, it is registered in the Connections Manipulator Manager. It is then wrapped in a TCPRunnableConnection, through which the manager takes care of reading and writing in this socket, and sends events to the service that will process the request.
Ports Manager manipulates with the sockets of a particular dispatcher. All methods from the ServiceDispContextthat are connected with the socket manipulation are implemented on the basis of this module.
Each service is able to open different types of sockets (ServerSocket, Socket). Different types of services are granted permissions to apply transport layers when opening a socket. This means that a socket with a specified queue can be opened, for example – SSL/HTTPTunneling. First an HTTP socket has to be opened: a standard HTTP request is created and sent using the data sent through this type of socket. Respectively, the HTTP requests are received, from which the data is extracted and disposed to the user. SSL is applied above this socket.
The different transport layers are realized as separate services that implement methods from the service frame. Through these methods Ports Manager receives sockets with specific transport quality from the corresponding service.
See also:
Ports Manager Properties in the Reference Manual