News for hackers. Stuff that matters.
Re:How Heap's 5-line MVP evolved into a 30,000 TPS beast by matm on Tuesday March 18, 2014 @03:27PM (#7424361)
This is referring to the integration code itself. It was something like:

  var DOMEvents = ['click', 'submit', 'change'];
  for (var i = 0; i < DOMEvents.length; i++) {
    window.addEventListener(DOMEvents[i], function(e){
      $.post('/collector', {type: e.type, target_id: e.target.id, target_class: e.target.className});
    });
  }
Re:How Heap's 5-line MVP evolved into a 30,000 TPS beast by onion2k on Tuesday March 18, 2014 @05:08PM (#7424983)
That's interesting and immediately obvious how it could both be useful and valuable in the right domain. Logging what people are doing on modern event-driven websites definitely is a problem worth solving. My let's-made-a-complicated-version-first mindset would have extended jQuery's .bind or .on prototype in case the site is using event.stopPropagation(), and that's why I never finish anything. Thanks for sharing.
Re:How Heap's 5-line MVP evolved into a 30,000 TPS beast by shamsulbuddy on Friday March 28, 2014 @03:47PM (#7489545)
This is rocksolid basic script..one quick question..if you post on every event then dont you think so that it will generate huge traffic..how did you handle that