• unknown's avatar
    - moving pagecache.h from include/ to storage/maria as it is Maria- · f159c6cf
    unknown authored
    specific
    - adding TRN::first_undo_lsn, needed to know when a log can be deleted;
    this variable must be set under log's mutex and that leads to setting
    TRN::rec_lsn, TRN::undo_lsn and TRN::first_undo_lsn in a
    inwrite_rec_hook; adding implementation of one hook for REDOs and one
    for UNDOs. Thus translog_write_record() always uses TRN and so does
    not need a short_id argument, can find it from TRN.
    - Monty's patch for the last Valgrind error in the tree.
    - Log handler's unit tests fail but Sanja says it's known
    
    
    include/Makefile.am:
      pagecache.h moved and renamed
    include/maria.h:
      pagecache.h moved and renamed
    sql/handler.h:
      pagecache.h moved and renamed
    storage/maria/Makefile.am:
      pagecache.h moved and renamed
    storage/maria/ha_maria.cc:
      adding an assertion which sounds logical
    storage/maria/ma_blockrec.c:
      trn->rec_lsn and trn->undo_lsn are now set via hooks inside the log
      record's writing; this allows to also set trn->first_undo_lsn
      needed to compute the log's low-water mark.
      The PAGERANGE_STORE_SIZE -> PAGE_STORE_SIZE is Monty's fix to a
      Valgrind error.
    storage/maria/ma_loghandler.c:
      "tcb" renamed to "trn". Log handler now knows what is a transaction,
      and finds short_id from trn. trn's rec_lsn, undo_lsn, first_undo_lsn
      are now set by some inwrite_rec_hookS (one for REDOs, one for UNDOs).
      The HAVE_purify blocks are Monty's fix to a Valgrind error.
    storage/maria/ma_loghandler.h:
      Log handler functions use TRN, that needs a forward declaration
    storage/maria/ma_pagecache.c:
      pagecache.h was moved and renamed
    storage/maria/ma_pagecache.h:
      pagecache.h was moved and renamed
    storage/maria/ma_pagecaches.c:
      pagecache.h was moved and renamed
    storage/maria/trnman.c:
      initializing some members of TRN.
    storage/maria/trnman.h:
      TRN::first_undo_lsn needed for log's low-water mark calculation
      (which will serve to know which logs can be deleted)
    storage/maria/unittest/ma_test_loghandler-t.c:
      translog_write_record() now needs a valid TRN
    storage/maria/unittest/ma_test_loghandler_multigroup-t.c:
      translog_write_record() now needs a valid TRN
    storage/maria/unittest/ma_test_loghandler_multithread-t.c:
      translog_write_record() now needs a valid TRN
    storage/maria/unittest/ma_test_loghandler_pagecache-t.c:
      translog_write_record() now needs a valid TRN
    storage/maria/unittest/test_file.h:
      pagecache.h was moved and renamed
    f159c6cf
test_file.h 276 Bytes