<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>142011</bug_id>
          
          <creation_ts>2015-02-25 00:33:41 -0800</creation_ts>
          <short_desc>Web Inspector: Make console faster, only render last N messages in the DOM</short_desc>
          <delta_ts>2026-01-12 09:08:28 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>Web Inspector</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>ASSIGNED</bug_status>
          <resolution></resolution>
          
          <see_also>https://bugs.webkit.org/show_bug.cgi?id=136984</see_also>
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          <dependson>155629</dependson>
    
    <dependson>157368</dependson>
          <blocked>152220</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Nikita Vasilyev">nvasilyev</reporter>
          <assigned_to name="Nikita Vasilyev">nvasilyev</assigned_to>
          <cc>giovanni.piller</cc>
    
    <cc>graouts</cc>
    
    <cc>inspector-bugzilla-changes</cc>
    
    <cc>jonowells</cc>
    
    <cc>webkit-bug-importer</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1071999</commentid>
    <comment_count>0</comment_count>
    <who name="Nikita Vasilyev">nvasilyev</who>
    <bug_when>2015-02-25 00:33:41 -0800</bug_when>
    <thetext>Having thousands of messages in the console can make it slow. Display only last 500 messages to reduce amount of elements in the DOM and thus reduce memory consumption.

Either add &quot;Show previous 100 messages&quot; button or just load them when we scroll to the top edge of the console.

I’m not sure about the numbers, I need to do some stress testing first.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1072001</commentid>
    <comment_count>1</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2015-02-25 00:34:01 -0800</bug_when>
    <thetext>&lt;rdar://problem/19950261&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1141645</commentid>
    <comment_count>2</comment_count>
    <who name="Nikita Vasilyev">nvasilyev</who>
    <bug_when>2015-11-12 14:43:32 -0800</bug_when>
    <thetext>While working on code hotness visualizer, I&apos;ve been logging objects every time I get data from the backend, approximately every second. Running inspector over 10 minutes makes the whole UI interface unbearably slow.

The following code shouldn&apos;t drastically affect Web Inspector performance after running for 10 minutes:

setInterval(function() {
    console.log({x: Math.random()})
}, 1000);</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1148776</commentid>
    <comment_count>3</comment_count>
    <who name="Nikita Vasilyev">nvasilyev</who>
    <bug_when>2015-12-12 21:01:17 -0800</bug_when>
    <thetext>See also:
&lt;rdar://problem/23527135&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1165107</commentid>
    <comment_count>4</comment_count>
    <who name="Nikita Vasilyev">nvasilyev</who>
    <bug_when>2016-02-16 03:49:28 -0800</bug_when>
    <thetext>I’d prefer to have a generic solution that would
also work for big data grids (e.g. in Timelines).</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1172408</commentid>
    <comment_count>5</comment_count>
    <who name="Nikita Vasilyev">nvasilyev</who>
    <bug_when>2016-03-08 22:15:31 -0800</bug_when>
    <thetext>As far as I can tell, we store console messages data only in the DOM.
We don&apos;t have an array of WebInspector.ConsoleMessage instances in
WebInspector.JavaScriptLogViewController or anywhere else.

My first step would be to store WebInspector.ConsoleMessage instances
in WebInspector.JavaScriptLogViewController, so I can render them later
when needed.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1173002</commentid>
    <comment_count>6</comment_count>
    <who name="Nikita Vasilyev">nvasilyev</who>
    <bug_when>2016-03-09 21:51:11 -0800</bug_when>
    <thetext>The first step I&apos;d like to tackle is to render console
messages only when the split console is visible or the console
tab is active.

AFAIK, there is currently no event like &quot;console-show&quot;.
The closest I&apos;ve found so far is
WebInspector.QuickConsole.Event.DidResize event and
WebInspector.consoleContentView.visible getter.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1173008</commentid>
    <comment_count>7</comment_count>
    <who name="Timothy Hatcher">timothy</who>
    <bug_when>2016-03-09 23:13:17 -0800</bug_when>
    <thetext>(In reply to comment #6)
&gt; The first step I&apos;d like to tackle is to render console
&gt; messages only when the split console is visible or the console
&gt; tab is active.
&gt; 
&gt; AFAIK, there is currently no event like &quot;console-show&quot;.
&gt; The closest I&apos;ve found so far is
&gt; WebInspector.QuickConsole.Event.DidResize event and
&gt; WebInspector.consoleContentView.visible getter.

LogContentView  would get hidden() and shown() called on them. Implementing those could call other code, like on JavaScriptLogViewController.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>