Information Technology Reference
In-Depth Information
This chapter develops the lineage towards the domain-specific aspect lan-
guage (DSAL) approach to distributed systems development by examining previ-
ous approaches, and issues surrounding those approaches.
We begin by discussing the low-level Application Programming Interface
(API) approach as exemplified by BSD sockets. We then discuss the RPC approach
for both procedural languages, in the form of ONC RPC, and object-oriented sys-
tems in the form of CORBA and Java RMI and compare the network awareness
and network transparent models.
We then discuss the high-level API approach as exemplified by JMS and
discuss the effects and implications the different approaches have on ease of devel-
opment, software reusability and maintainability.
Throughout this chapter we use the example of a simple distributed service
that returns the current date.
2.2 Sockets-Based Programming
Sockets are a low-level generalised programming interface for networking and in-
terprocess communication first provided in the BSD4.2 operating system 1 . Most,
if not all, UNIX systems provide the socket API and various operating systems,
such as Windows with its Winsock API, provide similar functionality.
Sockets are a low-level networking API modelled on the UNIX systems calls
related to file I/O semantics. While there is some similarity between file and
network I/O operations, network I/O has other considerations, which make the fit
less than perfect. Stevens [96] identifies the following considerations for network
I/O:
• The client server relationship is not symmetrical. The application needs to
know which role (client or server) it is to assume.
• Network connections can be connectionless or connection-oriented. Connec-
tionless operations do not map neatly to file operations because there is no
concept of opening a connection as every network I/O operation could be to
a different host.
• Names are more important in distributed systems, for example to verify se-
curity, than they are for file operations. Therefore, passing a file descriptor
to a process without knowing the original name, while being acceptable for
a file I/O operation, may not be acceptable for a network I/O operation.
• Additional parameters, for example the protocol and its details, are required
for network operations.
• While the UNIX I/O system is stream-oriented, many network protocols are
message-oriented and therefore rely on message boundaries.
1 Strictly speaking, BSD sockets were initially provided in the 4.1cBSD release and subsequently
refined into their current form in 4.2BSD.
Search WWH ::




Custom Search