Saving internal program data for further use is one of the most useful ideas in programming. Developing general features to provide such data saving/restoring is a very active research area. There are two application areas for such features we believe to be crucial: system fault tolerance and data persistence. Our analysis shows that the features used in these areas have a lot in common: they are to flatten data of different types and save them in a store which can be used later on. The recent revision of the Ada language standard, Ada 95, introduces a new mechanism called streams that allows structured data to be flattened. Streams are sequences of elements comprising values from possibly different types. Ada 95 allows programmers to develop their streams following the standard abstract class interface. In this paper we show how to use the stream concept for developing new features to provide internal program data saving suitable for fault tolerance and persistence. A hierarchy of different storage types, useful in different application domains, is introduced. The standard stream interface is extended, making it possible for programmers to have a better control of the way streams work by separating storage medium control from the actual stream type using the design patterns. The convenience of this new interface is demonstrated by developing a generic package allowing any non-limited object to be written into a storage device. It can be used for providing data persistence and as a state restoration feature in schemes used for tolerating software design faults.
[1]
Laurent Pautet,et al.
Inside the Distributed Systems Annex
,
1998,
Ada-Europe.
[2]
Hermann Kopetz,et al.
Fault tolerance, principles and practice
,
1990
.
[3]
Laurent Pautet,et al.
Providing fault-tolerant services to distributed Ada 95 applications
,
1996,
TRI-Ada '96.
[4]
Michael J. Oudshoorn,et al.
Orthogonal persistence and Ada
,
1994,
TRI-Ada '94.
[5]
Michael J. Oudshoorn,et al.
Beyond Ada 95: The Addition of Persistence and Its Consequences
,
1996,
Ada-Europe.
[6]
Dirk Riehle,et al.
Pattern Languages of Program Design 3
,
1997
.
[7]
Ronald Morrison,et al.
An Approach to Persistent Programming
,
1989,
Comput. J..
[8]
Brian Randell,et al.
System structure for software fault tolerance
,
1975,
IEEE Transactions on Software Engineering.
[9]
Peter Buneman,et al.
Types and persistence in database programming languages
,
1987,
CSUR.
[10]
Butler W. Lampson,et al.
Crash Recovery in a Distributed Data Storage System
,
1981
.
[11]
Andreas Reuter,et al.
Transaction Processing: Concepts and Techniques
,
1992
.
[12]
Jörg Kienzle,et al.
Shared Recoverable Objects
,
1999,
Ada-Europe.