Commit Graph

32 Commits (master)

Author SHA1 Message Date
Vitaliy Filippov c79b38bd26 Move all sources to subdirs
Test / test_snapshot_chain_ec (push) Successful in 2m50s Details
Test / test_rebalance_verify_imm (push) Successful in 3m17s Details
Test / test_root_node (push) Successful in 9s Details
Test / test_rebalance_verify (push) Successful in 4m6s Details
Test / test_switch_primary (push) Successful in 33s Details
Test / test_write (push) Successful in 53s Details
Test / test_write_no_same (push) Successful in 12s Details
Test / test_write_xor (push) Successful in 51s Details
Test / test_rebalance_verify_ec_imm (push) Successful in 3m26s Details
Test / test_rebalance_verify_ec (push) Successful in 4m24s Details
Test / test_heal_pg_size_2 (push) Successful in 5m11s Details
Test / test_heal_ec (push) Successful in 5m8s Details
Test / test_heal_csum_32k_dmj (push) Successful in 5m1s Details
Test / test_heal_csum_32k_dj (push) Successful in 6m0s Details
Test / test_heal_csum_4k_dmj (push) Successful in 7m3s Details
Test / test_heal_csum_32k (push) Successful in 7m6s Details
Test / test_heal_csum_4k_dj (push) Successful in 6m53s Details
Test / test_osd_tags (push) Successful in 28s Details
Test / test_enospc (push) Successful in 1m10s Details
Test / test_enospc_imm (push) Successful in 57s Details
Test / test_enospc_xor (push) Successful in 1m24s Details
Test / test_heal_csum_4k (push) Successful in 6m58s Details
Test / test_scrub_zero_osd_2 (push) Successful in 29s Details
Test / test_scrub (push) Successful in 33s Details
Test / test_scrub_xor (push) Successful in 26s Details
Test / test_enospc_imm_xor (push) Successful in 51s Details
Test / test_nfs (push) Successful in 24s Details
Test / test_scrub_pg_size_6_pg_minsize_4_osd_count_6_ec (push) Successful in 34s Details
Test / test_scrub_ec (push) Successful in 32s Details
Test / test_scrub_pg_size_3 (push) Successful in 39s Details
2024-05-15 11:06:01 +03:00
Vitaliy Filippov 44692d148a Make vitastor_kv.h header public
Test / test_snapshot_chain_ec (push) Successful in 2m47s Details
Test / test_rebalance_verify_imm (push) Successful in 2m42s Details
Test / test_root_node (push) Successful in 9s Details
Test / test_rebalance_verify (push) Successful in 3m21s Details
Test / test_switch_primary (push) Successful in 37s Details
Test / test_write (push) Successful in 46s Details
Test / test_write_no_same (push) Successful in 17s Details
Test / test_write_xor (push) Successful in 49s Details
Test / test_rebalance_verify_ec (push) Successful in 4m51s Details
Test / test_rebalance_verify_ec_imm (push) Successful in 4m31s Details
Test / test_heal_pg_size_2 (push) Successful in 3m36s Details
Test / test_heal_ec (push) Successful in 3m37s Details
Test / test_heal_csum_32k_dmj (push) Successful in 6m7s Details
Test / test_heal_csum_32k_dj (push) Successful in 6m12s Details
Test / test_heal_csum_32k (push) Successful in 7m20s Details
Test / test_heal_csum_4k_dmj (push) Successful in 7m7s Details
Test / test_osd_tags (push) Successful in 19s Details
Test / test_enospc (push) Successful in 1m27s Details
Test / test_enospc_xor (push) Successful in 2m24s Details
Test / test_heal_csum_4k_dj (push) Successful in 5m42s Details
Test / test_enospc_imm (push) Successful in 1m39s Details
Test / test_heal_csum_4k (push) Successful in 6m0s Details
Test / test_scrub_zero_osd_2 (push) Successful in 47s Details
Test / test_scrub (push) Successful in 50s Details
Test / test_enospc_imm_xor (push) Successful in 1m15s Details
Test / test_scrub_xor (push) Successful in 25s Details
Test / test_nfs (push) Successful in 23s Details
Test / test_scrub_ec (push) Successful in 32s Details
Test / test_scrub_pg_size_6_pg_minsize_4_osd_count_6_ec (push) Successful in 35s Details
Test / test_scrub_pg_size_3 (push) Successful in 41s Details
2024-05-15 01:49:38 +03:00
Vitaliy Filippov 266d038b11 Fix 32-bit build warnings and one error again :-)
Test / test_snapshot_chain_ec (push) Successful in 2m52s Details
Test / test_rebalance_verify_imm (push) Successful in 3m7s Details
Test / test_root_node (push) Successful in 8s Details
Test / test_rebalance_verify (push) Successful in 3m36s Details
Test / test_switch_primary (push) Successful in 40s Details
Test / test_write (push) Successful in 41s Details
Test / test_write_no_same (push) Successful in 18s Details
Test / test_write_xor (push) Successful in 1m6s Details
Test / test_rebalance_verify_ec (push) Successful in 4m25s Details
Test / test_rebalance_verify_ec_imm (push) Successful in 3m52s Details
Test / test_heal_pg_size_2 (push) Successful in 3m21s Details
Test / test_heal_ec (push) Successful in 5m27s Details
Test / test_heal_csum_32k_dmj (push) Successful in 5m56s Details
Test / test_heal_csum_32k_dj (push) Successful in 5m49s Details
Test / test_heal_csum_32k (push) Successful in 6m43s Details
Test / test_osd_tags (push) Successful in 21s Details
Test / test_enospc (push) Successful in 2m18s Details
Test / test_heal_csum_4k_dmj (push) Successful in 6m43s Details
Test / test_heal_csum_4k (push) Successful in 6m27s Details
Test / test_heal_csum_4k_dj (push) Successful in 6m29s Details
Test / test_enospc_imm (push) Successful in 1m5s Details
Test / test_enospc_xor (push) Successful in 1m38s Details
Test / test_scrub (push) Successful in 37s Details
Test / test_scrub_zero_osd_2 (push) Successful in 32s Details
Test / test_enospc_imm_xor (push) Successful in 45s Details
Test / test_scrub_xor (push) Successful in 33s Details
Test / test_scrub_pg_size_6_pg_minsize_4_osd_count_6_ec (push) Successful in 34s Details
Test / test_scrub_ec (push) Successful in 34s Details
Test / test_scrub_pg_size_3 (push) Successful in 43s Details
Test / test_nfs (push) Successful in 13s Details
2024-04-11 22:49:33 +03:00
Vitaliy Filippov e42148f347 Allow to specify KV commands on command line 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 0cd455d17f First just recheck version without actually re-reading block in vitastor-kv 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 32ba653ba6 Fix vitastor-kv hang on reopen & unfinished closed listing 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 9dc4d5fd7b Fix freeing r/w buffers on errors in kv_db 2024-03-16 13:24:36 +03:00
Vitaliy Filippov e58538fa47 Fix eviction when random_pos selects the end 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 511bc3df1c Fix and improve parallel allocation
- Do not try to allocate more DB blocks in an inode block until it's "confirmed" and "locked" by the first write
- Do not recheck for new zero DB blocks on first write into an inode block - a CAS failure means someone else is already writing into it
- Throw new allocation blocks away regardless of whether the known_version is 0 on a CAS failure
2024-03-16 13:24:36 +03:00
Vitaliy Filippov ec5f7c6b87 More fixes
- do not overwrite a block with older version if known version is newer
  (read may start before update and end after update)
- invalidated block versions can't be remembered and trusted
- right boundary for split blocks is right_half when diving down, not key_lt
- restart update also when block is "invalidated", not just on version mismatch
- copy callback in listings to avoid closure destruction bugs too
2024-03-16 13:24:36 +03:00
Vitaliy Filippov 3ebed9a749 Add logging and one more assert 2024-03-16 13:24:36 +03:00
Vitaliy Filippov eab67a6e8f Make get_block() wait for updating when unrelated block is found along the path 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 20993d9b7a Fix a race condition where changed blocks were parsed over existing cached blocks and getting a mix of data 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 5cf9b343c0 Simplify code by removing an unneeded "optimisation" 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 79ae0aadcd Add kv_log_level, print warnings on level 1, trace ops on level 10 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 605afc3583 Fix duplicate keys in listings on parallel updates -- do not rewind key "iterator position" 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 763e77b4f4 Do not complain on empty first block 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 1bd8d2da56 Add some more resiliency to serialize() 2024-03-16 13:24:36 +03:00
Vitaliy Filippov a7396d2baf Invalidate blocks being updated too 2024-03-16 13:24:36 +03:00
Vitaliy Filippov e98a38810d Change new block allocation method: make each writer choose multiple empty PG blocks and place blocks in them 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 28c4324c36 Remove blocks from cache on unsuccessful updates 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 31ec3fa8f5 Allow to track multiple updates per block (it should never happen though) 2024-03-16 13:24:36 +03:00
Vitaliy Filippov e4fa26f60a Do not call stop_updating after failed write_new_block and after clear_block (both delete the item) 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 59ae27f9e5 Track versions of parent blocks and recheck if changed during update 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 2c6a301d9b Fix resume_split condition (key_lt can also be "") 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 01558349f8 Experiment: transform offsets for better sharding 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 36f4717d0d More post-stress-test fixes
- Prevent _split types of new blocks
- Stop updating new blocks only after the whole update, otherwise pointers
  may become invalid
- Use recheck_none for updates initially
- Use UINT64_MAX as initial block version when postponing ops, otherwise the
  check fails when the block is initially empty. This for example leads to
  writing both leaf items & block pointers (which is incorrect) into the root
  block when starting stress-test with --parallelism 32
- Fix -EINTR comparison
2024-03-16 13:24:36 +03:00
Vitaliy Filippov 5773f1a375 K/V fixes after stress-test :-)
- track block versions correctly - per inode block (128kb) instead of tree block (4kb)
- prevent multiple parallel CAS writes of the same inode block
- add logging for EILSEQ which means invalid data in the tree
- fix get_block updated flag which was true for blocks already in cache and was leading to infinite loops on "unrelated block" errors
- apply changes to blocks in cache only after successful writes (using "virtual changes")
- do not replace cached block with an older version from disk
- recheck "unrelated blocks" (read/update collisions) until data stops changing
- track tree path correctly - do not treat split block as parent of its right half
- correctly move blocks when finding new empty place on disk
- restart updates from the beginning when one of blocks is changed by a parallel update
- fix delete using SET opcode and setting key to the empty value instead
- prevent changing the same key more than 1 time in parallel
- fix listing verification
- resume continue_updates in update_find (required because it uses continue_update itself)
- add allow_old_cached parameter to get()
2024-03-16 13:24:36 +03:00
Vitaliy Filippov 61ef000c6e Evict blocks based on memory limit & block usage 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 7d5e1cc393 Track blocks per level 2024-03-16 13:24:36 +03:00
Vitaliy Filippov 5e7f27a02d Track block level 2024-03-16 13:24:36 +03:00
Vitaliy Filippov fd1d8a8520 Experimental B-Tree Vitastor embedded K/V database implementation! 2024-03-16 13:24:36 +03:00