Skip to content

tracking issue for implementing compact-log-backup in tikv-ctl #17283

@YuJuncen

Description

@YuJuncen

Development Task

The current pitr is pretty slow due to there are too many small files, also putting files via raft protocol make us suffer from write amplification.

If we can merge files as SST, it will be possible to get rid of the problems above.

Tracking of tasks

Can be merge without kvproto change:

This modification includes all modifications applies to the external storage. Including:

  • Add the iter_prefix method to external storage.
  • Add the lock method to external storage. This is used to control concurrent accessing the external storage.
  • Allow finished in memory SstWriters can be reopened.

Waiting kvproto changes:

This will provide a library that can be used to compact logs.
The library exposes a structure named Execution for caller. The Execution contains the core things of a compaction:

  • Collect files from backup data.
  • Generate compaction works.
  • Execute the compaction works.

The Execution can be extended by adding Hooks to it.
The hooks includes:

  • Saving the metadata of compaction.
  • Locking the Storage.
  • Print the logs.
  • etc..

This will provide an entrance for the function.

Metadata

Metadata

Assignees

No one assigned

    Labels

    affects-8.5This bug affects the 8.5.x(LTS) versions.component/backup-restoreComponent: backup, import, external_storagetype/enhancementThe issue or PR belongs to an enhancement.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions