-
-
Notifications
You must be signed in to change notification settings - Fork 94
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
Implementation of batch processing #48
base: main
Are you sure you want to change the base?
Conversation
This commit does quite a bit: - Introduces Makefile as the commands are getting long - Adds installation of ImageMagick to the Dockerfile - Adds imagick bindings - Instatiates the bindings in main.go to check they work
ba7c147
to
5a0d78f
Compare
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.
Generally looks like a good shape :) I'm assuming it'll be come more goroutine-based at some point? I definitely like the breaking up of IO-bound and CPU-bound work into separate goroutine pools :)
batch-processing/main.go
Outdated
defer res.Body.Close() | ||
|
||
// Ensure we got success from the server | ||
if res.StatusCode != http.StatusOK { |
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.
As an extension problem in the README, I'd add trying to get them thinking about pause/resume, so that already-done work can be skipped if we end up re-running (i.e. if the processed failed, we somehow have tracked what we've already processed, so we can just pick up the not-yet-done work). But not for the first cut!
However, for the example impl I'd probably add a comment here contrasting the pros of eagerly failing vs log and continue
- The `defer` calls now clean up immediately - New `Config` and `Row` structs clean up the flow
72910a0
to
022f41a
Compare
Fix #26.
View rendered batch-processing/IMPLEMENTATION.md