-
-
Notifications
You must be signed in to change notification settings - Fork 11
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
[#45] Add async worker for synchronizing database #132
base: main
Are you sure you want to change the base?
Conversation
f780d67
to
c36be34
Compare
repos <- searchAllHaskellRepos today interval | ||
log I "Upserting repositories into the database..." |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Logging is very useful in this function! And we definitely should have it. It's just unfortunate that because of calls to logging functions the code becomes less readable and all steps are not apparent immediately... It's an open question, how to improve the situation though. But at least, these logging messages serve as a good documentation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@chshersh Yes, I agree. I thought the same, but I think it’s definitely worth it. This was my first time using any logging library in Haskell, but I really enjoyed how easy and straightforward it is to use. Very user friendly.
c36be34
to
09ae6a5
Compare
syncCache interval = forever $ syncWithGithub interval `catchError` syncErrHandler | ||
where | ||
syncErrHandler :: AppErrorType -> m a | ||
syncErrHandler = undefined |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will think about the problem 🤔
Resolves #45