Skip to content

use IDisk's interfaces to operate filesystem in Keeper - #45884

Closed
LiuYangkuan wants to merge 1 commit into
ClickHouse:masterfrom
LiuYangkuan:keeper_use_disk_do_IO
Closed

LiuYangkuan wants to merge 1 commit into
ClickHouse:masterfrom
LiuYangkuan:keeper_use_disk_do_IO

Conversation

@LiuYangkuan

Copy link
Copy Markdown
Contributor

Changelog category (leave one):

  • Improvement

Changelog entry (a user-readable short description of the changes that goes to CHANGELOG.md):

Replacing std::filesystem operations with DiskPtr APIs, because IDisk is filesystem abstraction.
This way can make keeper to store logs and snapshots into more types of Disk.

Information about CI checks: https://clickhouse.com/docs/en/development/continuous-integration/

@antonio2368 antonio2368 self-assigned this Feb 1, 2023
@LiuYangkuan
LiuYangkuan force-pushed the keeper_use_disk_do_IO branch from f6188ae to f73d67b Compare February 1, 2023 13:22
@robot-clickhouse robot-clickhouse added the pr-improvement Pull request with some product improvements label Feb 1, 2023
@LiuYangkuan
LiuYangkuan force-pushed the keeper_use_disk_do_IO branch from f73d67b to 5d35cf5 Compare February 1, 2023 13:58
@antonio2368 antonio2368 added the can be tested Allows running workflows for external contributors label Feb 1, 2023
@LiuYangkuan LiuYangkuan changed the title use IDisk's interfaces to operate filesystem in Keeper [WIP] use IDisk's interfaces to operate filesystem in Keeper Feb 1, 2023
@LiuYangkuan
LiuYangkuan force-pushed the keeper_use_disk_do_IO branch from 5d35cf5 to 9a2acd7 Compare February 2, 2023 01:02
@LiuYangkuan LiuYangkuan changed the title [WIP] use IDisk's interfaces to operate filesystem in Keeper use IDisk's interfaces to operate filesystem in Keeper Feb 2, 2023
@LiuYangkuan
LiuYangkuan force-pushed the keeper_use_disk_do_IO branch from eca483c to c82c097 Compare February 2, 2023 01:18
@LiuYangkuan

Copy link
Copy Markdown
Contributor Author

@antonio2368 ready to review.

@LiuYangkuan
LiuYangkuan force-pushed the keeper_use_disk_do_IO branch 7 times, most recently from 99e8b39 to 0062a7a Compare February 2, 2023 11:46
@LiuYangkuan
LiuYangkuan force-pushed the keeper_use_disk_do_IO branch from 0062a7a to f29700b Compare February 2, 2023 11:47
@LiuYangkuan

Copy link
Copy Markdown
Contributor Author

@antonio2368 It breaks when build clickhouse-keeper target, "undefined symbol of DiskLocal". I have try to link libdbmsd.a, but don't works. how can I fix it?

@antonio2368

Copy link
Copy Markdown
Member

@antonio2368 It breaks when build clickhouse-keeper target, "undefined symbol of DiskLocal". I have try to link libdbmsd.a, but don't works. how can I fix it?

It happens when standalone build is done (to test locally call cmake -DBUILD_STANDALONE_KEEPER=ON)
Inside programs/keeper/CMakeLists.txt you will see part that defines manually all the necessary source files required for build and add what's missing.
You should NOT link with libdbms we don't want to pull entire ClickHouse into standalone build.
Also, if you end up including too much we have to see if we can minimize it by extracting parts of code in a more clever way or simply put this on hold.

@LiuYangkuan

LiuYangkuan commented Feb 3, 2023 •

Copy link
Copy Markdown
Contributor Author

Also, if you end up including too much we have to see if we can minimize it by extracting parts of code in a more clever way or simply put this on hold.

It seems difficult to resolve circle dependancies, because src/Disks is a high level component.

@antonio2368 antonio2368 mentioned this pull request May 22, 2023
4 tasks done
@LiuYangkuan LiuYangkuan reopened this May 24, 2023
@alexey-milovidov

Copy link
Copy Markdown
Member

Will be merged in #50098.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

can be tested Allows running workflows for external contributors pr-improvement Pull request with some product improvements

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants