-
Notifications
You must be signed in to change notification settings - Fork 31
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
Improve ocrd_network logging #1111
Conversation
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.
LGTM, just a quick read-through, I'll contribute ideas once I have some more time for it.
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 have tested and it seems to work fine. I think it is a huge improvement, all structured now and much better to find the right logfile now.
What imho could be added is:
- make logfile and and mets-server basedir configurable with env. For example when I test locally I use /data for the mets-server (this is better for my local setup with docker-compose) and when this was configurable it would be easier for me to set it up. And I could use /data in the docker-compose-setup as well and would not have to volume mount two directories (now I am mounting /data and /tmp).
- add a logging endpoint for the processors: as now we have the log-file-path in the database it would be very easy to add and endpoint to the processing server to retrieve the log of a processor through http
Resolved with 464f8ea
Resolved with c81ffcc |
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.
Looks good, much cleaner and being able to get the log via the API is excellent.
Ready for release IMHO. Can you summarize the changes for the release notes?
It's on top. I have updated the initial post. |
@kba, I forgot to update the Considering this, I was wondering why should we add the environment variables manually to the help section. I think it would be possible to iterate over all variables inside the |
The main reasons I did the |
This PR improves the logging mechanism of the
ocrd_network
module.Additions:
{job_id}.log
ocrd_network
logging is based on the format provided inocrd_utils
Feel free to recommend suggestions.