brikis98 / ping-play

BigPipe streaming for the Play Framework
MIT License
307 stars 60 forks source link

Add monitoring hooks #22

Open brikis98 opened 9 years ago

brikis98 commented 9 years ago

To track the performance of a BigPipe page, you will want to track (at least):

  1. The time when HTTP request was received
  2. The time when Play app sent back the first bytes of the response
  3. The time when each pagelet arrived in the browser.
  4. The time it took to load each pagelet's dependencies
  5. The time it took to render each pagelet

There are existing tools to measure (1) and (2), but we should add server-side hooks for (3), and client-side hooks for (3), (4), and (5). The client-side hooks could even have an optional Google Analytics integration.