As i understand, when i make several threads with socket.io connection, it takes too match time to iterate all received messages for matching one. So connection crashes. In normal situation if client doesn’t send any message for some time, server sends ping message to check connection is still available. is there some practices to handle it in gatling?
Gatling automatically replies to Ping frames with a Pong one.
so what could be reason for crashing then?
четверг, 6 августа 2020 г. в 11:12:44 UTC+3, Stéphane Landelle:
No idea, can’t investigate without you providing a reproducer.
From terms:
Provide a Short, Self Contained, Correct (Compilable), Example (see http://sscce.org/)
i’ve realized that in my situation not server but client should send ping messages. is it possible to set it with base gatling settings or override somehow the “matching” method? it makes me worry that the library is realized like builder and i didn’t find the methods signature.
четверг, 6 августа 2020 г. в 12:15:34 UTC+3, Stéphane Landelle:
No, it’s not possible atm.
Contributions welcome (or become a FrontLine customer and we’ll consider raising priority on our side).
FYI, I’ve logged a feature request: https://github.com/gatling/gatling/issues/3929
ok,
thks anyway
четверг, 6 августа 2020 г. в 13:26:01 UTC+3, Stéphane Landelle:
I see nothing in socket.io’s client API for configuring sending periodic pings to the server. I’m not even sure there’s a JavaScript API for this.
I do see a pingInterval option on the server API though. Browsers automatically reply to ping frames sent by the server with pong ones, just like Gatling does, as it’s required by the spec. However, they don’t automatically send ping frames, that would be a waste of bandwidth and battery.
Are you sure your clients send such ping frames to the server? How do they do that? Do you have any pointers on how socket.io does that please?
that how it looks like in chrome devtools console: client sends ping (message with only code-number “2”) and receives pong (server-message wich contains 3)
четверг, 6 августа 2020 г. в 14:05:49 UTC+3, Stéphane Landelle:
OK, so those are absolutely not WebSocket Ping and Pong frames.
Those are Data frames, specific to socket.io/Engine.io’s heartbeat mechanism (see https://socket.io/docs/ “Disconnection detection”).
but yet, if it cant be set “from box”, is it possible to build-in into gatling scenario-builder sequence a kind of self-written timer? or to I’m not very experienced in Scala and anyway there is no possibility to overwrite final method. but i try to find some workaround to solve the problem
четверг, 6 августа 2020 г. в 16:46:00 UTC+3, Stéphane Landelle: