Browse Prior Art Database

Method for Concurrent Write and Read of a Wrap-Around Data Log

IP.com Disclosure Number: IPCOM000118988D
Original Publication Date: 1997-Oct-01
Included in the Prior Art Database: 2005-Apr-01
Document File: 4 page(s) / 115K

Publishing Venue

IBM

Related People

Bennett, RB: AUTHOR [+2]

Abstract

Disclosed is a method for concurrent write and read of a wrap-around data log when there is a single writer and one or more concurrent readers. The serialization needed to support multiple writers to the data log is outside the scope of this current method.

This text was extracted from an ASCII text file.
This is the abbreviated version, containing approximately 52% of the total text.

Method for Concurrent Write and Read of a Wrap-Around Data Log

      Disclosed is a method for concurrent write and read of a
wrap-around data log when there is a single writer and one or more
concurrent readers.  The serialization needed to support multiple
writers to the data log is outside the scope of this current method.

      The structure of the data log is illustrated in Fig. 1.  Then,
the entire data log resides on a persistent storage medium a m blocks
of log records, where each block contains n log records.  The values
of m and n are fixed for a given instance of a data log.  When more
than m*n records (m blocks of n log records) have been written to the
data log, there is a wrap-around condition such that the oldest log
records are replaced by the newest ones.  A block of n log records
exists in memory as a temporary buffer and is written to persistent
storage only when it becomes full.  The data log can only be written
to or read from in a single direction, from oldest to newest log
record.

      When a block of log records is written to persistent storage, a
set of attributes of the data log is also written to persistent
storage and includes the following:
  o  BlockSize: Number of log records accumulated in memory before
      writing them to persistent storage.
  o  MaxLogSize: The maximum number of log records that the data
      log will hold before wrap-around occurs.
  o  CurrentLogSize: The number of log records currently residing
      in the data log.
  o  WrapFlag: Indicates whether a wrap-around has occurred in
      the data log.
  o  CurrentFirstBlockSeqNo: The sequence number of the current
      first block number in the data log.
  o  FirstBlockSlotID: Identifies the location of the first block
      of log records in persistent storage.
  o  LastBlockSlotID: Identifies the location of the last block
      of log records in persistent storage.
  o  BlockSeqNo: Chronological sequence number assigned
      sequentially to each data log block and is recorded
      in the block itself rather than with the persistent
      set of attributes.

      Locking also occurs during the write of the attributes and data
block, so that a consistent view of the data log is maintained at all
times.  The locking scheme that is implemented must be in the scope
of both the reader and writer of the data log.

      In the following example, the number of log records n in a
block equals four and the number of blocks m in the data log equals
five and are identified A through E.  After, writing 28 log...