Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

core/rawdb: freezer batch write #23462

Merged
merged 2 commits into from Sep 7, 2021
Merged

Commits on Aug 25, 2021

  1. core/rawdb: batched freezer writes

    core/rawdb: improve append benchmark
    
    core/rawdb: add freezer batch
    
    core/rawdb: minor benchmark nitpicks
    
    core/rawdb: add freezer batch
    
    core/rawdb: method docs
    
    core/rawdb: resolve freezer batch filenum at write-time
    
    core/rawdb: use bytes.Buffer in freezer batch
    
    core/rawdb: work in progress -- rlp encoding inside freezer batch
    
    core/rawdb: implement write batchs in freezer
    
    core/rawdb: improve memory allocations for snappy compression
    core/rawdb: polish
    core/rawdb: simplify + fix copy/paste error
    core/rawdb: error handling for freezertable batches
    core/rawdb: lint nitpicks
    core/rawdb: more tests for freezer batching
    
    core/rawdb: freezer batch interface
    
    core/rawdb: WIP freezer batch interface
    core/rawdb: check insert count of table batches
    core/rawdb: use ancient batch in background freeze
    core/rawdb: fix some issues in background freezer
    ethdb: document AncientBatch
    core/rawdb: remove single-item append
    core/rawdb: use dumpIndexString in batch tests
    core/rawdb: fix batch test
    core/rawdb: implement commit during append
    core/rawdb: add some missing close calls in freezer tests
    core/rawdb: simplify snappy buffer
    core/rawdb: change ancient writer interface
    core/rawdb: fix offset test
    core/rawdb: track headBytes only in freezerTable
    core/rawdb: add writeLock
    core/rawdb: reuse write batch
    core/rawdb: re-add metrics reporting
    core/rawdb: recreate the concurrent truncate test of freezer
    
    This changes the test slightly to use the 'freezer' object instead of
    'freezerTable'. This is necessary because the concurrency handling has
    moved to the freezer and concurrent append and truncate is no longer
    allowed on the table object.
    
    core/rawdb: fix item count after ModifyAncients and improve the test
    core/rawdb: add concurrency test for retrieve
    core/rawdb: allow overriding max table size in newFreezer
    
    This makes the concurrency tests fail with -race.
    
    core/rawdb: fix race in advanceFile
    core/rawdb: remove atomic access on freezer.headId
    
    It doesn't need to be atomic, all accesses are protected by the lock.
    
    core/rawdb: use int64 for writeSize
    
    core/rawdb: implement and test all-or-nothing behavior of ModifyAncients
    core/rawdb: move buffer code to batch file
    core/rawdb: reimplement batch test on freezer
    core/rawdb: fix race in AncientSize
    core, core/rawdb: WIP batch ancient write in sync
    core/rawdb: delete old batch tests
    core: fix error handling when inserting side chain receipts
    
    This fixes (well, rewrites) the test for the error case of
    InsertReceiptChain where side chain data is imported and setting the
    fast block fails because it doesn't match the header chain.
    
    This previously relied on the terminateInsert hook. With the new ancient
    write interface, there is no good place for this hook anymore, so the
    test now injects an actual error instead of simulating one.
    
    core: improve comments
    
    core/blockchain, core/rawdb: less iterator usage when deleting leveldb-data
    
    core/rawdb: return write error from WriteAncientBlocks
    
    It's easier to test this function when it doesn't just exit
    the process on failure.
    
    core/rawdb: add benchmark for WriteAncientBlocks
    
    core/rawdb: use os.RemoveAll in test
    
    core/rawdb: avoid allocating in benchmark loop
    
    core/rawdb: avoid copying difficulty twice
    
    The difficulty is already copied by block.Header(), avoid
    copying it again.
    
    core/rawdb: improve WriteAncientBlocks benchmark
    
    core: handle block->header validation
    holiman committed Aug 25, 2021
    Copy the full SHA
    1c473ed View commit details
    Browse the repository at this point in the history
  2. core/rawdb: fix tests

    holiman committed Aug 25, 2021
    Copy the full SHA
    4d4cdf3 View commit details
    Browse the repository at this point in the history