Tasks #1048
Specify disconnect protocol for socket transport
Status: | In Progress | Start date: | 06/28/2012 | ||
---|---|---|---|---|---|
Priority: | Normal | Due date: | |||
Assignee: | J. Moringen | % Done: | 50% | ||
Category: | Protocol | ||||
Target version: | rsb-0.18 |
Related issues
Associated revisions
Implement shutdown protocol for socket transport
Implemented a basic shutdown protocol using the TCP functionalities.
refs #1048
Implement shutdown protocol for socket transport
Implemented a basic shutdown protocol using the TCP functionalities.
refs #1048
Implement shutdown protocol for socket transport
Implemented a basic shutdown protocol using the TCP functionalities.
refs #1048
Added shutdown protocol in src/transport/socket/*.lisp
refs #1048
This implements the initial change towards a shutdown protocol. For
now, we use shutdown(3posix) for the output direction on both sockets
to transmit the respective shutdown request messages.
- src/transport/socket/protocol.lisp: new file; contains protocol
functions used in the socket transport module - src/transport/socket/conditions.lisp (header): updated copyright
(connection-shutdown-requested): new condition; signaled when the
remote peer requests the shutdown of a connection
(shutdown-handshake-for connection-shutdown-requested): new method;
return :receive - src/transport/socket/bus-connection.lisp (bus-connection::closing?):
changed type boolean -> member nil t :send :receive; updated
documentation string
(shared-initialize :after bus-connection t): call `handshake'
(handshake): new function; perform sending or receiving role of
setup or shutdown handshake
(receive-message bus-connection t): recognize shutdown request by
remote peer and call error policy with
`connection-shutdown-requested' condition in that case
(disconnect bus-connection): renamed close -> disconnect;
when requested perform a particular role of the shutdown handshake,
possibly waiting for the handshake to complete; after that,
terminate the receiver thread and close the socket
(print-object bus-connection): print role in shutdown handshake, if
any
(%make-error-policy): use `named-lambda'; call `disconnect' with
suitable handshake role which is determined by calling
`shutdown-handshake-for' on the condition; do not call
`stop-receiver' since `disconnect' will always do that - cl-rsb.asd (system cl-rsb-and-usocket): added file
src/transport/socket/protocol.lisp
History
#1 Updated by J. Moringen over 11 years ago
- Target version changed from rsb-0.9 to rsb-0.7
#2 Updated by J. Moringen over 11 years ago
- Target version changed from rsb-0.7 to rsb-0.9
#3 Updated by J. Moringen over 11 years ago
- Status changed from New to In Progress
- Assignee set to J. Moringen
- % Done changed from 0 to 10
#4 Updated by J. Moringen over 11 years ago
- Target version changed from rsb-0.9 to rsb-0.10
#5 Updated by J. Wienke over 10 years ago
- % Done changed from 10 to 50
Shutdown sequence has been implemented using the TCP possibilities in java, python and c++.
What is still missing is to distinguish between erroneous disconnects and planned once by transmitting a null byte when a planned disconnect was accepted.
#6 Updated by J. Moringen over 10 years ago
- Target version changed from rsb-0.10 to rsb-0.11
#7 Updated by J. Moringen almost 10 years ago
- Target version changed from rsb-0.11 to rsb-0.12
#8 Updated by J. Moringen almost 9 years ago
- Target version changed from rsb-0.12 to rsb-0.13
#9 Updated by J. Moringen about 8 years ago
- Target version changed from rsb-0.13 to rsb-0.14
#10 Updated by J. Moringen almost 8 years ago
- Target version changed from rsb-0.14 to rsb-0.15
#11 Updated by J. Moringen over 7 years ago
- Target version changed from rsb-0.15 to rsb-0.16
#12 Updated by J. Moringen almost 7 years ago
- Target version changed from rsb-0.16 to rsb-0.17
#13 Updated by J. Moringen over 6 years ago
- Target version changed from rsb-0.17 to rsb-0.18