Commit Graph

220 Commits

Author SHA1 Message Date
armink 12f3960307 [kvdb] Fix testcase error from #251 2023-10-16 21:25:01 +08:00
Lyon 7b2557f3e7
[kvdb] interrupt iteraotor when read_section_info fails (#251)
* interrupt iteraotor when read_section_info failed

* Update src/fdb_kvdb.c

Co-authored-by: 朱天龙 (Armink) <armink.ztl@gmail.com>

* Update src/fdb_kvdb.c

Co-authored-by: 朱天龙 (Armink) <armink.ztl@gmail.com>

---------

Co-authored-by: 朱天龙 (Armink) <armink.ztl@gmail.com>
2023-10-16 09:06:35 +08:00
armink deae3d1d3f [fdb] Fixed build error. 2023-10-15 15:00:10 +08:00
armink c02f3f8573 [fdb] Update the fdb file mode log. 2023-10-15 14:31:38 +08:00
armink 1c68317574 [tsdb] Improve fdb_tsl_query_count return value. Delete the tsl_append assert check. 2023-10-15 11:49:37 +08:00
armink ab4c69f302 [fdb] Improve the fdb_kv_iterate. Only crc check OK kv will be iterated. 2023-10-15 11:46:28 +08:00
armink 5a8d7d0842 [fdb] Remove sector continuous mode assert check. It may trigger accidentally when db meta info has an error. 2023-10-15 11:36:50 +08:00
armink 1d2fc750f9 [kvdb] update the log 2023-10-15 11:24:56 +08:00
armink c8dd4ebe63 [kvdb] Fixed an issue where KVDB may not be able to automatically recover under extreme circumstances 2023-10-15 11:22:13 +08:00
BecauseItIsThere 09fa698f95
[fdb] Relocate `#include<unistd.h>` (fixed #248) 2023-10-12 17:51:19 +08:00
朱天龙 (Armink) 530cffcab1
Merge pull request #247 from guoweilkd/master
fix db_lock()/db_unlock() not calling in pairs
2023-10-12 13:03:05 +08:00
guoweilkd 4aa2dbc6a4 fix FDB_ALIGN macro expansion errors 2023-10-12 11:01:02 +08:00
guoweilkd d2cae60cff fix db_lock()/db_unlock() not calling in pairs 2023-10-12 10:51:39 +08:00
fzi-haxel 56b658e522
[fdb]Replaced `~0UL` in max value checks (#243)
The actual value of `~0UL` is architecture dependent. The `unsigned long` type must be at least 32 bits, but can be larger.
Especially on 64-bit systems, `unsigned long` usually is 64 bits long, for which `~0UL` will result in `0xFFFFFFFFFFFFFFFF` instead of `0xFFFFFFFF`.
If this is the case, comparisons like `kv->len == ~0UL`, where `kv->len` is of type `uint32_t`, are always false.
This commit replaces `~0UL` with the appropriate max value defines from stdint.h.
2023-10-06 14:35:55 +08:00
DarryZh 3e441f6c26
[inc/fdb_low_lvl] fix An error occurred in FDB_ALIGN(size, align) when align is not 2 to the nth power (#233) 2023-08-17 18:01:48 +08:00
benpicco fab8a16180
[fdb] add missing assert.h include (#229) 2023-08-09 21:46:10 +08:00
benpicco a4e68ae965
[fdb] use native assert if FDB_USING_NATIVE_ASSERT is set (#228) 2023-08-09 19:55:20 +08:00
benpicco d01c0d48aa
[port/fal] add option to use native assert() (#225) 2023-08-08 10:36:07 +08:00
benpicco 07dcd7f035
[fdb] fix comparison of integer expressions of different signedness (#226) 2023-08-08 10:34:54 +08:00
grape-wzy cc1c6f4d9f
[kvdb] update _fdb_kv_load(fdb_kvdb_t db) (#219)
remove function declaration in fdb_low_lvl.h;
add static qualifier in fdb_kvdb.c
2023-06-10 13:30:15 +08:00
PostmanLinux 89796605c7
[kvdb] improve kvdb cache algo when key was first found (#218) 2023-06-05 22:53:41 +08:00
朱天龙 (Armink) 4e56774082 [fdb] add db path info for logs 2023-05-28 19:03:26 +08:00
朱天龙 (Armink) 8608140d88 [fdb] check some read error for file mode 2023-05-28 19:02:04 +08:00
朱天龙 (Armink) 55fd31eeb3 [fdb] update FDB_SECTOR_CACHE_TABLE_SIZE to 8 2023-05-28 19:01:06 +08:00
朱天龙 (Armink) 7451fbbdbe [tsdb] fix testcase heap-use-after-free error 2023-05-20 21:12:24 +08:00
朱天龙 (Armink) 9275b44f46 [kvdb] fix testcase build warning 2023-05-20 09:40:06 +08:00
朱天龙 (Armink) ec95540ebc [tsdb] update testcase only using file mode 2023-05-19 23:03:34 +08:00
朱天龙 (Armink) dab9d2bba9 [kvdb] add db size scale up testcase 2023-05-19 21:58:02 +08:00
朱天龙 (Armink) 3c80fa5679 [kvdb] add align padding for 64bit write granularity mode 2023-05-16 09:50:17 +08:00
朱天龙 (Armink) 53de94f82c [fdb] update the version number to 2.0.0 2023-05-14 22:00:41 +08:00
朱天龙 (Armink) a035ea3b2c [fdb] change some assert to error logs 2023-05-14 21:20:30 +08:00
朱天龙 (Armink) dbf5a58fa1 [kvdb] fixed the memory read out of bounds error 2023-05-14 18:31:10 +08:00
朱天龙 (Armink) 5c5eff8d2b [testcase] update the kvdb testcase 2023-05-07 21:26:55 +08:00
朱天龙 (Armink) 6e3ebdc056 [kvdb] fix kvdb memory access error when FDB_WRITE_GRAN is 64 2023-05-07 21:25:59 +08:00
朱天龙 (Armink) 8f009ec057 [doc] fix the badge in the doc 2023-04-30 11:30:19 +08:00
朱天龙 (Armink) 37e0597803 [kvdb] fix testcase running error on ci env 2023-04-30 11:28:35 +08:00
朱天龙 (Armink) d3eaa54ccc [kvdb] fix testcase build error. 2023-04-30 00:01:31 +08:00
朱天龙 (Armink) aa3a194527 [kvdb][testcase] improve the kvdb testcase for GC 2023-04-29 23:52:00 +08:00
朱天龙 (Armink) 63fe2961c4 [kvdb] Improve the oldest sector search method. 2023-04-29 23:49:37 +08:00
朱天龙 (Armink) cc5d665bbc [kvdb] fix kvdb iterate bug after set default. 2023-04-29 21:06:16 +08:00
朱天龙 (Armink) c829b3d8e2 [kvdb] fix #211 , fdb kv iterate from the oldest sector. 2023-04-29 16:11:35 +08:00
朱天龙 (Armink) 6e8e9e7780 [tsdb] the tsl will drop when cur timestamp is equal to the last save timestamp 2023-04-22 10:00:10 +08:00
朱天龙 (Armink) 7fd3db6740 [fdb] move the db oldest_addr definition into `struct fdb_db`. 2023-04-21 23:58:27 +08:00
朱天龙 (Armink) 04a3f475e2 [kvdb] update the code format. 2023-04-21 22:21:26 +08:00
朱天龙 (Armink) e9aa6cd9fa Merge remote-tracking branch 'remotes/origin/partial_gc' 2023-04-21 22:11:39 +08:00
朱天龙 (Armink) dfd25b3b04 [ci] remove travis 2023-04-21 10:30:52 +00:00
朱天龙 (Armink) 7e38f8ca6f
Update main.yml 2023-04-21 17:52:25 +08:00
朱天龙 (Armink) 94b94eb675
Update main.yml 2023-04-21 17:49:20 +08:00
朱天龙 (Armink) fcff17f53d
[ci] add github action 2023-04-21 17:42:09 +08:00
shihang-zhang e008c1a281
[kvdb] update the sector iterator by startswith the oldest sector (#206)
Co-authored-by: shihang.zhang <shihang.zhang.ext@siemens.com>
2023-04-21 14:47:48 +08:00