Navigation Menu

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

Update git datasource to be a "remote first" implementation #361

Closed
2 tasks done
mansona opened this issue Oct 17, 2018 · 0 comments
Closed
2 tasks done

Update git datasource to be a "remote first" implementation #361

mansona opened this issue Oct 17, 2018 · 0 comments
Assignees

Comments

@mansona
Copy link
Contributor

mansona commented Oct 17, 2018

During a conversation with @ef4 today we discussed some of the functionality needed to make the git data source work effectively with a remote repo as the authoritative repo.

One of the things that came up on the conversation was that the _makeCommit() could be refactored to support a "remote first" implementation that should Just Work™️ with local repos.

The main thought process is that git supports pushing an orphan commit to a remote branch which will essentially add that commit to the branch.

There are a lot of extra things to consider so I will do my best to track them below:

Extra Considerations

  • The remote implementation adds some extra scenarios for race conditions (or rather extends the possibility of previously impossible conditions) and makes all race conditions more likely. because of this, we have to implement retry (including backoff) in a loop that keeps trying to apply the changes

todo

  • Identify all of the test cases that need to be implemented specifically for remote repo functionality and make sure they are itemised. This will be effective when implementing the functionality in a TDD way 👍
  • implement a factory "service" that ensures the same local repo used for both indexers and writer. This will need to for a persistent cache on disk that is in a known place using a naming convention with the remote.
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