Page 180 -
P. 180
6.3 Architectural patterns 163
Issue
Receipts Receipts
Read Issued Identify
Invoices Payments
Find Payments Issue Payment Reminders
Due Reminder
Invoices Payments
Figure 6.13 An client program is simply an integrated user interface, constructed using a web
example of the pipe browser, to access these services.
and filter architecture
The most important advantage of the client–server model is that it is a distributed
architecture. Effective use can be made of networked systems with many distributed
processors. It is easy to add a new server and integrate it with the rest of the system
or to upgrade servers transparently without affecting other parts of the system.
I discuss distributed architectures, including client–server architectures and distrib-
uted object architectures, in Chapter 18.
6.3.4 Pipe and filter architecture
My final example of an architectural pattern is the pipe and filter pattern. This is a
model of the run-time organization of a system where functional transformations
process their inputs and produce outputs. Data flows from one to another and is trans-
formed as it moves through the sequence. Each processing step is implemented as a
transform. Input data flows through these transforms until converted to output. The
transformations may execute sequentially or in parallel. The data can be processed by
each transform item by item or in a single batch.
The name ‘pipe and filter’ comes from the original Unix system where it was pos-
sible to link processes using ‘pipes’. These passed a text stream from one process to
another. Systems that conform to this model can be implemented by combining Unix
commands, using pipes and the control facilities of the Unix shell. The term ‘filter’
is used because a transformation ‘filters out’ the data it can process from its input
data stream.
Variants of this pattern have been in use since computers were first used for auto-
matic data processing. When transformations are sequential with data processed in
batches, this pipe and filter architectural model becomes a batch sequential model, a
common architecture for data processing systems (e.g., a billing system). The archi-
tecture of an embedded system may also be organized as a process pipeline, with
each process executing concurrently. I discuss the use of this pattern in embedded
systems in Chapter 20.
An example of this type of system architecture, used in a batch processing appli-
cation, is shown in Figure 6.13. An organization has issued invoices to customers.
Once a week, payments that have been made are reconciled with the invoices. For