Network Config   «Prev  Next»

Lesson 5 MTS and incoming connections
Objective Describe how MTS processes incoming connections.

MTS and Incoming Connections

The listener is a software program that runs on each remote node and listens for any incoming database requests. When a request is detected, the listener may direct the request to:
  1. A dedicated server
  2. A multithreaded server
  3. An existing process or pre-spawned shadow process
The following Slideshow illustrates what happens if the listener chooses to direct that request to an MTS:

Oracle MTS Connections

1) The client calls the address of the listener for the desired database.
1) The client calls the address of the listener for the desired database. If there is more than on listener, the client randomizes its calls among those that are available.

2) The listener receives the connection request.
2) The listener receives the connection request.

3) The listener performs the connection handshake and determines if the client is allowed to connect (by checking the list of SIDs it listens for).
3) The listener performs the connection handshake and determines if the client is allowed to connect (by checking the list of SIDs it listens for).

4) The listener issues a redirect message back to the client containing the address of the least-called dispatcher that is listening on the protocol used by the client.
4) The listener issues a redirect message back to the client containing the address of the least-called dispatcher that is listening on the protocol used by the client.

5) The client closes the connection to the listener.
5) The client closes the connection to the listener.

6) The client establishes a new connection to the dispatcher, using the address provided by the listener in the redirect message.
6) The client establishes a new connection to the dispatcher, using the address provided by the listener in the redirect message.

7) The listener and dispatcher perform a short handshake to update each other regarding the presence of the new connection.
7) The listener and dispatcher perform a short handshake to update each other regarding the presence of the new connection. This enables the listener to load-balance connections between dispatchers running on the same protocol.

8) The listener resumes listening for incoming connections.
8) The listener resumes listening for incoming connections.

When an Oracle database has been configured as a multi-threaded server, incoming connections are always routed to the dispatcher. However, a dedicated connection can be specifically requested by having SERVER=DEDICATED in the CONNECT_DATA portion of the connect descriptor. It is sometimes useful for transactions involving a high degree of activity to use a dedicated connection.
The next lesson discusses the architecture of MTS.

Sending MTS Request

Before moving on to the next lesson, click the Exercise link below to test your understanding of the processes involved in directing a request to MTS.
Sending MTS Request