socketioxide
socketioxide copied to clipboard
feat(socketio/extensions): rework extensions and add an `Extension` decorator and an `HttpExtension` decorator
Modify the Extension implementation
- Use a
RwLock<HashMap>rather than aDashMapfor concurrent access. - Add a clone bound on the data and directly
Clonethe returned data fromget - Remove
get_mutfn
Add
- an
Extensionextractor. - an
HttpExtensionextractor that extracts from theHttpRequest.
Refactor
- Split the
extractmodule into submodules
Todo
- [ ] Update documentation
Resolves issue :
- #295
Bencher
| Report | Sat, April 20, 2024 at 05:52:22 UTC |
| Project | Socketioxide |
| Branch | feat-extensions-rework |
| Testbed | ubuntu-latest |
| Benchmark | Latency | Latency Results nanoseconds (ns) |
|---|---|---|
| engineio_packet/decode/Decode packet binary b64 | ➖ (view plot) | 75.545 |
| engineio_packet/decode/Decode packet message | ➖ (view plot) | 23.063 |
| engineio_packet/decode/Decode packet noop | ➖ (view plot) | 14.011 |
| engineio_packet/decode/Decode packet ping/pong | ➖ (view plot) | 14.025 |
| engineio_packet/decode/Decode packet ping/pong upgrade | ➖ (view plot) | 13.636 |
| engineio_packet/encode/Encode packet binary b64 | ➖ (view plot) | 53.287 |
| engineio_packet/encode/Encode packet message | ➖ (view plot) | 38.144 |
| engineio_packet/encode/Encode packet noop | ➖ (view plot) | 22.851 |
| engineio_packet/encode/Encode packet open | ➖ (view plot) | 315.720 |
| engineio_packet/encode/Encode packet ping/pong | ➖ (view plot) | 22.807 |
| engineio_packet/encode/Encode packet ping/pong upgrade | ➖ (view plot) | 22.960 |
| extensions/concurrent_get | ➖ (view plot) | 7.223 |
| extensions/concurrent_get_inserts | ➖ (view plot) | 15.560 |
| extensions/concurrent_inserts | ➖ (view plot) | 21.389 |
| socketio_packet/decode/Decode packet ack on / | ➖ (view plot) | 262.350 |
| socketio_packet/decode/Decode packet ack on /custom_nsp | ➖ (view plot) | 280.480 |
| socketio_packet/decode/Decode packet binary ack (b64) on / | ➖ (view plot) | 490.960 |
| socketio_packet/decode/Decode packet binary ack (b64) on /custom_nsp | ➖ (view plot) | 511.510 |
| socketio_packet/decode/Decode packet binary event (b64) on / | ➖ (view plot) | 574.170 |
| socketio_packet/decode/Decode packet binary event (b64) on /custom_nsp | ➖ (view plot) | 597.560 |
| socketio_packet/decode/Decode packet connect on / | ➖ (view plot) | 47.602 |
| socketio_packet/decode/Decode packet connect on /custom_nsp | ➖ (view plot) | 63.926 |
| socketio_packet/decode/Decode packet event on / | ➖ (view plot) | 331.020 |
| socketio_packet/decode/Decode packet event on /custom_nsp | ➖ (view plot) | 357.000 |
| socketio_packet/decode/Decode packet event with ack on / | ➖ (view plot) | 331.580 |
| socketio_packet/decode/Decode packet event with ack on /custom_nsp | ➖ (view plot) | 353.290 |
| socketio_packet/encode/Encode packet ack on / | ➖ (view plot) | 117.210 |
| socketio_packet/encode/Encode packet ack on /custom_nsp | ➖ (view plot) | 121.860 |
| socketio_packet/encode/Encode packet binary ack (b64) on / | ➖ (view plot) | 316.520 |
| socketio_packet/encode/Encode packet binary ack (b64) on /custom_nsp | ➖ (view plot) | 321.780 |
| socketio_packet/encode/Encode packet binary event (b64) on / | ➖ (view plot) | 392.100 |
| socketio_packet/encode/Encode packet binary event (b64) on /custom_nsp | ➖ (view plot) | 415.380 |
| socketio_packet/encode/Encode packet connect on / | ➖ (view plot) | 53.566 |
| socketio_packet/encode/Encode packet connect on /custom_nsp | ➖ (view plot) | 55.458 |
| socketio_packet/encode/Encode packet event on / | ➖ (view plot) | 122.230 |
| socketio_packet/encode/Encode packet event on /custom_nsp | ➖ (view plot) | 129.730 |
| socketio_packet/encode/Encode packet event with ack on / | ➖ (view plot) | 123.300 |
| socketio_packet/encode/Encode packet event with ack on /custom_nsp | ➖ (view plot) | 128.270 |
Bencher - Continuous Benchmarking
View Public Perf Page
Docs | Repo | Chat | Help
Bencher
| Report | Sat, April 20, 2024 at 06:01:19 UTC |
| Project | Socketioxide |
| Branch | feat-extensions-rework |
| Testbed | ubuntu-latest |
| Benchmark | Latency | Latency Results nanoseconds (ns) |
|---|---|---|
| engineio_packet/decode/Decode packet binary b64 | ➖ (view plot) | 79.447 |
| engineio_packet/decode/Decode packet message | ➖ (view plot) | 21.922 |
| engineio_packet/decode/Decode packet noop | ➖ (view plot) | 14.351 |
| engineio_packet/decode/Decode packet ping/pong | ➖ (view plot) | 14.336 |
| engineio_packet/decode/Decode packet ping/pong upgrade | ➖ (view plot) | 14.339 |
| engineio_packet/encode/Encode packet binary b64 | ➖ (view plot) | 53.396 |
| engineio_packet/encode/Encode packet message | ➖ (view plot) | 38.132 |
| engineio_packet/encode/Encode packet noop | ➖ (view plot) | 22.850 |
| engineio_packet/encode/Encode packet open | ➖ (view plot) | 313.890 |
| engineio_packet/encode/Encode packet ping/pong | ➖ (view plot) | 22.803 |
| engineio_packet/encode/Encode packet ping/pong upgrade | ➖ (view plot) | 23.010 |
| extensions/concurrent_get | ➖ (view plot) | 7.224 |
| extensions/concurrent_get_inserts | ➖ (view plot) | 15.519 |
| extensions/concurrent_inserts | ➖ (view plot) | 21.532 |
| socketio_packet/decode/Decode packet ack on / | ➖ (view plot) | 261.320 |
| socketio_packet/decode/Decode packet ack on /custom_nsp | ➖ (view plot) | 280.780 |
| socketio_packet/decode/Decode packet binary ack (b64) on / | ➖ (view plot) | 489.950 |
| socketio_packet/decode/Decode packet binary ack (b64) on /custom_nsp | ➖ (view plot) | 516.180 |
| socketio_packet/decode/Decode packet binary event (b64) on / | ➖ (view plot) | 559.700 |
| socketio_packet/decode/Decode packet binary event (b64) on /custom_nsp | ➖ (view plot) | 592.410 |
| socketio_packet/decode/Decode packet connect on / | ➖ (view plot) | 48.183 |
| socketio_packet/decode/Decode packet connect on /custom_nsp | ➖ (view plot) | 63.676 |
| socketio_packet/decode/Decode packet event on / | ➖ (view plot) | 337.670 |
| socketio_packet/decode/Decode packet event on /custom_nsp | ➖ (view plot) | 360.530 |
| socketio_packet/decode/Decode packet event with ack on / | ➖ (view plot) | 340.460 |
| socketio_packet/decode/Decode packet event with ack on /custom_nsp | ➖ (view plot) | 351.950 |
| socketio_packet/encode/Encode packet ack on / | ➖ (view plot) | 117.820 |
| socketio_packet/encode/Encode packet ack on /custom_nsp | ➖ (view plot) | 121.890 |
| socketio_packet/encode/Encode packet binary ack (b64) on / | ➖ (view plot) | 320.860 |
| socketio_packet/encode/Encode packet binary ack (b64) on /custom_nsp | ➖ (view plot) | 323.190 |
| socketio_packet/encode/Encode packet binary event (b64) on / | ➖ (view plot) | 398.970 |
| socketio_packet/encode/Encode packet binary event (b64) on /custom_nsp | ➖ (view plot) | 416.600 |
| socketio_packet/encode/Encode packet connect on / | ➖ (view plot) | 53.120 |
| socketio_packet/encode/Encode packet connect on /custom_nsp | ➖ (view plot) | 55.505 |
| socketio_packet/encode/Encode packet event on / | ➖ (view plot) | 122.470 |
| socketio_packet/encode/Encode packet event on /custom_nsp | ➖ (view plot) | 128.750 |
| socketio_packet/encode/Encode packet event with ack on / | ➖ (view plot) | 123.420 |
| socketio_packet/encode/Encode packet event with ack on /custom_nsp | ➖ (view plot) | 128.660 |
Bencher - Continuous Benchmarking
View Public Perf Page
Docs | Repo | Chat | Help
Bencher
| Report | Sun, April 21, 2024 at 21:38:06 UTC |
| Project | Socketioxide |
| Branch | feat-extensions-rework |
| Testbed | ubuntu-latest |
| Benchmark | Latency | Latency Results nanoseconds (ns) |
|---|---|---|
| engineio_packet/decode/Decode packet binary b64 | ➖ (view plot) | 86.212 |
| engineio_packet/decode/Decode packet message | ➖ (view plot) | 46.595 |
| engineio_packet/decode/Decode packet noop | ➖ (view plot) | 36.148 |
| engineio_packet/decode/Decode packet ping/pong | ➖ (view plot) | 31.330 |
| engineio_packet/decode/Decode packet ping/pong upgrade | ➖ (view plot) | 35.504 |
| engineio_packet/encode/Encode packet binary b64 | ➖ (view plot) | 54.634 |
| engineio_packet/encode/Encode packet message | ➖ (view plot) | 30.034 |
| engineio_packet/encode/Encode packet noop | ➖ (view plot) | 30.039 |
| engineio_packet/encode/Encode packet open | ➖ (view plot) | 289.240 |
| engineio_packet/encode/Encode packet ping/pong | ➖ (view plot) | 29.488 |
| engineio_packet/encode/Encode packet ping/pong upgrade | ➖ (view plot) | 29.800 |
| extensions/concurrent_get | ➖ (view plot) | 7.228 |
| extensions/concurrent_get_inserts | ➖ (view plot) | 15.521 |
| extensions/concurrent_inserts | ➖ (view plot) | 21.428 |
| socketio_packet/decode/Decode packet ack on / | ➖ (view plot) | 277.530 |
| socketio_packet/decode/Decode packet ack on /custom_nsp | ➖ (view plot) | 291.820 |
| socketio_packet/decode/Decode packet binary ack (b64) on / | ➖ (view plot) | 512.680 |
| socketio_packet/decode/Decode packet binary ack (b64) on /custom_nsp | ➖ (view plot) | 548.620 |
| socketio_packet/decode/Decode packet binary event (b64) on / | ➖ (view plot) | 584.780 |
| socketio_packet/decode/Decode packet binary event (b64) on /custom_nsp | ➖ (view plot) | 591.140 |
| socketio_packet/decode/Decode packet connect on / | ➖ (view plot) | 62.898 |
| socketio_packet/decode/Decode packet connect on /custom_nsp | ➖ (view plot) | 78.104 |
| socketio_packet/decode/Decode packet event on / | ➖ (view plot) | 345.020 |
| socketio_packet/decode/Decode packet event on /custom_nsp | ➖ (view plot) | 361.150 |
| socketio_packet/decode/Decode packet event with ack on / | ➖ (view plot) | 346.750 |
| socketio_packet/decode/Decode packet event with ack on /custom_nsp | ➖ (view plot) | 364.070 |
| socketio_packet/encode/Encode packet ack on / | ➖ (view plot) | 119.740 |
| socketio_packet/encode/Encode packet ack on /custom_nsp | ➖ (view plot) | 122.110 |
| socketio_packet/encode/Encode packet binary ack (b64) on / | ➖ (view plot) | 317.030 |
| socketio_packet/encode/Encode packet binary ack (b64) on /custom_nsp | ➖ (view plot) | 319.830 |
| socketio_packet/encode/Encode packet binary event (b64) on / | ➖ (view plot) | 416.210 |
| socketio_packet/encode/Encode packet binary event (b64) on /custom_nsp | ➖ (view plot) | 422.040 |
| socketio_packet/encode/Encode packet connect on / | ➖ (view plot) | 52.921 |
| socketio_packet/encode/Encode packet connect on /custom_nsp | ➖ (view plot) | 55.271 |
| socketio_packet/encode/Encode packet event on / | ➖ (view plot) | 124.380 |
| socketio_packet/encode/Encode packet event on /custom_nsp | ➖ (view plot) | 128.450 |
| socketio_packet/encode/Encode packet event with ack on / | ➖ (view plot) | 125.310 |
| socketio_packet/encode/Encode packet event with ack on /custom_nsp | ➖ (view plot) | 128.960 |
Bencher - Continuous Benchmarking
View Public Perf Page
Docs | Repo | Chat | Help
Bencher
| Report | Tue, June 4, 2024 at 09:51:31 UTC |
| Project | Socketioxide |
| Branch | feat-extensions-rework |
| Testbed | ubuntu-latest |
⚠️ WARNING: The following Measure does not have a Threshold. Without a Threshold, no Alerts will ever be generated!
- Latency (latency)
Click here to create a new Threshold
For more information, see the Threshold documentation.
To only post results if a Threshold exists, set the--ci-only-thresholdsCLI flag.
Click to view all benchmark results
| Benchmark | Latency | Latency Results nanoseconds (ns) |
|---|---|---|
| engineio_packet/decode/Decode packet binary b64 | ➖ (view plot) | 88.41 |
| engineio_packet/decode/Decode packet message | ➖ (view plot) | 38.95 |
| engineio_packet/decode/Decode packet noop | ➖ (view plot) | 35.65 |
| engineio_packet/decode/Decode packet ping/pong | ➖ (view plot) | 31.09 |
| engineio_packet/decode/Decode packet ping/pong upgrade | ➖ (view plot) | 35.08 |
| engineio_packet/encode/Encode packet binary b64 | ➖ (view plot) | 56.15 |
| engineio_packet/encode/Encode packet message | ➖ (view plot) | 30.88 |
| engineio_packet/encode/Encode packet noop | ➖ (view plot) | 29.74 |
| engineio_packet/encode/Encode packet open | ➖ (view plot) | 286.55 |
| engineio_packet/encode/Encode packet ping/pong | ➖ (view plot) | 29.55 |
| engineio_packet/encode/Encode packet ping/pong upgrade | ➖ (view plot) | 29.63 |
| extensions/concurrent_get | ➖ (view plot) | 6.81 |
| extensions/concurrent_get_inserts | ➖ (view plot) | 14.91 |
| extensions/concurrent_inserts | ➖ (view plot) | 21.08 |
| socketio_packet/decode/Decode packet ack on / | ➖ (view plot) | 282.49 |
| socketio_packet/decode/Decode packet ack on /custom_nsp | ➖ (view plot) | 297.67 |
| socketio_packet/decode/Decode packet binary ack (b64) on / | ➖ (view plot) | 498.63 |
| socketio_packet/decode/Decode packet binary ack (b64) on /custom_nsp | ➖ (view plot) | 529.78 |
| socketio_packet/decode/Decode packet binary event (b64) on / | ➖ (view plot) | 596.15 |
| socketio_packet/decode/Decode packet binary event (b64) on /custom_nsp | ➖ (view plot) | 622.54 |
| socketio_packet/decode/Decode packet connect on / | ➖ (view plot) | 62.53 |
| socketio_packet/decode/Decode packet connect on /custom_nsp | ➖ (view plot) | 80.56 |
| socketio_packet/decode/Decode packet event on / | ➖ (view plot) | 356.08 |
| socketio_packet/decode/Decode packet event on /custom_nsp | ➖ (view plot) | 375.10 |
| socketio_packet/decode/Decode packet event with ack on / | ➖ (view plot) | 357.17 |
| socketio_packet/decode/Decode packet event with ack on /custom_nsp | ➖ (view plot) | 382.98 |
| socketio_packet/encode/Encode packet ack on / | ➖ (view plot) | 116.51 |
| socketio_packet/encode/Encode packet ack on /custom_nsp | ➖ (view plot) | 120.24 |
| socketio_packet/encode/Encode packet binary ack (b64) on / | ➖ (view plot) | 310.42 |
| socketio_packet/encode/Encode packet binary ack (b64) on /custom_nsp | ➖ (view plot) | 320.12 |
| socketio_packet/encode/Encode packet binary event (b64) on / | ➖ (view plot) | 391.82 |
| socketio_packet/encode/Encode packet binary event (b64) on /custom_nsp | ➖ (view plot) | 410.16 |
| socketio_packet/encode/Encode packet connect on / | ➖ (view plot) | 52.63 |
| socketio_packet/encode/Encode packet connect on /custom_nsp | ➖ (view plot) | 55.43 |
| socketio_packet/encode/Encode packet event on / | ➖ (view plot) | 119.66 |
| socketio_packet/encode/Encode packet event on /custom_nsp | ➖ (view plot) | 124.45 |
| socketio_packet/encode/Encode packet event with ack on / | ➖ (view plot) | 120.93 |
| socketio_packet/encode/Encode packet event with ack on /custom_nsp | ➖ (view plot) | 123.37 |
Bencher - Continuous Benchmarking
View Public Perf Page
Docs | Repo | Chat | Help