Coder Social home page Coder Social logo

Filter frames about websocket-monitor HOT 6 OPEN

firebug avatar firebug commented on September 28, 2024 1
Filter frames

from websocket-monitor.

Comments (6)

janodvarko avatar janodvarko commented on September 28, 2024

@esphen What do you think?

Honza

from websocket-monitor.

eliihen avatar eliihen commented on September 28, 2024

@janodvarko

Yeah, it's been annoying me at work too. We send ping and pong frames once every 30 sec or so, even though we don't use Socket.IO :)

I think in some circumstances it would be useful to see the ping frames, i.e. when you're implementing the ping functionality. So we could say that the user can enable the ping frames with a pref in the addons panel.

What do ping frames in the different protocols look like? What should we hide?

At work we use simple frames that say ping or pong, so exact matches on those can be filtered out.

Are these 1B frames socket.io ping frames?

screenshot_20160304_215158

What about Sock.JS and WAMP? Do you know any conventions for pinging?

I can have a look at some way to implement this when I get time. This weekend maybe.

from websocket-monitor.

janodvarko avatar janodvarko commented on September 28, 2024

I think in some circumstances it would be useful to see the ping frames,

Definitely. I wasn't thinking about hiding these frames entirely, but rather provide a UI that allows the user to do that if wanted.

What do ping frames in the different protocols look like? What should we hide?

Of course, there can be many 'ping' messages, protocol based or custom like you have...

It's currently possible to filter frames using search box in the toolbar. Fox example, if you type tweet into it, only frames with tweat string in the payload will be displayed. Perhaps we could make this filter box smarter and allow to filter out frames that represents a 'ping' message.

I don't know about the syntax, but e.g. !ping would hide all frames with ping in the payload?
Or ! would hide frames with empty content? Are there any existing tools we could take an inspiration from. Does Wireshark have any standard syntax for filtering?

We might want to remember the filter in the UI (directly in the search box or in a recent filter list?) so, it's simple to set it again the next time.

Honza

from websocket-monitor.

eliihen avatar eliihen commented on September 28, 2024

@janodvarko

I don't know about the syntax, but e.g. !ping would hide all frames with ping in the payload?

Netmonitor uses something like this. They have a - syntax where you can write -ping to get anything that does not contain ping. We could do that to stay consistent with our sibling tools.

Does Wireshark have any standard syntax for filtering?

Yes, they got a brief introduction here. They use == with values on fields to confer equality, ! to negate expressions, and have predefined protocols like smb that only show samba traffic. It seems like a very intricate system, and albeit powerful, may be a bit overkill for us.

Or ! would hide frames with empty content?

I think !ping could hide both empty messages and ping, so the user wouldn't have to write something like !ping ! !pong which looks quite silly.

Speaking of which, should the user be allowed to enter several of these filters? How do we handle that? One suggestion is to use commas to separate expressions, i.e. !ping,!pong. Alternatively we can do what Wireshark does and use &&. Thoughts?

We might want to remember the filter in the UI (directly in the search box or in a recent filter list?)

Sure, we can do this with simple storage or similar. What is more interesting is how we would display them in the GUI. I was reminded of your suggestion in a different issue earlier to make a box like in the debugger panel. We could do something like that?

I drew a sketch of the idea. Please excuse the SUPER rough draft; I'm not a graphical designer 😄

sketch

from websocket-monitor.

gsdaemon avatar gsdaemon commented on September 28, 2024

Would be just nice to have an option in the settings for hiding ping-pong requests

from websocket-monitor.

janodvarko avatar janodvarko commented on September 28, 2024

Netmonitor uses something like this. They have a - syntax where you can write -ping to get anything that > does not contain ping. We could do that to stay consistent with our sibling tools.

I like the idea

I think !ping could hide both empty messages and ping, so the user wouldn't have to write something like
!ping ! !pong which looks quite silly.

Also agree

Speaking of which, should the user be allowed to enter several of these filters? How do we handle that?
One suggestion is to use commas to separate expressions, i.e. !ping,!pong.

Commas sounds good to me.

I also like the screenshot (with popup box). We can do it in a second step (also such UI could be reused in the Net panel).

Honza

from websocket-monitor.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.