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

Add Database.Redis.Schema.RemoteJob #8

Merged
merged 5 commits into from
Jul 15, 2024
Merged

Add Database.Redis.Schema.RemoteJob #8

merged 5 commits into from
Jul 15, 2024

Conversation

jbransen
Copy link
Contributor

This adds the implementation and documentation of the Database.Redis.Schema.RemoteJob module, which allows distributed job scheduling. I believe it might be useful outside of Chordify, and judging from the readme it has always been the intention to open-source it.

For those that work at Chordify: there are some small differences to the internal implementation, because Data.OneOf is not public. For runRemoteJob I added the FindHandler class to find the index in the type-level list, and I have decided to exclude inspectQueue and inspectRunningJobs for now because I did not see an easy way of implementing that without Data.OneOf.

Copy link
Collaborator

@matus-chordify matus-chordify left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you! I've just got some cosmetic remarks. Some of them (like naming things) may not actually even be your "fault" but I've included them, anyway.

I haven't read the algorithm too closely, as I know it's been tested quite a bit.

README.md Outdated Show resolved Hide resolved
README.md Show resolved Hide resolved
src/Database/Redis/Schema/RemoteJob.hs Outdated Show resolved Hide resolved
src/Database/Redis/Schema/RemoteJob.hs Show resolved Hide resolved
@isomorpheme isomorpheme merged commit fad7520 into master Jul 15, 2024
12 checks passed
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.

3 participants