git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* pack.packSizeLimit, safety checks
@ 2010-02-01  9:20 Sergio
  2010-02-01 16:11 ` Nicolas Pitre
  0 siblings, 1 reply; 11+ messages in thread
From: Sergio @ 2010-02-01  9:20 UTC (permalink / raw)
  To: git

Hi,

documentation about pack.packSizeLimit

says:

The default maximum size of a pack. This setting only affects packing to a file,
i.e. the git:// protocol is unaffected. It can be overridden by the
--max-pack-size option of git-repack(1).

I would suggest clarifying it into

The default maximum size of a pack in bytes. This setting only affects packing
to a file, i.e. the git:// protocol is unaffected. It can be overridden by the
--max-pack-size option of git-repack(1).

Since --max-pack-size takes MB and one might be tempted to assume that the same
is valid for pack.packSizeLimit.

Also note that some safety check on pack.packSizeLimit could probably be
desirable to avoid an unreasonably small limit. For instance:

Assume that pack.packSizeLimit is set to 1 (believing it would be 1MB, but it is
in fact 1B). With this at the first git gc every object goes in its own pack.
You realize the mistake, you fix pack.packSizeLimit to 1000000, but at this
point you cannot go back since git gc cannot run anymore (too many open files).

Maybe, considering all the possible use cases of pack.packSizeLimit could help
finding a reasonable lower bound.

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2010-02-04  2:35 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-02-01  9:20 pack.packSizeLimit, safety checks Sergio
2010-02-01 16:11 ` Nicolas Pitre
2010-02-01 16:26   ` Johannes Sixt
2010-02-01 16:28     ` Shawn O. Pearce
2010-02-01 17:20       ` Junio C Hamano
2010-02-01 17:19   ` Junio C Hamano
2010-02-01 18:04     ` Nicolas Pitre
2010-02-01 18:45       ` Junio C Hamano
2010-02-04  2:14       ` Junio C Hamano
2010-02-04  2:31         ` Nicolas Pitre
2010-02-04  2:34           ` Junio C Hamano

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).