fix:seek failed if type is earliest

This commit is contained in:
wangmm0220 2023-07-09 11:34:49 +08:00
parent ae5a7913eb
commit 3ad486e95b
1 changed files with 6 additions and 7 deletions

View File

@ -2709,17 +2709,16 @@ int32_t tmq_get_topic_assignment(tmq_t* tmq, const char* pTopicName, tmq_topic_a
SVgOffsetInfo* pOffsetInfo = &pClientVg->offsetInfo; SVgOffsetInfo* pOffsetInfo = &pClientVg->offsetInfo;
// pOffsetInfo->currentOffset.type = TMQ_OFFSET__LOG; pOffsetInfo->currentOffset.type = TMQ_OFFSET__LOG;
char offsetBuf[TSDB_OFFSET_LEN] = {0};
tFormatOffset(offsetBuf, tListLen(offsetBuf), &pOffsetInfo->currentOffset);
// char offsetBuf[TSDB_OFFSET_LEN] = {0}; tscInfo("vgId:%d offset is update to:%s", p->vgId, offsetBuf);
// tFormatOffset(offsetBuf, tListLen(offsetBuf), &pOffsetInfo->currentOffset);
tscInfo("vgId:%d offset is update to:%"PRId64, p->vgId, p->currentOffset);
pOffsetInfo->walVerBegin = p->begin; pOffsetInfo->walVerBegin = p->begin;
pOffsetInfo->walVerEnd = p->end; pOffsetInfo->walVerEnd = p->end;
// pOffsetInfo->currentOffset.version = p->currentOffset; pOffsetInfo->currentOffset.version = p->currentOffset;
// pOffsetInfo->committedOffset.version = p->currentOffset; pOffsetInfo->committedOffset.version = p->currentOffset;
} }
} }
} }