Class TermGapFiller

java.lang.Object
io.aeron.logbuffer.TermGapFiller

public class TermGapFiller extends Object
Fills a gap in a term with a padding record.
  • Constructor Details

    • TermGapFiller

      public TermGapFiller()
  • Method Details

    • tryFillGap

      public static boolean tryFillGap(UnsafeBuffer logMetaDataBuffer, UnsafeBuffer termBuffer, int termId, int gapOffset, int gapLength)
      Try to gap fill the current term at a given offset if the gap contains no data.

      Note: the gap offset plus gap length must end on a FrameDescriptor.FRAME_ALIGNMENT boundary.

      Parameters:
      logMetaDataBuffer - containing the default headers
      termBuffer - to gap fill
      termId - for the current term.
      gapOffset - to fill from
      gapLength - to length of the gap.
      Returns:
      true if the gap has been filled with a padding record or false if data found.