From: Jakub Narebski <jnareb@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: git@vger.kernel.org
Subject: Re: [RFC/PATCH 2/2] gitweb: Add an option to show size of blobs in the tree view
Date: Wed, 1 Aug 2007 15:05:01 +0200 [thread overview]
Message-ID: <200708011505.02078.jnareb@gmail.com> (raw)
In-Reply-To: <7vd4y8fcjw.fsf@assigned-by-dhcp.cox.net>
On Wed, 1 Aug 2007, Junio C Hamano wrote:
> Jakub Narebski <jnareb@gmail.com> writes:
>
>> It allows to play with 'tree' view with blob size. Currently you
>> have to start browsing by adding ";opt=-l" to the gitweb URL by
>> hand. There is not link which will change view from ordinary 'tree'
>> view to 'tree' view with blob sizes.
>>
>> The 'tree' with blob size view is slightly more costly than the
>> ordinary, old 'tree' view, but not much more (0.018s vs 0.012s
>> in the hot cache case), so I don't think we need to control it
>> as a enabled (or disabled) feature, overrideable or not. It
>> probably should not be default.
>
> I do not think there is any reason to forbid its use, as the
> "-l" to ls-tree was introduced for exactly this purpose,
> However, it might make sense to make the use of -l optional via
> the %feature mechanism. 50% increase even on hot cache case is
> not a price people who run busy sites would want to pay.
It's 0.014s vs 0.009s - 0.010s on root dir of repacked git.git
repository. It is I think caused by the fact that "git ls-tree -l
<tree-ish>" has to look up each blob in the tree, and read its
header. IIRC header is uncompressed, so it doesn't need deflating;
if it is compressed, then we have to add deflating to that. The
blob size (object size) is not present in the tree object structure.
Perhaps it is something to have in mind when designing and implementing
new packv4 with its creating tree objects on demand.
But I agree that this should be protected by the %feature mechanism.
Two questions:
1. Should we make '-l' default when turned on? Or make 'showsizes'
%feature tristate: off, on, by default on?
2. If it is turned off, should we silently (or not so silently)
ignore this option, or return "Permission denied" or perhaps
"Invalid extra options parameter"?
And how we should name this feature (key in %feature hash)?
P.S. I have received no comments on
[RFC/PATCH] gitweb: Enable transparent compression for HTTP output
(trade CPU load for lower bandwidth usage).
--
Jakub Narebski
Poland
next prev parent reply other threads:[~2007-08-01 22:09 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-07-31 11:19 [PATCH 1/2] gitweb: Allow for multivalued parameters passed to href subroutine Jakub Narebski
2007-07-31 11:19 ` [RFC/PATCH 2/2] gitweb: Add an option to show size of blobs in the tree view Jakub Narebski
2007-07-31 22:12 ` Junio C Hamano
2007-08-01 13:05 ` Jakub Narebski [this message]
2007-08-01 23:12 ` Junio C Hamano
2007-08-01 23:58 ` Jakub Narebski
2007-08-02 0:47 ` Junio C Hamano
2007-08-02 5:22 ` Junio C Hamano
2007-08-02 10:47 ` Jakub Narebski
2007-08-02 20:47 ` Junio C Hamano
2007-07-31 23:07 ` Jakub Narebski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200708011505.02078.jnareb@gmail.com \
--to=jnareb@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).