-
Notifications
You must be signed in to change notification settings - Fork 175
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
Completely rewrite all core logic using compacting log storage #338
Conversation
Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
815ffb1
to
cf983db
Compare
Goals: - Maximize performance - Simplify logic and code - Lay foundation for future development Key changes: - Store data using compacting log to minimize disk writes - Process incoming copies in O(1), doing the minimal amount of work possible - Fix various other inefficiencies in core logic, bringing time complexity down to O(1) (at the cost of a bit of extra memory sometimes) - Fixed a bug where max preview lengths were off by 2 characters - Move favorited items to top when MOVE_ITEM_FIRST is enabled Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
Because we're using the *_async functions, our I/O ops can reorder themselves. This becomes a problem if, for example, we mark an entry as favorite before actually adding it. Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
…d log ops) Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
Signed-off-by: Alex Saveau <saveau.alexandre@gmail.com>
@SUPERCILEX Could you provide some summary of the improvements of this PR? |
Depending on how things go, these changes will either be part of this repo or I'll publish my own version of clipboard indicator. In either case, I'll make announcements on Reddit and write a blog post about the compacting log, fast hashing, and other optimizations once everything is ready. You can track my progress here if you're interested: https://github.com/SUPERCILEX/gnome-shell-extension-clipboard-indicator/commits/master. The gist of these changes is relatively straightforward: make everything go fast, remove all scaling limitations, make the code more maintainable, and implement useful feature requests where possible. |
@SUPERCILEX please open issues tab on your's fork page. |
Done! |
Also, would you two be willing to do some QA? I can let you know once I'm ready and post instructions here on how to install the updated extension. |
cc @b00f who might be interested, I've seen your name pop up a bunch |
Sure, I've already been using your build for a few days actually! It does feel a little snappier, but there's this interesting lag that still exists when toggling the extension and then hovering over the system menu and back to indicator. This lag existed in the upstream as well but I was wondering if your changes had addressed it. |
Hmmm, not sure what you mean. As in, you put your mouse over the clipboard icon and then move it to the wifi icon? |
Yes, exactly - while the popup is toggled, so switching from the system dropdown (volumne, mic, brightness, etc.) to the clipboard dropdown causes some stuttering as the history loads. |
Ohhhhhh, I think I have a guess for what's going on! We only build the menu UI after loading all the items, and since that takes a while you won't see anything for a bit. Will take a look later and let you know if that's it. |
@jacksongoode the slow start issue should be fixed. 🎉 |
Jesus christ am just seeing this. Can you please tell me what type of coffee you drank to do this much work. Just amazing! |
This has been released in a rewritten version of the extension: https://extensions.gnome.org/extension/4839/clipboard-history/, https://github.com/SUPERCILEX/gnome-clipboard-history.
Here's what's been fixed: