A prototype program for PoC (Proof of Concept), is used to check and compare the latency performance between MQTT over TCP and MQTT over KCP.
DO NOT USE THE PROJECT IN PRODUCTION ENVIRONMENT!
├───experiment: experiment code for IFN712
├───kcp: mqtt over kcp implementation
├───mqttsrv: a basic mqtt broker supporting both tcp and kcp
├───pub: a minimum mqtt over kcp publisher
├───sub: a minimum mqtt over kcp subscriber
├───tcp: mqtt over tcp implementation
└───visual: data visualization
graph LR
A["local client 1"]
B["broker on cloud"]
C["local client 2"]
A -- step0: subscribe /pingtest/tcp/request --> B
C -- step0: subscribe /pingtest/tcp/reply --> B
A -- step1: sending /pingtest/tcp/request --> B
B -- step2: forward /pingtest/tcp/request --> C
C -- step3: sending /pingtest/tcp/reply --> B
B -- step4: forward /pingtest/tcp/reply --> A
A -- step5: subscribe /pingtest/kcp/request --> B
C -- step5: subscribe /pingtest/kcp/reply --> B
A -- step6: sending /pingtest/kcp/request --> B
B -- step7: forward /pingtest/kcp/request --> C
C -- step8: sending /pingtest/kcp/reply --> B
B -- step9: forward /pingtest/kcp/reply --> A
The program will record all test records into a .xlsx
file for analysis purposes.
The experiment needs to be performed in different environments/configurations
Env | Options |
---|---|
Request Interval | 0.1s , 0.5s , 1s |
Message Payload Size | 60 bytes , 500 bytes , 1500 bytes |
Network Conditions | Ethernet , Wifi , Mobile 4G static , Mobile 4G while moving |
Env | Options |
---|---|
Request Interval | 0.1s , 0.5s , 1s |
Message Payload Size | 5000 bytes , 10000 bytes |
Network Conditions | Ethernet , Wifi , Mobile 4G static |
Special appreciation to these open-source projects and their extraordinary contribution to the research project.