Uploaded image for project: 'Ignite'
  1. Ignite
  2. IGNITE-8057

Execute WAL fsync preventively before checkpoint begin

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 2.5
    • None
    • None
    • None

    Description

      After fix of IGNITE-7754, we execute explicit WAL fsync on checkpoint begin:

      if (hasPages) {
          assert cpPtr != null;
      
          tracker.onWalCpRecordFsyncStart();
      
          // Sync log outside the checkpoint write lock.
          cctx.wal().flush(cpPtr, true);
      
          tracker.onWalCpRecordFsyncEnd();
      

      It's executed outside of checkpoint write lock. However, it still can decrease overall throughput by suspending writing of dirty pages by checkpoint threads.
      We can decrease time of this fsync by executing it preventively, before acquiring checkpoint write lock.
      We should prioritize this ticket if value of walCpRecordFsyncDuration metric in "Checkpoint started" message will be too big.
      Note: it's possible to give a fsync hint to WAL manager in single-writer mode.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              ivan.glukos Ivan Rakov
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: