Edgewall Software
Modify

Ticket #5499 (new defect)

Opened 5 years ago

Last modified 2 years ago

performance issues when viewing larger files

Reported by: theultramage@… Owned by: cboos
Priority: normal Milestone: next-minor-0.12.x
Component: version control/browser Version: devel
Severity: normal Keywords: blame
Cc: kirean@…
Release Notes:
API Changes:

Description

There are numerous source code files in our project that are above the default limit (250kB).
When viewing these files, it takes a moment before they're generated and rendered by the browser. When using the 'annotate' option, this problem increases significantly. Here is a sample (server is a P733, using apache):

Original size: 200kB
Browser view: 800kB, generating time: 1 minute
Annotated view: 1500kB, generating time: 5 minutes

It gets far worse on files that are 400+kB (actually I don't even try that anymore).
Additionally, when viewing such an annotated page in Opera, the browser does 100% cpu load that doesn't stop until you close the page. Sometimes it also destabilizes the browser (needs restart).

Can anything be done in this regard?

Attachments

Change History

comment:1 Changed 5 years ago by cboos

  • Keywords blame added
  • Milestone set to 0.11

There's certainly room for improvement:

  • the blame.js Javascript code could certainly be optimized or could even disable itself for large files
  • the generated HTML could be less verbose
    • there's the empty <span> problem (#4339)
    • the color code could eventually be done using class names instead of style attributes

Tentatively scheduling for 0.11.

comment:2 Changed 4 years ago by kirean@…

  • Cc kirean@… added

I'm also having perfomance issues with annotate.

comment:3 Changed 4 years ago by kirean@…

The annotate view in 0.11 looks cool, but if performance is effected I'll be stuck with ViewVC anyway. I would prefer this to be done in the same (fast) way as in ViewVC instead..

comment:4 Changed 4 years ago by cboos

Well, until the performance issue gets fixed, maybe we could try to disable the javascript code for anything but small files:

  • trac/versioncontrol/templates/browser.html

     
    2727                range_max_secs: '$dir.range_max_secs' 
    2828            }); 
    2929        </py:if> 
    30         <py:if test="file and file.annotate"> 
     30        <py:if test="file and file.annotate and file.size &lt; 50000"> 
    3131          enableBlame("${href.changeset()}/", "${path}"); 
    3232        </py:if> 
    3333      }); 

I doubt this will be enough to fix the performance issue, but maybe it will make it more acceptable.

comment:5 Changed 3 years ago by cboos

  • Milestone changed from 0.11-retriage to 0.12

See also #7055.

comment:6 Changed 2 years ago by rblank

  • Milestone changed from 0.12 to next-minor-0.12.x
View

Add a comment

Modify Ticket

Change Properties
<Author field>
Action
as new
as The resolution will be set. Next status will be 'closed'
to The owner will be changed from cboos. Next status will be 'new'
The owner will be changed from cboos to anonymous. Next status will be 'assigned'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.