Hi,
we're working on integrating Go's runtime/trace execution tracer from the old catapult UI to Perfetto (see
tracking issue) and running into a small problem:
- The user clicks a link "open in Perfetto".
- Our onClick handler calls window.open() to establish the deep linking with Perfetto UI. This has to be done right away to avoid popup blocking from the browser.
- Then we call fetch() to get the data for perfetto, but this process can take 20s.
- Meanwhile the Perfetto UI is open and the user has no indication that the data is being loaded in the background.
- Eventually the fetch() operation finishes, and we call postMessage() which causes Perfetto to show a loading indicator.
What we would like is the ability to tell Perfetto to start showing a loading indicator immediately, perhaps via a separate postMessage(). This way the user would not be confused about what's going on.
Please let us know if this is something that Perfetto could support in the future, or if you have another idea on how we could provide a better user experience right now.
Of course we'd like to speed up the trace data generation as well, but it's not easy.
Thanks
Felix Geisendörfer (on behalf of the go runtime diagnostics working group)