[TD-4556]add compact flag in STsdbRepo

This commit is contained in:
lichuang 2021-06-07 10:55:35 +08:00
parent efa03cb0f4
commit e2831b4833
2 changed files with 2 additions and 0 deletions

View File

@ -92,6 +92,7 @@ struct STsdbRepo {
pthread_mutex_t mutex;
bool repoLocked;
int32_t code; // Commit code
bool inCompact; // is in compact process?
};
#define REPO_ID(r) (r)->config.tsdbId

View File

@ -533,6 +533,7 @@ static STsdbRepo *tsdbNewRepo(STsdbCfg *pCfg, STsdbAppH *pAppH) {
pRepo->state = TSDB_STATE_OK;
pRepo->code = TSDB_CODE_SUCCESS;
pRepo->inCompact = false;
pRepo->config = *pCfg;
if (pAppH) {
pRepo->appH = *pAppH;