Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

compact: Redesign compaction planning process for cost efficiency and determinism. #3405

Open
bwplotka opened this issue Nov 4, 2020 · 15 comments
Labels
difficulty: hard dont-go-stale Label for important issues which tells the stalebot not to close them feature request/improvement help wanted

Comments

@bwplotka
Copy link
Member

bwplotka commented Nov 4, 2020

Related discussion: https://matrix.to/#/!WaUKIfoqfiyWQhenET:matrix.org/$16044993991172247rFDCZ:matrix.org?via=matrix.org&via=hoffie.info

Problems of the Current Algorithm

  1. The current algorithm is not very efficient for the cost (e.g network bandwidth). For example, if you have blocks laid out as 2h 2h 2h 2h 2h 2h 2h 2h 2h 2h 2h 2h 2h (301 of those in total), our current planning with comp range e.g [2h, 8h, 2d, 25d] will pick the oldest 4x2h to compact 8h and so on, then same for 2d only to at then do a single block of 25d. This means 88 compactions instead of just SINGLE compaction 300x2h blocks into single 25d. Vertical compactions are totally excluded as separate compactions so it's even worse.

  2. It's currently (without locking mechanism) hard to run multiple compactors on a single stream. It would be nice to apply some determinism to allow such compactor sharding across a single stream. This is however lower priority goal.

This is related to #3390

@bwplotka
Copy link
Member Author

bwplotka commented Nov 4, 2020

Potentially blocker as bigger compactions would require more resources: #3406

@stale
Copy link

stale bot commented Jan 4, 2021

Hello 👋 Looks like there was no activity on this issue for the last two months.
Do you mind updating us on the status? Is this still reproducible or needed? If yes, just comment on this PR or push a commit. Thanks! 🤗
If there will be no activity in the next two weeks, this issue will be closed (we can always reopen an issue if we need!). Alternatively, use remind command if you wish to be reminded at some point in future.

@stale stale bot added the stale label Jan 4, 2021
@yeya24
Copy link
Contributor

yeya24 commented Jan 4, 2021

Still valid

@yeya24 yeya24 removed the stale label Jan 4, 2021
@stale
Copy link

stale bot commented Mar 16, 2021

Hello 👋 Looks like there was no activity on this issue for the last two months.
Do you mind updating us on the status? Is this still reproducible or needed? If yes, just comment on this PR or push a commit. Thanks! 🤗
If there will be no activity in the next two weeks, this issue will be closed (we can always reopen an issue if we need!). Alternatively, use remind command if you wish to be reminded at some point in future.

@stale stale bot added the stale label Mar 16, 2021
@bwplotka
Copy link
Member Author

Very valid

@stale
Copy link

stale bot commented Jun 2, 2021

Hello 👋 Looks like there was no activity on this issue for the last two months.
Do you mind updating us on the status? Is this still reproducible or needed? If yes, just comment on this PR or push a commit. Thanks! 🤗
If there will be no activity in the next two weeks, this issue will be closed (we can always reopen an issue if we need!). Alternatively, use remind command if you wish to be reminded at some point in future.

@stale stale bot added the stale label Jun 2, 2021
@stale
Copy link

stale bot commented Jun 16, 2021

Closing for now as promised, let us know if you need this to be reopened! 🤗

@stale stale bot closed this as completed Jun 16, 2021
@yeya24 yeya24 reopened this Oct 12, 2021
@stale
Copy link

stale bot commented Oct 30, 2021

Closing for now as promised, let us know if you need this to be reopened! 🤗

@stale stale bot closed this as completed Oct 30, 2021
@yeya24
Copy link
Contributor

yeya24 commented Oct 30, 2021

Still valid

@stale
Copy link

stale bot commented Jan 9, 2022

Hello 👋 Looks like there was no activity on this issue for the last two months.
Do you mind updating us on the status? Is this still reproducible or needed? If yes, just comment on this PR or push a commit. Thanks! 🤗
If there will be no activity in the next two weeks, this issue will be closed (we can always reopen an issue if we need!). Alternatively, use remind command if you wish to be reminded at some point in future.

@stale stale bot added the stale label Jan 9, 2022
@GiedriusS GiedriusS removed the stale label Jan 10, 2022
@vjabrayilov
Copy link

Hey, dear @yeya24 and @bwplotka. The proposal that I attached to #3406, tries to solve this issue as well. https://drive.google.com/file/d/1oZd3ENSZ7v2hONNf4pDL3yXr_0eHcwsV/view?usp=sharing

Looking forward your feedback.
Best.

@bwplotka
Copy link
Member Author

Sweet, thanks, adding to my Todo list.

@stale
Copy link

stale bot commented Jun 12, 2022

Hello 👋 Looks like there was no activity on this issue for the last two months.
Do you mind updating us on the status? Is this still reproducible or needed? If yes, just comment on this PR or push a commit. Thanks! 🤗
If there will be no activity in the next two weeks, this issue will be closed (we can always reopen an issue if we need!). Alternatively, use remind command if you wish to be reminded at some point in future.

@stale stale bot added the stale label Jun 12, 2022
@douglascamata douglascamata added dont-go-stale Label for important issues which tells the stalebot not to close them and removed stale labels Jan 12, 2024
@Vanshikav123
Copy link
Contributor

Hello ! @bwplotka @yeya24 is this issue still relevant?

@calestyo
Copy link

calestyo commented Mar 11, 2024

Sure it is, I stumbled just few days ago over the same problem, which is why I had reported #7198.

PS: Since #7198 is closed now as a duplicate of this issue here, people my also want to read the symptoms/etc. I've had reported there,... should anyone ever work on this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
difficulty: hard dont-go-stale Label for important issues which tells the stalebot not to close them feature request/improvement help wanted
Projects
None yet
Development

No branches or pull requests

7 participants