initial version of permance/network check tool

The current situation for performance measurements and checking network
behaviour is rather unsatisfactory, as the only tools available are
``pubsub`` and the ``roundtrip`` and ``throughput`` examples.  The first
can do many things thanks to its thousand-and-one options, but its
purpose really is to be able to read/write arbitrary data with arbitrary
QoS -- though the arbitrary data bit was lost in the hacked conversion
from the original code.  The latter two have a terrible user interface,
don't perform any verification that the measurement was successful and
do not provide the results in a convenient form.

Furthermore, the abuse of the two examples as the primary means for
measuring performance has resulted in a reduction of their value as an
example, e.g., they can do waitset- or listener-based reading (and the
throughput one also polling-based), but that kind of complication does
not help a new user understand what is going on.  Especially not given
that these features were simply hacked in.

Hence the need for a new tool, one that integrates the common
measurements and can be used to verify that the results make sense.  It
is not quite done yet, in particular it is lacking in a number of
aspects:

* no measurement of CPU- and network load, memory usage and context
  switches yet;
* very limited statistics (min/max/average, if you're lucky; no
  interesting things such as jitter on a throughput test yet);
* it can't yet gather the data from all participants in the network
  using DDS;
* it doesn't output the data in a convenient file format yet;
* it doesn't allow specifying boundaries within which the results
  must fall for the run to be successful.

What it does verify is that all the endpoint matches that should exist
given the discovered participant do in fact come into existence,
reporting an error (and exiting with an exit status code of 1) if they
don't, as well as checking the number of participants.  With the way the
DDSI protocol works, this is a pretty decent network connectivity check.

The raw measurements needed for the desired statistics (apart from
system-level measurements) are pretty much made, so the main thing that
still needs to be done is exploit them and output them.  It can already
replace the examples for most benchmarks (only the 50%/90%/99%
percentiles are still missing for a complete replacement).

Signed-off-by: Erik Boasson <eb@ilities.com>
This commit is contained in:
Erik Boasson 2019-04-15 11:52:43 +02:00 committed by eboasson
parent 46f61e09f5
commit 06245d0d4a
5 changed files with 2091 additions and 3 deletions

View file

@ -13,6 +13,7 @@ set(CMAKE_INSTALL_TOOLSDIR "${CMAKE_INSTALL_DATADIR}/${CMAKE_PROJECT_NAME}/tools
add_subdirectory(pubsub)
add_subdirectory(config)
add_subdirectory(ddsls)
add_subdirectory(ddsperf)
# VxWorks build machines use OpenJDK 8, which lack jfxrt.jar. Do not build launcher on that platform.
#

View file

@ -0,0 +1,23 @@
#
# Copyright(c) 2006 to 2018 ADLINK Technology Limited and others
#
# This program and the accompanying materials are made available under the
# terms of the Eclipse Public License v. 2.0 which is available at
# http://www.eclipse.org/legal/epl-2.0, or the Eclipse Distribution License
# v. 1.0 which is available at
# http://www.eclipse.org/org/documents/edl-v10.php.
#
# SPDX-License-Identifier: EPL-2.0 OR BSD-3-Clause
#
idlc_generate(ddsperf_types ddsperf_types.idl)
add_executable(ddsperf ddsperf.c)
target_link_libraries(ddsperf ddsperf_types ddsc)
if(WIN32)
target_compile_definitions(ddsperf PRIVATE _CRT_SECURE_NO_WARNINGS)
endif()
install(
TARGETS ddsperf
DESTINATION "${CMAKE_INSTALL_BINDIR}"
COMPONENT dev
)

2036
src/tools/ddsperf/ddsperf.c Normal file

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,29 @@
struct OneULong
{
unsigned long seq;
};
#pragma keylist OneULong
struct Keyed32
{
unsigned long seq;
unsigned long keyval;
octet baggage[24];
};
#pragma keylist Keyed32 keyval
struct Keyed256
{
unsigned long seq;
unsigned long keyval;
octet baggage[248];
};
#pragma keylist Keyed256 keyval
struct KeyedSeq
{
unsigned long seq;
unsigned long keyval;
sequence<octet> baggage;
};
#pragma keylist KeyedSeq keyval