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

Emit sorted dir-diff result as soon as preceding results get ready #603

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

yuja
Copy link
Contributor

@yuja yuja commented Dec 8, 2023

If the directory diff contains lots of changes across files, it's better to
emit earlier results incrementally.

The idea is borrowed from the following thread. The diff producer assigns
incremental index, and the consumer puts the results in BinaryHeap to reorder
them by index.
https://users.rust-lang.org/t/parallel-work-collected-sequentially/13504/3

@yuja yuja force-pushed the push-nprqmzptuyvz branch 2 times, most recently from f3bcd71 to 4d2f683 Compare January 6, 2024 00:38
@yuja yuja force-pushed the push-nprqmzptuyvz branch 2 times, most recently from 9313712 to 19fd6e2 Compare February 25, 2024 10:10
@yuja yuja force-pushed the push-nprqmzptuyvz branch 2 times, most recently from 17e2647 to e482293 Compare March 6, 2024 13:18
@yuja yuja force-pushed the push-nprqmzptuyvz branch 2 times, most recently from d775351 to 2ee8cc0 Compare April 2, 2024 13:09
@yuja yuja force-pushed the push-nprqmzptuyvz branch 2 times, most recently from 12edce3 to bd2e3d0 Compare May 17, 2024 11:48
@yuja yuja force-pushed the push-nprqmzptuyvz branch 2 times, most recently from a467b45 to f853e36 Compare July 24, 2024 09:24
This ensures that the json output is also sorted.
If the directory diff contains lots of changes across files, it's better to
emit earlier results incrementally.

The idea is borrowed from the following thread. The diff producer assigns
incremental index, and the consumer puts the results in BinaryHeap to reorder
them by index.
https://users.rust-lang.org/t/parallel-work-collected-sequentially/13504/3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant