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

Make Metadata store account for IOExceptions #3

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

useless5771
Copy link
Collaborator

Updated GistMetadataStore and GistCommentStore so they handle possible IOExceptions thrown (and unexpected failures) during updates to JSON files.

The implementation (of both) is as follows:

  • they always write to a working copy of a file
  • if writing to a working copy fails, it is deleted.
  • if there happens to be an exception thrown during replacement of the main copy with the working copy, the state is recovered from the working copy
  • if it happens that both - working copy and main file is there, working copy is ignored.

I covered the changes with unit tests, however I haven't performed any integration tests with RCloud, as I don't have RCloud configured to work with rcloud-gist-service (yet).

FIX #2

@gordonwoodhull gordonwoodhull requested a review from s-u November 30, 2018 15:11
@gordonwoodhull
Copy link

@s-u, we should review and merge this.

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

Successfully merging this pull request may close these issues.

2 participants