odb: track commit graphs via object source
Get series with b4
b4 am [email protected] change-id 20250904-b4-pks-commit-graph-via-source-b4e1a1edd214Versions newest first
- v1 Latest6 patches 19 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/6 | blame: drop explicit check for commit graphblame.c | +0 | 1 reply | |
| 2/6 | revision: drop explicit check for commit graphrevision.c | +0 | 1 reply | |
| 3/6 | commit-graph: return the prepared commit graph from `prepare_commit_graph()`commit-graph.c | +32 | 1 reply | |
| 4/6 | commit-graph: return commit graph from `repo_find_commit_pos_in_graph()`bloom.c commit-graph.c commit-graph.h | +23 | 1 reply | |
| 5/6 | commit-graph: pass graphs that are to be merged as parametercommit-graph.c | +10 | 0 replies | |
| 6/6 | odb: move commit-graph into the object sourcescommit-graph.c commit-graph.h odb.c +2 more | +56 | 1 reply |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH 0/6] odb: track commit graphs via object source
Hi,
commit graphs are currently stored on the object database level. This doesn't really make much sense conceptually, given that commit graphs are specific to one object source. Furthermore, with the upcoming pluggable object database effort, an object source's backend may not evene have a commit graph in the first place but store that information in a different format altogether.
This patch series prepares for that by moving the commit graph from struct object_database into struct odb_source.
There's a trivial conflict with tc/last-modified that can be solved like this:
commit-graph.c +0 -0
@@@ -823,7 -812,12 +823,11 @@@ int corrected_commit_dates_enabled(strustruct bloom_filter_settings *get_bloom_filter_settings (struct repository *r) { - struct commit_graph *g; + struct commit_graph *g = prepare_commit_graph(r); + - if (!prepare_commit_graph(r)) ++ if (!g) +return NULL ; + - g = r->objects->commit_graph;while (g) {if (g->bloom_filter_settings)return g->bloom_filter_settings;
Thanks!
Patrick
---
Patrick Steinhardt (6):
blame: drop explicit check for commit graph
revision: drop explicit check for commit graph
commit-graph: return the prepared commit graph from prepare_commit_graph()
commit-graph: return commit graph from repo_find_commit_pos_in_graph()
commit-graph: pass graphs that are to be merged as parameter
odb: move commit-graph into the object sources
blame.c | 3 - bloom.c | 8 ++- commit-graph.c | 177 +++++++++++++++++++++++++++++++-------------------------- commit-graph.h | 14 ++--- odb.c | 9 +-- odb.h | 6 +- packfile.c | 3 +- revision.c | 3 - 8 files changed, 118 insertions(+), 105 deletions(-)
---
base-commit: 2462961280690837670d997bde64bd4ebf8ae66d
change-id: 20250904-b4-pks-commit-graph-via-source-b4e1a1edd214