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

runwithRedirectFrom() call needs error checking and output stream handling #32

Open
sheridancbio opened this issue Jul 30, 2016 · 3 comments

Comments

@sheridancbio
Copy link
Collaborator

In PdbScriptsPipelineRunCommand.java : runwithRedirectFrom(), a process is created and input is redirected to it, but output streams are ignored and the return code / status code is not checked.

Long standard output or standard error streams can cause the small process buffers to overload .. but in the case of mysql we probably don't expect that. Still, maybe we should redirect output streams to temporary files and then delete them when the mysql commands are complete.

But return codes must be checked to see if the mysql command failed or exited with an error.

@juexinwang
Copy link
Collaborator

I can try to deal with that. But I think the better solution is using mysql features directly from spring-boot

@juexinwang
Copy link
Collaborator

I have updated this.

@sheridancbio sheridancbio changed the title runwithRedirectFrom() call needs error checking and output stream handling Rev3 : runwithRedirectFrom() call needs error checking and output stream handling Aug 4, 2016
@sheridancbio sheridancbio self-assigned this Aug 4, 2016
@sheridancbio sheridancbio changed the title Rev3 : runwithRedirectFrom() call needs error checking and output stream handling runwithRedirectFrom() call needs error checking and output stream handling Aug 12, 2016
@sheridancbio
Copy link
Collaborator Author

This issue is closely related to #13 ... if we properly handle output streams, both of these issues can probably be resolved.

In addition to reporting a detected error during a mysql command, the pdb-annotation-pipeline should stop its processing at the point where the error occurred (unless the error can be recovered from) and tell the user as much as possible about what partial changes were made to the database, so the user can manually correct partial updates if necessary.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants