Comments (6)
I tried the same thing using node-red and the same latency is observed
Can you elaborate on this part? Do you observe ~10ms latency with node-red as well? If so, it could be a problem with the test setup, e.g. client side buffering.
from emqx.
client side buffering.
listeners.tcp.my_tcp_listener_name {
bind = 1883
tcp_options {
nodelay = true
}
}
I added this to my configuration file to attempt to disable nagle's algorithm, but It doesnt seem to change anything , is there a way to test that ?
from emqx.
My question was: do you observe the same end-to-end latency with both EMQX and node-red? If so, it could be a problem with the load generator (e.g. paho client does buffering on its own, or there is some GIL issue with python).
This can be easily ruled out by inspecting a wireshark trace.
In my tests (1 pub -> 1 sub using emqtt
client on Linux), the average round-trip latency is ~0.5 ms.
Also, if you use Rule Engine with some heavy rules the latency can increase.
from emqx.
do you observe the same end-to-end latency with both EMQX and node-red?
yes using both the python script and node-red , I observe same ~10ms latency , the broker is on the same machine
wire shark trace using python script
wireshark trace using node-red
In my tests (1 pub -> 1 sub using emqtt client on Linux), the average round-trip latency is ~0.5 ms.
hmm can you confirm latency stays the same at a high frequency , like sending a small packet every 100ms
from emqx.
hmm can you confirm latency stays the same at a high frequency , like sending a small packet every 100ms
I used the following script ./emqttb --pushgw @pub --pubinterval 100ms -N 1 --metadata -t foo/%n @sub -N 1 --parse-metadata -t foo/#
(emqttb
is a wrapper for emqtt
that turns it into a scriptable loadgen) which essentially emulates your setup. Results look like this:
Another reason for increased latency could be a large number of inactive clients that subscribe to the topics without any traffic. This can make routing table lookups slower.
from emqx.
I close this ticket, because:
- We highlighted some causes for the increased latency.
- In the original test the packets go through the LAN (
192.168.1.100
), it adds network latency that we cannot control - My attempts to reproduce the problem in a more controlled environment (packets are routed through
lo
) weren't successful - Windows build is intended for local prototyping only, we don't tune it for high throughput/low latency whatsoever.
from emqx.
Related Issues (20)
- Can't add users on touch screen device HOT 7
- Action output to external HTTP server - authorization header issue HOT 2
- The client disconnects after publish message whose topic starts with '$' HOT 2
- Not getting Emqx dashboard HOT 1
- EMQX Clustering - Message Replication HOT 4
- STOMP GW does not send heartbeat to client HOT 4
- EMQX cluster cannot restart after persistence HOT 1
- After STOMP enables authentication, authentication fails when the account password carries a colon
- runq_overload everyday for few minutes HOT 4
- Receive Maximum Not Sent in Bridge CONNACK HOT 4
- webhook监听上下线事件时,事件时序有误,原因不明(connected and disconnected events may out of order) HOT 3
- Authentication fails periodically and restart fixes it HOT 9
- For my project required kafka and kerberos integration with EMQX opensource,So any how is it possible to do these integration with Emqx OPenSource version HOT 2
- Get acknowledgement from subscriber(s) after publish messages HOT 2
- Restored retained message have no payload HOT 2
- error messages received and MQTT broker keep running up and down, very HOT 4
- Several protocol violations or bugs in EMQX HOT 26
- Upgrade to Openssl 3.0 or higher HOT 7
- LDAP server treated as down due to wrong error returned than expected? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from emqx.