git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] pack-objects: use streaming interface for reading large loose blobs

From
Junio C Hamano <gitster@pobox.com>
Date
May 29, 2012, 17:56 UTC
Message-ID
<7vd35m6fct.fsf@alter.siamese.dyndns.org>
In-Reply-To
<1338028081-22638-1-git-send-email-pclouds@gmail.com>
Nguyễn Thái Ngọc Duy  <pclouds@gmail.com> writes:
Show 14 quoted lines
> git usually streams large blobs directly to packs. But there are cases
> where git can create large loose blobs (unpack-objects or hash-object
> over pipe). Or they can come from other git implementations.
> core.bigfilethreshold can also be lowered down and introduce a new
> wave of large loose blobs.
>
> Use streaming interface to read/compress/write these blobs in one
> go. Fall back to normal way if somehow streaming interface cannot be
> used.
>
> Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
> ---
>  On top of ng/pack-objects-cleanup. Changes since the last version is
>  we do not rely on close_istream(NULL); any more.

This version looks much cleaner, at least to me, as the logic in the function always switches upon "st", using it as "are we reading the data from the stream incrementally?" boolean.

Thanks, will queue.
Previous: Nguyễn Thái Ngọc Duy
Message 2 of 2 in “pack-objects: use streaming interface for reading large loose blobs”
  1. pack-objects: use streaming interface for reading large loose blobsNguyễn Thái Ngọc Duy, May 26, 2012
  2. Junio C HamanoMay 29, 2012

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.