aboutsummaryrefslogtreecommitdiffstats
path: root/odb.h
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2025-09-15 08:52:05 -0700
committerJunio C Hamano <gitster@pobox.com>2025-09-15 08:52:05 -0700
commit7d00521d7be21ca4a3713b2fa367eb7296212e09 (patch)
tree7eb6850b179d543a59177c8363ec90dc0768fce8 /odb.h
parentThe eighth batch (diff)
parentbulk-checkin: use repository variable from transaction (diff)
downloadgit-7d00521d7be21ca4a3713b2fa367eb7296212e09.tar.gz
git-7d00521d7be21ca4a3713b2fa367eb7296212e09.zip
Merge branch 'jt/de-global-bulk-checkin'
The bulk-checkin code used to depend on a file-scope static singleton variable, which has been updated to pass an instance throughout the callchain. * jt/de-global-bulk-checkin: bulk-checkin: use repository variable from transaction bulk-checkin: require transaction for index_blob_bulk_checkin() bulk-checkin: remove global transaction state bulk-checkin: introduce object database transaction structure
Diffstat (limited to 'odb.h')
-rw-r--r--odb.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/odb.h b/odb.h
index 51fe8a5a92..bd7374f92f 100644
--- a/odb.h
+++ b/odb.h
@@ -92,6 +92,7 @@ struct odb_source {
struct packed_git;
struct cached_object_entry;
+struct odb_transaction;
/*
* The object database encapsulates access to objects in a repository. It
@@ -103,6 +104,13 @@ struct object_database {
struct repository *repo;
/*
+ * State of current current object database transaction. Only one
+ * transaction may be pending at a time. Is NULL when no transaction is
+ * configured.
+ */
+ struct odb_transaction *transaction;
+
+ /*
* Set of all object directories; the main directory is first (and
* cannot be NULL after initialization). Subsequent directories are
* alternates.