fix: add del mark for last cache

This commit is contained in:
Shungang Li 2024-08-05 11:04:29 +08:00
parent 4586e09b7b
commit 3e923f765b
2 changed files with 383 additions and 323 deletions

View File

@ -343,7 +343,6 @@ typedef struct {
rocksdb_readoptions_t *readoptions;
rocksdb_writebatch_t *writebatch;
rocksdb_writebatch_t *rwritebatch;
TdThreadMutex rMutex;
STSchema *pTSchema;
} SRocksCache;
@ -915,12 +914,21 @@ typedef enum {
READER_EXEC_ROWS = 0x2,
} EExecMode;
#define LAST_COL_VERSION (0x1)
#define LAST_COL_VERSION_1 (0x1) // add primary key, version
#define LAST_COL_VERSION_2 (0x2) // add cache status
#define LAST_COL_VERSION LAST_COL_VERSION_2
typedef enum {
TSDB_LAST_CACHE_VALID = 0, // last_cache has valid data
TSDB_LAST_CACHE_EMPTY, // neither last_cache nor tsdb has data
TSDB_LAST_CACHE_NO_CACHE, // last_cache has no data, but tsdb may have data
} ELastCacheStatus;
typedef struct {
SRowKey rowKey;
int8_t dirty;
SColVal colVal;
ELastCacheStatus cacheStatus;
} SLastCol;
typedef struct {

File diff suppressed because it is too large Load Diff