mirror of
https://github.com/GreptimeTeam/greptimedb.git
synced 2026-05-20 06:50:37 +00:00
feat(log_store): introduce the CollectionTask (#4530)
* feat: introduce the `CollectionTask` * feat: add config of index collector * chore: remove unused code * feat: truncate indexes * chore: apply suggestions from CR * chore: update config examples * refactor: retrieve latest offset while dumping indexes * chore: print warn
This commit is contained in:
@@ -89,7 +89,7 @@ impl<S: LogStore> Wal<S> {
|
||||
move |region_id, last_entry_id, provider| -> BoxFuture<'_, Result<()>> {
|
||||
Box::pin(async move {
|
||||
store
|
||||
.obsolete(provider, last_entry_id)
|
||||
.obsolete(provider, region_id, last_entry_id)
|
||||
.await
|
||||
.map_err(BoxedError::new)
|
||||
.context(DeleteWalSnafu { region_id })
|
||||
@@ -142,7 +142,7 @@ impl<S: LogStore> Wal<S> {
|
||||
provider: &Provider,
|
||||
) -> Result<()> {
|
||||
self.store
|
||||
.obsolete(provider, last_id)
|
||||
.obsolete(provider, region_id, last_id)
|
||||
.await
|
||||
.map_err(BoxedError::new)
|
||||
.context(DeleteWalSnafu { region_id })
|
||||
|
||||
@@ -168,6 +168,7 @@ mod tests {
|
||||
async fn obsolete(
|
||||
&self,
|
||||
_provider: &Provider,
|
||||
_region_id: RegionId,
|
||||
_entry_id: EntryId,
|
||||
) -> Result<(), Self::Error> {
|
||||
unreachable!()
|
||||
|
||||
Reference in New Issue
Block a user