How to log WebSocket data frames

2,038 views
Skip to first unread message

Alessandro Manzi

unread,
May 19, 2016, 2:52:03 AM5/19/16
to Google Chrome Developer Tools
I am trying to inspect WebSocket communication. Using the Dev Tool -> Network I can see the information and I am able to save them in HAR.
But the HAR seems to contain only the header of the packets. I want to store also the data (text data) and timestamp of the WebSocket packet.
I can see these data with the Dev Tool on Network -> WS -> Frames. But I do not know how to export. If I simply select the text lines, I can copy and paste
only the part that is visible on the screen, but I have hundreds of data.
Is it possible to log them all?
Thanks!

Blaise Bruer

unread,
May 19, 2016, 1:46:26 PM5/19/16
to Google Chrome Developer Tools
This is something that is not possible to put into HAR format at this time because HAR specification does not have details on how to export framed transfer formats like WebSockets. I did a quick search and found a request to make a HAR format that would support framed transfer types here: https://groups.google.com/forum/#!topic/http-archive-specification/_DBaSKch_-s .

As for now I'm sorry, but I do not see how we could follow the HAR spec and give all the data that WebSockets give. Please feel free to bring the topic up to web-perf mailing list and see if a spec could be hammered out.
Reply all
Reply to author
Forward
0 new messages