Bug 6875 - Rework graph rendering
Summary: Rework graph rendering
Status: RESOLVED FIXED
Alias: None
Product: Error Reporting tool
Classification: Yocto Project Subprojects
Component: Error Reporting Tool (show other bugs)
Version: unspecified
Hardware: x86 Multiple
: Medium normal
Target Milestone: 1.8 M2
Assignee: Michael Wood
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks: 6523
  Show dependency tree
 
Reported: 2014-10-23 13:56 UTC by Michael Wood
Modified: 2015-01-23 19:48 UTC (History)
0 users

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: No (bug/feature does not impact docs)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Wood 2014-10-23 13:56:04 UTC
The graph rendering is very expensive at the moment all of the graphs are rendered using a fixed template that comes with django-nvd3. To access properties which aren't exposed in this template there is some javascript in the graphs page which re-writes the result of the template render which contains the entire page and not just the graph. The result of this is then set as the page for each graph async using jquery.

We can simplify this by using a corrected graph template and not the one that is shipped with django-nvd3.
Comment 1 Michael Wood 2015-01-23 19:48:14 UTC
commit d33be0440750f0684ecccacf8af09b6937bd59c2

    home: Rework the mechanism for generating graphs via custom template
    
    Previously using python-nvd3 we were constrained by the templates
    distributed and the properties exposed by the python
    bindings/abstraction for nv d3 which were incomplete. To avoid multiple
    passes on the page (sever side and client side) we can just generate the
    graph with the correct js/html in the first place.