Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds an application (hub_test) for testing the throughput of a hub or a CAN-bus #762

Merged
merged 47 commits into from
Feb 2, 2024

Conversation

balazsracz
Copy link
Collaborator

Adds a new application to OpenMRN called hub_test. This application can generate a specific amount of traffic, send it to a bus (a CAN-bus or a gridconnect-TCP hub). A second component is a receiver, which listens to traffic on the same OpenLCB bus. It verifies that data arrives without dropped packets, in order, and prints statistics about throughput and round-trip time (which correlates with buffer length).

Adds a structure for recording timestamps per packet.
Applies the gridconnect use select link option.
Applies the SO_SNDBUF/RCVBUF link option.
When a dispatcher was used to send traffic to a gridconnect bridge,
an infinite number of packets were allocated in the dispatcher when more than
one client was connected.

By adding a limitedpool to the bridge object, we can ensure that the dispatcher is blocked when
the output queue pushes back.
When a dispatcher was used to send traffic to a gridconnect bridge,
an infinite number of packets were allocated in the dispatcher when more than
one client was connected.

By adding a limitedpool to the bridge object, we can ensure that the dispatcher is blocked when
the output queue pushes back.
…b-test-app

* commit '4bd04c6c81b987a82f5f399bd104fb0eeb9b2f7b':
  Limits end to end buffering in gridconnect bridge.
* bracz-hub-bridge-limit-pool:
  fix whitespace
* bracz-exec-multi-thread-assert:
  Ensures that an executor thread can not be created twice.
Applies the gridconnect use select link option.
Applies the SO_SNDBUF/RCVBUF link option.
…b-test-app

* commit 'ea41047b1bc27c2cc29e4b5ba303b9bb10096009':
  Refactors the fd optimization code to FdUtils class.
  Sorts lines in sources.
  Ensures that the ClientCOnnection.cxx is built and linked.
  client connection util: exposes the file descriptor when available. Applies the gridconnect use select link option. Applies the SO_SNDBUF/RCVBUF link option.
  gc-tcp-hub: applies SO_SNDBUF and SO_RCVBUF options to sockets.
  Optimizes the memory and buffer use of the hub application.
  Adds constants for TCP socket options fo SO_SNDBUF and SO_RCVBUF
* bracz-optimize-tcp-socket:
  Adds comment.
  Fix compile error.
  Makes tcp_lowat also configurable.
This needs no dedicated memory, but uses the regular mainBufferPool.

Add a check that all outgoing packets are released before deleting the pool.
This solves hub crashing when a client disconnects.
This needs no dedicated memory, but uses the regular mainBufferPool.

Add a check that all outgoing packets are released before deleting the pool.
This solves hub crashing when a client disconnects.
* bracz-optimize-tcp-socket:
  Tune TCP options.
  Switch gridconnect hub to LimitedPool instead of FixedPool. This needs no dedicated memory, but uses the regular mainBufferPool.
* master:
  Adds configuration options for TCP sockets, tuning for Hub app. (#759)
  Limits end to end buffering in gridconnect bridge. (#758)
  Ensures that an executor thread can not be created twice. (#757)
  Fixes build_bootloader_img.py. (#755)
* bracz-optimize-tcp-socket:
  Adds configuration options for TCP sockets, tuning for Hub app. (#759)
  Limits end to end buffering in gridconnect bridge. (#758)
  Ensures that an executor thread can not be created twice. (#757)
  Fixes build_bootloader_img.py. (#755)
- support creating multiple TCP clients with -N number
- support sending different packets, like identify producer and verify node ID
  which allows measuring response latency of a node.
* master:
  Fix test flakiness.
  Fix compile error on FdUtils under freertos.
@balazsracz balazsracz merged commit 2caa136 into master Feb 2, 2024
4 checks passed
@balazsracz balazsracz deleted the bracz-hub-test-app branch February 2, 2024 11:57
balazsracz added a commit that referenced this pull request Feb 2, 2024
* master:
  Fixes file comment.
  Adds an application (hub_test) for testing the throughput of a hub or a CAN-bus (#762)
  Adds a helper function to decode a 14-bit 9.2.1.1 address into address type and raw address. (#766)
  Fix broken test.
  Accessory packet refactoring and POM support (#764)
  Adds support for Offset(n) attribute in the CDI  (#765)
  Adds local loopback to TractionThrottle. (#756)
  Fix test flakiness.
  Fix compile error on FdUtils under freertos.
balazsracz added a commit that referenced this pull request Feb 4, 2024
* master:
  Fix incorrect consumer identified message being emitted by dcc accy producer. (#768)
  Avoids rendering hidden segments. (#767)
  Adds trailing zero to the cdi XML file written to the filesystem. (#777)
  Fix target subdirectory name (#775)
  Fixes file comment.
  Adds an application (hub_test) for testing the throughput of a hub or a CAN-bus (#762)
balazsracz added a commit that referenced this pull request Feb 4, 2024
* bracz-consumer-id-range-fix:
  Fix incorrect consumer identified message being emitted by dcc accy producer. (#768)
  Avoids rendering hidden segments. (#767)
  Adds trailing zero to the cdi XML file written to the filesystem. (#777)
  Fix target subdirectory name (#775)
  Fixes file comment.
  Adds an application (hub_test) for testing the throughput of a hub or a CAN-bus (#762)
balazsracz added a commit that referenced this pull request Feb 4, 2024
* master:
  Upintegrate changes from the OpenMRNIDF repository (#771)
  Adds support for DCC extended accessories  (#769)
  Fix incorrect consumer identified message being emitted by dcc accy producer. (#768)
  Avoids rendering hidden segments. (#767)
  Adds trailing zero to the cdi XML file written to the filesystem. (#777)
  Fix target subdirectory name (#775)
  Fixes file comment.
  Adds an application (hub_test) for testing the throughput of a hub or a CAN-bus (#762)
  Adds a helper function to decode a 14-bit 9.2.1.1 address into address type and raw address. (#766)
  Fix broken test.
  Accessory packet refactoring and POM support (#764)
  Adds support for Offset(n) attribute in the CDI  (#765)
  Adds local loopback to TractionThrottle. (#756)
  Fix test flakiness.
  Fix compile error on FdUtils under freertos.
balazsracz added a commit that referenced this pull request Feb 4, 2024
* bracz-idf-downintegrate:
  Upintegrate changes from the OpenMRNIDF repository (#771)
  Fix comments.
  Adds support for DCC extended accessories  (#769)
  Fix incorrect consumer identified message being emitted by dcc accy producer. (#768)
  Avoids rendering hidden segments. (#767)
  Adds trailing zero to the cdi XML file written to the filesystem. (#777)
  Fix target subdirectory name (#775)
  Fixes file comment.
  Adds an application (hub_test) for testing the throughput of a hub or a CAN-bus (#762)
  Adds a helper function to decode a 14-bit 9.2.1.1 address into address type and raw address. (#766)
  Fix broken test.
  Accessory packet refactoring and POM support (#764)
  Adds support for Offset(n) attribute in the CDI  (#765)
  Adds local loopback to TractionThrottle. (#756)
  Fix test flakiness.
  Fix compile error on FdUtils under freertos.
balazsracz added a commit that referenced this pull request Feb 5, 2024
* master:
  Fix esp32 select race conditions. (#780)
  Latency test with maximum stats and custom process evaluation (#773)
  Fix compiler warnings in openmrn when using new GCC's. (#772)
  Upintegrate changes from the OpenMRNIDF repository (#771)
  Adds support for DCC extended accessories  (#769)
  Fix incorrect consumer identified message being emitted by dcc accy producer. (#768)
  Avoids rendering hidden segments. (#767)
  Adds trailing zero to the cdi XML file written to the filesystem. (#777)
  Fix target subdirectory name (#775)
  Fixes file comment.
  Adds an application (hub_test) for testing the throughput of a hub or a CAN-bus (#762)
  Adds a helper function to decode a 14-bit 9.2.1.1 address into address type and raw address. (#766)
  Fix broken test.
  Accessory packet refactoring and POM support (#764)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants