3.0. Functional Specification
This document specifies both a message format and a state machine for DSLCP protocol transactions.
3.1. Control Message Format
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Identifier | Total length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Function | Event Status |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Endpoint 1 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Endpoint 2 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Message |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Body |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
Identifier: 16 bits
The identifier is a value assigned by the DSLCP used to uniquely identify link setup transactions. It is intended to be used with the endpoint addresses by a link controller to identify a transaction.
Total length: 16 bits
The total length, in octets, including the header of this DSLCP control message.
Function: 16 bits
The operation to be processed or being responded to.
Functions currently defined are:
Bring up value 0
Bring down value 1
Event Status: 16 bits
The state of the controlled link, relative to the last function request.
The possible event states are:
Setup request succeeded value 2
Setup request failed value 3
Teardown request succeeded value 4
Teardown request failed value 5
Asynchronous network down value 7
Endpoint addresses: 32 bits each
The internet addresses of the two communicating parties for which the link is being prepared.
Message body: arbitrary length up to 65499 octets
An ascii string which is meaningful the link controller. When the requesting host is configured, the system administrator sets the control strings for each network link that may be accessed by the requesting host.
3.2. State Machine
The transport provider is aware of only 2 possible states for the controlled link: up or down. Furthermore, transport users may request or release transport services from the transport provider at any time. Thus, there must be a state machine employed by DSLCP when communicating between the transport provider and the controlled link. This state machine hides the details of link control transactions from the transport provider. The state machine has 6 possible states.
Down: There is no active transport connection and the controlled link is not setup.
Coming Up: A transport user has requested a connection for which the transport provider has given a setup request to the DSLCP. The DSLCP has sent a setup request to the link controller and is awaiting a response.
Up: At least one transport connection is active and the controlled link is setup.
Going Down: All transport connections have been terminated and the transport provider has sent an equivalent number of up requests and down requests to the DSLCP. The DSLCP has sent a teardown request to the link controller and is awaiting a response.
Bring Down: While DSLCP is in the Coming Up state, the transport provider requested link teardown. As soon as a response is received from the link controller, the DSLCP will send a teardown request if the link setup was successful.
Bring Up: While in the Going Down state, the transport provider requested connection setup. As soon as a response is received from the link controller, the DSLCP will send a setup request.
DSLCP state diagram:
------- +----------------+
Transport | Down |<---------\
Connect ---->+----------------+ \
Request / ^ ^ \
------- Setup | | \
Send Failed | | Teardown \ Response Timeout
Setup /------ | | Success \ ---------------
/ / | | -------- |
| | | | |
| | | | |
| | Teardown Response | | |
| | Success Timeout | | |
| | ----------------- | | +----------+ |
| | Send---------|--|-----| Bring Up |--|----\
| | Setup | | +----------+ | | Transport
| | / | | ^ | | Teardown
| | / | | Transport | | Request
| | / | | Connect| | | ---------
| | / Setup | Request| | |
| | | Failed | -------| | |
v | v ------ | | | v
+--------------+ | | +-------------+
| Coming Up |----------+----|--|--Response--->| Going Down |
+--------------+ ^ | | Timeout +-------------+
| ^ | | | | -------- ^ ^
| | Transport | | | Send | |
| Transport Teardown | | | Teardown | |
| Connect Request | | | / |
| Request ------- | | | / |
| ------- v | | | / /
| \ +------------+ - | | / /
| -| Bring Down | ------ | / /
\ +------------+ --------|--Setup----- /
\ | Success /
\ | ------- /
\ Setup Network | Send / Transport
\ Success Is Down | Teardown / Teardown
\ ------- ------- | / Request
\ | / --------
\ | / Send
\ +---------------+ / Teardown
\----------->| Up |---
+---------------+
Events and State Transitions
The DSLCP will process three type of events:
- A link control request from the transport provider
- An DSLCP message from the link controller
- DSLCP message timeout
The transport provider will make link setup and and teardown requests to the DSLCP when transport users request and release services requiring link control operations. The transport provider should not keep track of the status of a particular link, as this is a function of the DSLCP. The transport provider may be unaware of redirection or other processing of link setup requests performed by DSLCP, so this is a function best left to DSLCP. The DSLCP will inform the transport provider as to the success or failure of a particular setup request, and transport providers may assume the success of teardown requests (the DSLCP will always return a success response to a teardown request).
The DSLCP will engage in link control transactions with link controllers. This will include accepting messages from link controllers in response to requests as well as unexpected messages from the link controller. Unexpected messages may include redundant responses to redundant requests sent as a result of timeouts.
Because of the possibility of unavailable links and link controllers, DSLCP should not wait indefinitely for message responses from link controllers to which it has sent messages. Since DSLCP does not require the use of a reliable transport protocol to carry DSLCP messages, DSLCP must have a timeout and retransmission mechanism. Since we have used DSLCP in a local network context with switch controllers which offer a quick turnaround (on the order of 1 second), we use a 5 second timeout with a 3 retransmit limit. These figures would require adaptation to different network and link controller configurations, and a self-adapting algorithm would be most appropriate for a general solution.
The specific events of interest to the DSLCP are:
-
Transport provider link setup request
-
Transport provider link teardown request
-
Link setup request failed
-
Link setup request succeeded
-
Link teardown request succeeded
-
Link teardown request failed
-
Network link is down
-
Timeout waiting for DSLCP response from link controller
The necessary processing for each event while in each state is as follows:
- Transport provider link setup request
-
Down:
- Send setup request to link controller.
- Enter Coming Up state.
- Notify transport provider to wait until link is up.
-
Coming Up:
-
Bring Up:
- Notify transport provider to wait until link is up.
-
Up:
- Notify transport provider that link is up.
-
Bring Down:
- Enter Coming Up state.
- Notify transport provider to wait until link is up.
-
Going Down:
- Enter Bring Up state.
- Notify transport provider to wait until link is up.
-
Discussion:
If the controlled link is not capable to support multiple transport connections, then the DSLCP must return appropriate errors when it detects multiple transport setup requests for that link.
-
- Transport provider link teardown request
- Down:
- Bring Down:
- Going Down:
- Notify transport provider that link is down.
- Coming Up:
- Enter Bring Down state.
- Notify transport provider that link is down.
- Bring Down:
- Notify transport provider that link is down.
- Up:
- Send teardown request.
- Enter Going Down state.
- Notify transport provider that link is down.
- Link setup request failed
- Down:
- Going Down:
- Bring Up:
- Unexpected message, possibly due to duplicate requests - ignore it.
- Up:
- Unexpected message, link controller may be refusing multiple setup requests sent because of timeout - ignore it.
- Coming Up:
- Bring Down:
- Enter down state.
- Link setup request succeeded
- Down:
- Unexpected message, possibly due to duplicate requests and reordering of request packets by network.
- Send teardown request.
- Going Down:
- Bring Up:
- Up:
- Unexpected message, possibly due to duplicate requests - ignore it.
- Coming Up:
- Enter Up state.
- Notify transport provider(s) waiting for link that it is available.
- Bring Down:
- Send teardown request.
- Enter Going Down state.
- Down:
- Link teardown request succeeded
-
Down:
-
Coming Up:
-
Bring Down:
- Unexpected message, possibly due to duplicate requests - ignore it.
-
Up:
- Unexpected message, possibly due to duplicate requests and reordering of request packets by network.
- Send teardown request.
- Enter Going Down state.
- Notify transport providers that link has gone down.
-
Bring Up:
- Send setup request
- Enter Coming Up state
-
Going Down:
- Enter Down state
-
Discussion:
If a teardown request succeeded message arrives when the DSLCP is in the UP state, then some error has occurred, and the conservative approach is to bring down the connection and resynchronize. However, it may be satisfactory to ignore the message without ill effect.
-
- Link teardown request failed
- Down:
- Coming up:
- Bring Down:
- Bring Up:
- Going Down:
- Up:
- DSLCP sent a teardown request message for an invalid transaction. The link controller has no identifier/endpoints transaction record for the request.
- Continue as if request had succeeded.
- Network link is down
- Down:
- Ignore message.
- Bring Down:
- Going Down:
- Enter Down state.
- Coming up:
- Bring Up:
- Up:
- Enter down state.
- Notify transport provider that link is down.
- Down:
- Timeout waiting for DSLCP response from controller
- Down:
- Up:
- DSLCP protocol error - fix bug, don't set timer when there are no outstanding requests.
- Coming Up:
- Bring Down:
- Send teardown request.
- Enter Going down state.
- Going Down:
- Enter Down state.
- Bring Up:
- Send setup request.
- Enter Coming Up state.