[ <- Previous Page ] [ ^ Table Of Contents ^ ] [ Next Page -> ]
Client/Server Communication Primer

Chapter 6
Client/Server Communication Primer

This short chapter descripes client server communication as it relates to zWebit and the interface communications programs in general.

In addition to other protocols, zWebit interface programs utilize the industry standard TCP/IP Communications client/server model. Interface programs that can receive data are typically server programs. Interface programs that send data are typically client programs. Server programs must be active before a client program can connect to it and send data.

There are many excellent books which delve into the intracacies of network programming, TCP/IP, and socket communications (recommendation: Unix systems Programming for SVR4 by David A. Curry). It is beyond the scope of this work to fully describe networking concepts.

The following table identifies the order of function calls used by client/server programs. In general, communication between a server program and a client program is performed in the following order.

DescriptionServer Function CallClient Function Call
Create a socket socket ( )socket ( )
Bind socket to address bind ( )
Listen for connection listen ( )
Connect to server connect ( )
Accept connection accept ( )
Process loop
*Send data send ( )
*Receive data recv ( )
*Send ACK send ( )
*Receive ACK recv ( )
Close connection close ( )
Close socket close ( )close ( )

* Note receive data, send data, send ACK and receive ACK are all subsidiary processes of the "Process loop."

[ <- Previous Page ] [ ^ Table Of Contents ^ ] [ ^ Top Of Page ^ ] [ Next Page -> ]

Visit the GNU home page.

FSF & GNU inquiries & questions to gnu@gnu.org.

Comments on these web pages to info@zhsac.com.

Copyright (C) 2003 HealthCare Systems and Consulting

Verbatim copying and distribution of this entire article is permitted in any medium, provided this notice is preserved.

Last updated: 07/21/2003