Re: [PATCH 01/18] streaming: rename `git_istream` into `odb_read_stream`
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Nov 19, 2025, 20:04 UTC
- Message-ID
- <xmqqikf5bxg8.fsf@gitster.g>
- In-Reply-To
- <2nd7qcj7jrrwc4fyhfsovs3ptrwmrdxxcap4sqadujtwwua5ha@bpbjlbnbcpiw>
Justin Tobler <jltobler@gmail.com> writes:
Show 13 quoted lines
> On 25/11/19 08:47AM, Patrick Steinhardt wrote: >> In the following patches we are about to make the `git_istream` more >> generic so that it becomes fully controlled by the specific object >> source that wants to create it. As part of these refactorings we'll >> fully move the structure into the object database subsystem. > > Ok, so looking at the current implementation of `git_istream`, it does > appear to be already defined in a somewhat generic manner as it supports > reading loose/packed objects. What sources are supported are all > centrally defined in "streaming.c" though. It sounds like we eventually > want each source to fully control this interface without having to go > through "streaming.c" to setup each source stream type which makes > sense.
As the original inventor of git_istream abstraction, I fully agree with this direction.
Thanks for cleaning up, and thanks for reviewing.
Show 22 quoted lines
> >> Prepare for this change by renaming the structure from `git_istream` >> to `odb_read_stream`. This mirrors the `odb_write_stream` structure that >> we already have. >> >> Signed-off-by: Patrick Steinhardt <ps@pks.im> >> --- >> diff --git a/streaming.h b/streaming.h >> index bd27f59e57..acf4c84338 100644 >> --- a/streaming.h >> +++ b/streaming.h >> @@ -7,14 +7,14 @@ >> #include "object.h" >> >> /* opaque */ >> -struct git_istream; >> +struct odb_read_stream; > > The name change here makes sense. While we are here, it might be nice to > leave a comment annotating it's purpose in a bit more detail. > > -Justin