Licensing Concerns Regarding Three-Walk Topological Sorting Implementation #263
Replies: 2 comments 4 replies
-
|
Thank you for the clarification, @flori-schwa . To avoid confusion, can you please also explain what the other 2 commits in that branch are and if they are related to the three-walk algorithm? You already proposed to merge them, that's why I ask:
@msohn what is the normal procedure here? In the section Legal Paperwork, it only says that one needs to
Also, the algorithm that Florian used is described in the series of blog posts called Supercharging the Git Commit Graph by Derrick Stolee, Principal Software Engineer at Microsoft. This one explains the algorithm: |
Beta Was this translation helpful? Give feedback.
-
|
Hi Florian, thanks for working on this 👍 I don't have concerns if you did the reimplementation from scratch and did it based on the published algorithm. The change seems rather large, maybe there's a way to split it into a series of smaller changes , e.g. if it contains refactorings which can be extracted into separate changes. How will topo sorting be done if there is no commit-graph available or if the commit-graph is outdated ? |
Beta Was this translation helpful? Give feedback.

Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I'm looking for feedback regarding potential licensing issues.
The discussion started by @fedejeanne in #243 outlines the performance problems we are facing when using the History View in EGit.
I have since then spent some time trying to improve the performance for repositories with large histories and ended up looking up how the C implementation of git performs topological sorting (https://github.com/git/git/tree/master/revision.c), where I've discovered the three-walk algorithm based on commit graph generation numbers.
As a prototype, I then transcribed this algorithm to java and integrated it into JGits Generator pipeline, by writing a new Generator, which completely replaces the existing chain of PendingGenerator->RewriteGenerator->TopoSortGenerator. This new Generator implemented the three-walk algorithm, applied the (Tree)RevFilter and performed commit history rewriting.
We have internally deployed this prototype for a while now and it has significantly improved the usability of the history view.
Other users and organisations with large repositories will most likely also profit from this algorithm. But since git's source code is licensed under a GPLv2 license (whereas JGit is licensed under a permissive BSD 3-Clause license), a simple transcription of the C code would probably be rejected by JGit, as per the README:
So I started re-implementing my prototype from scratch over the past few weeks, referencing my prototype occasionally when encountering performance problems or errors during commit rewriting.
The current version is available at https://github.com/vi-eclipse/jgit/tree/fschwabe/TopologicalRevWalk
The biggest differences are the adaption of the algorithm to work with JGits RevFilters and history rewriting as well as the separation of the monolithic prototype into multiple smaller components: ExplorePhase, InDegreePhase and the orchestrator ("TopoSortPendingGenerator")
I am happy to perform further refactoring (or attempt another clean-room re-implementation) if anyone has concerns with integrating this into JGit's codebase.
Beta Was this translation helpful? Give feedback.
All reactions