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

Use git log -m, and handle octopus merges too #3167

Merged
merged 4 commits into from
Aug 18, 2020

Conversation

idodeclare
Copy link
Contributor

Hello,

Please consider for integration this patch to use the -m switch with git log to support octopus merges as well as to properly report if new files come into existence during a merge.

(This is an extract from a branch of mine actually named bugfix/git_parsing from last year which I realize now was intended at first to support the above but where I had gone down a deep rabbit hole trying to speed up history for the FreeBSD repo and arrived at several time-consuming but lackluster results. I put the branch on the back burner forgetting its original purpose.)

Users will not be forced to reindex, but any merge history previously hidden will require a reindex to be visible.

Thank you.

Also:
- Add FileHistoryCacheOctopusTest showing dupes
  for merges (before revising for this patch)
- Update parsing of Git revision with labels
- Fix oracle#3166 "partial parse of git log"
@coveralls
Copy link

coveralls commented Jun 14, 2020

Pull Request Test Coverage Report for Build 5206

  • 21 of 24 (87.5%) changed or added relevant lines in 7 files are covered.
  • 1 unchanged line in 1 file lost coverage.
  • Overall coverage decreased (-0.04%) to 73.456%

Changes Missing Coverage Covered Lines Changed/Added Lines %
opengrok-indexer/src/main/java/org/opengrok/indexer/history/BazaarTagParser.java 0 1 0.0%
opengrok-indexer/src/main/java/org/opengrok/indexer/history/FileHistoryCache.java 2 3 66.67%
opengrok-indexer/src/main/java/org/opengrok/indexer/history/Repository.java 1 2 50.0%
Files with Coverage Reduction New Missed Lines %
opengrok-indexer/src/main/java/org/opengrok/indexer/history/FileHistoryCache.java 1 77.11%
Totals Coverage Status
Change from base Build 5203: -0.04%
Covered Lines: 37891
Relevant Lines: 51583

💛 - Coveralls

@vladak
Copy link
Member

vladak commented Jun 17, 2020

What happens when diffing a merge changeset and regular changeset in history view ?

@vladak
Copy link
Member

vladak commented Jun 17, 2020

Also, seems like there are some Windows build failures related to the changes.

@idodeclare
Copy link
Contributor Author

What happens when diffing a merge changeset and regular changeset in history view ?

@vladak , it's no different from any other diff. Reminder that OpenGrok starts two processes (in parallel thanks to #2955) to get the diff data for the two commit hashes. A merge has a commit hash too.

Also I pushed a change that hopefully fixes the Windows build.

@vladak vladak merged commit 0241b5b into oracle:master Aug 18, 2020
@vladak
Copy link
Member

vladak commented Aug 18, 2020

Sounds good. Thanks !

@idodeclare idodeclare deleted the feature/git_octopus branch August 22, 2020 17:09
@tulinkry
Copy link
Contributor

I think this touches also #1167, @idodeclare do you think this resolves it?

@idodeclare
Copy link
Contributor Author

I think this touches also #1167, @idodeclare do you think this resolves it?

@tulinkry, yes I think it does.

@tulinkry
Copy link
Contributor

Thanks, closing the issue

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.

4 participants