Re: [PATCH v4 12/15] bugreport: count loose objects
- From
Emily Shaffer <emilyshaffer@google.com>
- Date
- Dec 16, 2019, 23:54 UTC
- Message-ID
- <20191216235421.GM135450@google.com>
- In-Reply-To
- <xmqqv9qjhp28.fsf@gitster-ct.c.googlers.com>
On Fri, Dec 13, 2019 at 01:51:27PM -0800, Junio C Hamano wrote:
Show 17 quoted lines
> Emily Shaffer <emilyshaffer@google.com> writes: > > > The number of unpacked objects in a user's repository may help us > > understand the root of the problem they're seeing, especially if a > > command is running unusually slowly. > > > > Rather than directly invoking 'git-count-objects', which may sometimes > > fail unexpectedly on Git for Windows, manually count the contents of > > .git/objects. > > Is for_each_loose_object() or for_each_loose_file_in_objdir() not > sufficient? We really do *not* want a redundant implementation of > something we already use elsewhere in the system, especially for the > purpose of this program, because you would end up reporting what you > computed in a way that may be quite different from what the rest of > the system that is actually used by the end users computes. >
Oh, thanks for the pointer. That looks sufficient - I will investigate the differences between the two and stop filesystem browsing by hand in this case.
- Emily