The following tables describe:
transport interface states
transport interface and t_look() events
outgoing events
incoming events
state transitions caused by transport system user actions
transport interface state transitions
TLOOK error events
Transport interface states
The following table describes the states used to describe the state transitions of the transport interface.
State | Meaning | Service type |
T_UNINIT | Not initialized. Start and end state of the interface | T_COTS |
T_UNBND | Initialized but not bound | T_COTS |
T_IDLE | No connection established | T_COTS |
T_OUTCON | Outgoing connection waiting for the server | T_COTS |
T_INCON | Incoming connection waiting for the server | T_COTS |
T_DATAXFER | Data transfer | T_COTS |
T_OUTREL | Orderly connection shutdown (waiting for confirmation for orderly connection shutdown) | T_COTS_ORD |
T_INREL | Incoming orderly connection shutdown (waiting for request for orderly connection shutdown) | T_COTS_ORD |
Transport interface and t_look() events
The user can call the t_look() function to determine which event has occurred if a TLOOK error is reported. The TLOOK error has a special significance for the transport interface. TLOOK informs the user when a function of the interface was interrupted by an unexpected asynchronous event on the specified transport endpoint. An error indicated by TLOOK must therefore not be interpreted as an interface error. The called function is not executed because of the pending event.
Transport interface events:
Event | Meaning |
T_LISTEN | A connection request arrived at the transport endpoint. T_LISTEN can only occur with a transport endpoint which is assigned an address with qlen > 0. |
T_CONNECT | Confirmation of a previously sent connection request has arrived. The confirmation is sent when the server accepts a connection request. |
T_DATA | User data has arrived. |
T_DISCONNECT | A message reporting that a connection has been aborted or refused has arrived |
T_ORDREL | The request for an orderly connection shutdown has arrived. |
T_UDERR | The report about an error with a previously sent datagram has arrived. |
TLOOK error events:
XTI function | Event |
t_accept() | T_DISCONNECT, T_LISTEN |
t_connect() | T_DISCONNECT, T_LISTEN |
t_listen() | T_DISCONNECT |
t_rcv() | T_DISCONNECT, T_ORDREL |
t_rcvconnect() | T_DISCONNECT |
t_rcvrel() | T_DISCONNECT |
t_rcvudata() | T_UDERR |
t_snd() | T_DISCONNECT, T_ORDREL |
t_sndudata() | T_UDERR |
t_unbind() | T_LISTEN, T_DATA |
t_sndrel() | T_DISCONNECT |
t_snddis() | T_DISCONNECT |
If execution of an XTI function leads to a TLOOK error on a transport endpoint, subsequent calls to the same or other XTI functions affected by the same TLOOK return the TLOOK error until the causing event has been handled. You can identify the event causing the TLOOK error with the XTI t_look() function and then handle it with a suitable other XTI function.
Outgoing events
The outgoing events are described in following table. They correspond to the values returned by the specified transport functions, where the functions send a request or reply to the transport provider.
Some of the events (e.g. accept) in the table are discriminated according to the context in which they occur. The context depends on the values of the following variables:
ocnt: Number of pending connection requests
fd: File descriptor of the current transport endpoint
refsd: File descriptor of the transport endpoint on which a connection is accepted
Event | Meaning | Service type |
opened | Successful termination of t_open() | T_COTS |
bind | Successful termination of t_bind() | T_COTS |
optmgmt | Successful termination of t_optmgmt() | T_COTS_ORD |
unbind | Successful termination of t_unbind() | T_COTS |
closed | Successful termination of t_close() | T_COTS |
connect1 | Successful termination of t_connect() in synchronous mode | T_COTS |
connect2 | TNODATA error with t_connect() in asynchronous mode or TLOOK error caused by a connection shutdown request arriving at the communications endpoint | T_COTS |
accept1 | Successful termination of t_accept() with ocnt == 1, | T_COTS |
accept2 | Successful termination of t_accept() with ocnt == 1, | T_COTS |
accept3 | Successful termination of t_accept() with ocnt >1 | T_COTS |
snd | Successful termination of t_snd() | T_COTS |
snddis1 | Successful termination of t_snddis() with ocnt <=1 | T_COTS |
snddis2 | Successful termination of t_snddis() with ocnt >1 | T_COTS |
sndrel | Successful termination of t_sndrel() | T_COTS_ORD |
sndudata | Successful termination of t_sndudata() | T_CLTS |
Incoming events
The incoming events correspond to the successful return values of the specified function, where these functions receive data or information about events from the transport provider. The only incoming event that is not connected directly to the return value of a function is pass_conn. The pass_conn event occurs when a user transfers a connection to another transport endpoint. This event occurs on a transport endpoint to which the connection was transferred, although no transport interface function was called for it. The pass_conn event describes the behavior when a user accepts a connection on another transport endpoint.
In the following table, the rcvdis events are discriminated according to the context in which they occur. The context depends on the value of ocnt. The value of ocnt specifies the number of pending connection requests on the transport endpoint.
Event | Meaning | Service type |
listen | Successful termination of t_listen() | T_COTS |
rcvconnect | Successful termination of t_rcvconnect() | T_COTS |
rcv | Successful termination of t_rcv() | T_COTS |
rcvdis1 | Successful termination of t_rcvdis() with ocnt <= 0 | T_COTS |
rcvdis2 | Successful termination of t_rcvdis() with ocnt = = 1 | T_COTS |
rcvdis3 | Successful termination of t_rcvdis() with ocnt > 1 | T_COTS |
rcvrel | Successful termination of t_rcvrel() | T_COTS_ORD |
rcvudata | Successful termination of t_rcvudata() | T_CLTS |
rcvuderr | Successful termination of t_rcvuderr() | T_CLTS |
pass_conn | Receive a transferred connection | T_COTS |
State transitions caused by transport system user actions
In the state tables listed below, some state transitions are accompanied by a series of actions that have to be carried out by the transport service user. These actions are identified with the notation "[n]", where n is the number of the action to be executed.
The actions concerned are as follows:
Set the number of pending connection requests to 0.
Increment the number of pending connection requests.
Decrement the number of pending connection requests.
Transfer a connection to another transport endpoint, as specified in t_accept().
State tables
The state transitions of the transport interface are described in the following tables. The transition to the next state is shown for a current state and an event. All actions are also defined which are to be executed by the transport system user. Such actions are identified with "[n]".
The contents of each box indicate the follow-up state. This is dependent on the current state (at the head of the column) and the current incoming or outgoing event (at the left in the line concerned). An empty box means that the state/event combination concerned is invalid. Each box can contain an action list (as described in the previous section) in addition to the follow-up state. The transport service user must execute the actions in the listed order.
You should note the following points when reading the state tables:
The t_close() function is also handled in the state tables (see the closed event in tho following table). However, t_close() can be called from any state to close a transport endpoint. If the address is bound to a transport endpoint, calling t_close() automatically releases the address.
The transport provider detects when a transport service user calls a function outside the defined order. In this case, the transport provider refuses the function and sets t_errno to TOUTSTATE. The state does not change.
If a different transport error occurs, the state does not normally change. An exception to this is a TLOOK or TNODATA error with t_connect(). Other exceptions are noted explicitly in the description of the functions in section "XTI(POSIX) user functions". In the state tables, it is assumed that the transport interface is used correctly.
The t_getinfo(), t_getstate(), t_alloc(), t_free(), t_sync(), t_look() and t_error() functions are not included in the state tables as they do not affect the state.
The state transitions in the following phases are each handled in a separate table:
local management (connection-oriented and connectionless service)
data transfer in the connectionless service
connection setup, data transfer and connection shutdown in the connection-oriented service
Local management state transitions:
Event | State | ||
T_UNINIT | T_UNBND | T_IDLE | |
opened | T_UNBND | ||
bind | T_IDLE [1] | ||
optmgmt | T_IDLE | ||
unbind | T_UNBND | ||
closed | T_UNINIT |
Connectionless service state transitions:
Event | State |
T_IDLE | |
sndudata | T_IDLE |
rcvudata | T_IDLE |
rcvuderr | T_IDLE |
Connection-oriented service state transitions:
Event | State | |||||
T_IDLE | T_OUTCON | T_INCON | T_DATAXFER | T_OUTREL | T_INREL | |
connect1 | T_DATAXFER | |||||
connect2 | T_OUTCON | |||||
rcvconnect | T_DATAXFER | |||||
listen | T_INCONN [2] | T_INCONN [2] | ||||
accept1 | T_DATAXFER | |||||
accept2 | T_IDLE [3][4] | |||||
accept3 | T_INCON [3][4] | |||||
snd | T_DATAXFER | T_INREL | ||||
rcv | T_DATAXFER | T_OUTREL | ||||
snddis1 | T_IDLE | T_IDLE [3] | T_IDLE | T_IDLE | T_IDLE | |
snddis2 | T_IDLE [3] | |||||
rcvdis1 | T_IDLE | T_IDLE | T_IDLE | T_IDLE | ||
rcvdis2 | T_IDLE [3] | |||||
rcvdis3 | T_INCON [3] | |||||
sndrel | T_OUTREL | T_IDLE | ||||
rcvrel | T_INREL | T_IDLE | ||||
pass_conn | T_DATAXFER |