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

S3 backup exceptions aren't surfaced until the next backup #35

Open
eric-weaver opened this issue Apr 22, 2019 · 0 comments
Open

S3 backup exceptions aren't surfaced until the next backup #35

eric-weaver opened this issue Apr 22, 2019 · 0 comments
Assignees

Comments

@eric-weaver
Copy link
Contributor

eric-weaver commented Apr 22, 2019

Affected Southpaw Versions: v0.2.1 to v0.3.1

Issue:
Currently uploading backups to S3 via syncToS3() happen in a background thread. There is an object level Future that we use to block multiple backups from being performed at the same time. Since the result of the syncToS3 function is only evaluated when we call Future.get(), if an exception is thrown during copying backup files to S3, the exception will not be surfaced until the next time waitForSyncToS3() function is called which blocks till the Future is returned. Southpaw will continue processing records until the next backup, but on restart it will rollback (backup.time.s * 2) seconds

Proposed Fix:
Add an ability to add an onError callback to the syncToS3() function that will be fired off when an exception occurs allowing the main thread to listen for this and handle it appropriately.

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

No branches or pull requests

1 participant