Please enable JavaScript.
Coggle requires JavaScript to display documents.
Chapter 5 - Data Flow Architecture - Coggle Diagram
Chapter 5 - Data Flow Architecture
5.1 Batch Sequential
What is batch sequential?
Traditional data processing model
Widely used in 1950's - 1970's
RPG and COBOL
are two typical programming languages working on this model.
In batch sequential architecture, each data transformation subsystem or module cannot start its process until its previous subsystem completes its computation
How to implement Batch Sequential?
We can run a Unix Shell script as follows in batch sequential mode:
myShel1.sh
(exec) searching kwd < inputFile > matchedFile
(exec) counting < matchedFile > countedFile
(exec) sorting < countedFile > myReportFile
Where (exec) may be required by some Unix shell
Applicable domains of batch sequential architecture:
Intermediate file is a sequential access file.
Each subsystem reads related input files and writes output files.
Data are batched.
Benefits
Simple divisions on subsystems
Each subsystem can be a stand-alone program working on input
data and producing output data
Limitations
Implementation requires external control.
High latency
Concurrency is not supported and hence throughput remains low
It does not provide interactive interface
Process Control Architecture
suitable for the embedded system software design
Composed of
Sub-systems
2 Types of Sub-systems
controller unit
executor processor unit
Connectors
Process control data
Controlled variable: target controlled variable. It as a set point goal to reach
Manipulated variable: can be adjusted by the controller
Input variable: measured input data
Applicable domains of process control architecture
The system can have a set point—the goal the system will reach at its operational level.
Systems that need to maintain an output data at a stable level
Embedded software systems involving continuing actions
Benefit
Offers a better solution to the control system where no precise
formula can be used to decide the manipulated variable.
The software can be completely embedded in the devices
Limitation
Requires more sensors to monitor system states
5.2 Pipe and Filter Architecture
Pipe and filter architecture is another type of data flow architecture where the flow is driven by data
Compare with Batch Sequential
Similar
Independent Module
Data Connector
Difference
Connectors are stream oriented
Concurrent processing
Data flow method
Pull only (Read only)
A data sink may pull data from an upstream
Filter may pull data from an upstream
Pull/Push (Read/Write)
A filter may pull data from an upstream and push transformed data in a downstream
Push only (Write only)
A data source may push data in a downstream.
.
A filter may push data in a downstream
Classification of Filters
Active Filter
pulls in data and push out the transformed data (pull/push)
It works with a passive pipe that provides read/write mechanisms for pulling and pushing.
Passive Filter
Lets connected pipe to push data in and pull data out.
The filter must provide read/write mechanisms in this case.
Applicable Design Domain
System can be broken into a series of processing steps over data stream, in each step filter consumes and moves data incrementally.
There are significant work which can be pipelined to gain the performance
Data format on the data stream is simple and stable, and easy to be adapted if it is necessary.
Suitable for producer/consumer model
Limitation
Not suitable for dynamic interactions
Overhead of data transformation among filters such as parsing is repeated in two consecutive filters
■ A low common denominator is required for data transmission in the ASCII formats since filters may need to handle data streams in different formats
Advantages
Concurrency: It provides high overall throughput for excessive data processing.
Reusability: is easy – plug and play
Modifiability: Low due to coupling between filters
Simplicity: Clear
Flexibility: High, very modular design
Pipe & Filter In Unix
The pipe operator "|" moves the stdout from its predecessor to the stdin of its successor
Pipe & Filter Arch. in UML
one pipe class may connect to three other classes. They are data source, filter, and data sink.
Pipe & Filter in Java
The Java API provides the Pi(pedWriter) and Pi(pedReader) classes in the java.io package