This repository was archived by the owner on Sep 11, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 535
plumbing: format, packfile fix issue #129, related #124, and documentation improvements #130
Merged
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
This comments need improvements.
This line is OK, but does not clearly explain the purpose and usage of the type, as we will see in the next sentence.
This line is confusing for several reasons:
Offsets
method has to be improved, and it should probably call Decode internally.Decoder
without anObjectStorer
is not clear. According to the first line, the main purpose of aDecoder
is to store objects from a packfile into anObjectStorer
, so what happens when noObjectStorer
is available? how is this useful?This is OK, once the previous line is clarified.
s/transation/transaction/
This is not true, a Rollback is only called when the
setObject
operation fails on the transaction, but not when other operations fails. See my comments below.Overall, the purpose of this type is not clear, we should redesign it and clarify its purpose and usage.
We should start by explaining the problem, how the type is expected to be used. Then explain the possible decoders we support (seekable-transactioner, seekable-non-transactioner, ...). As this is very relevant for it use, the cause of a lot of code repetitions and has been the cause of several bugs in the past.
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.
It will be nice to explain all the possible combinations of
ObjectStorer
s and seekable scanners, from the very beginning, just to make it easier later to document the internal parts.