Difference between revisions of "Common NetMsg Exchanges"
From BRL-CAD
Line 2: | Line 2: | ||
==Application Interconnect Handshake== | ==Application Interconnect Handshake== | ||
− | This sequence of NetMsg exchanges represents the communications between an external application (App M) attempting to connect to a running Geometry Service (App GS). This sequence assumes success. | + | This sequence of [[IBME_GeometryService#NetMsg_Class|NetMsg]] exchanges represents the communications between an external application (App M) attempting to connect to a running Geometry Service (App GS). This sequence assumes success. |
===Main Sequence=== | ===Main Sequence=== |
Revision as of 14:13, 3 December 2008
Contents
Application Interconnect Handshake
This sequence of NetMsg exchanges represents the communications between an external application (App M) attempting to connect to a running Geometry Service (App GS). This sequence assumes success.
Main Sequence
- App GS waits for incoming socket requests.
- App M creates a socket connection to App GS.
- App GS accepts the socket connection.
- App M and App GS are now connected at the socket level.
- App M sends a RemHostNameSET NetMsg to App GS.
- App GS checks its RemHostName list for duplicates. (Alt #1)
- App GS sends a RemHostNameSETOK NetMsg to App M.
- App GS sends a RemHostNameSET NetMsg to App M.
- App GS waits for App M to send a RemHostNameSETOK NetMsg.
- App M sends a RemHostNameSETOK NetMsg.
- App M is now connected to the Geometry Service network.
- App M sends a NewSessionREQ NetMsg.
- App GS creates a new Session.
- App GS sends a NewSessionREQOK NetMsg.
Alt Sequence #1
- 6a. App GS finds that the incoming Host is already on the HostList. Either a duplicate name, or a duplicate connection.
- 6b. App GS sends App M a RemHostNameSETFAIL NetMsg.
- 6c. App GS drops socket connection to App M.
- 6d. App M drops socket connection to App GS.
Application Request For Geometry
This sequence of NetMsg exchanges represents the communications between an external application (App M) as it requests Geometry from the Geometry Service (App GS). This sequence assumes success and that both App M and App GS have completed the Application Interconnect Handshake.
Main Sequence
- App M sends a GeometryREQ NetMsg to App GS.
- App GS finds the request Geometry. (Alt #1)
- App GS sends App M a GeometryMANIFEST NetMsg.
- App GS sends App M as many GeometryCHUNK NetMsgs as required in order to fulfill the GeometryMANIFEST.
Alt Sequence #1
- 2a. App GS does NOT find requested Geometry.
- 2b. App GS sends App M a GeometryREQFAIL NetMsg.