Accomplishments:
Next: Testing:
Up: MINIREL : Recovery Manager
Previous: Internal Data Structures
The Recovery Manager is dependent on several other subsystems for its
proper functioning. Our implementation of the algorithm would be of little
use if it could not be appropriately tested. We thus had to build
simple prototypes of
all other subsystems we were interacting with - i.e. a Log Manager,
Buffer Manager, Space Manager and the Transaction Manager. We also had to
design a suitable testing tool - preferably one where tests were not hard
coded and one which was easy to manipulate.
The Log and Space Managers are built on top of UNIX files. Our
Buffer Manager is an 'in-memory' data structure which uses the clock
replacement algorithm for page replacement. We also built a
parser that accepts commands to perform various actions on the system.
The parser accepts the following commands:
- T1 tbegin & T1 commit : Begin and Commit transaction T1.
- T1 write <pgid> <offset> <data>
& T1 read <pgid> <offset> : Write to and Read
from a specified page at a specified offset.
- T1 abort : Abort transaction T1.
- tprint & dprint : Print current transaction table, dirty page table.
- pgflush <pgid> & bflush : Flush the
specified page to disk, flush the
buffer pool to disk.
- checkpoint : Take a checkpoint.
- restart & restart_crash <crash point> :
Restart the system , Restart
the system but crash at a specified point.
- crash : Crash the system.
- texit : A clean exit.
The parser's driver executes appropriate routines on recognizing the command.
We simulate multi-process execution by starting several transactions.
Each transaction may be assumed to belong to a different process.
In effect, the input to the system is a low level schedule of database
actions.
The next task was to build the Recovery Manager. As the other subsystems
were ready, our task was limited to getting the algorithm right. To a good
extent the pseudo-code in [MHL+90] helped us with the coding. There were
several changes as we did not implement partial rollbacks or savepoints.
Next: Testing:
Up: MINIREL : Recovery Manager
Previous: Internal Data Structures
ranjani ramamurthy
Sat May 13 16:56:49 CDT 1995