diff --git a/README.md b/README.md index 6ad141c..3817027 100644 --- a/README.md +++ b/README.md @@ -1,52 +1,137 @@ # Eclipse Cyclone DDS -Eclipse Cyclone DDS is by far the most performant and robust DDS implementation available on the market. - -Beside, Cyclone DDS is developed completely in the open and is undergoing the acceptance process to become part of Eclipse IoT (see [eclipse-cyclone-dds](https://projects.eclipse.org/proposals/eclipse-cyclone-dds)). - +Eclipse Cyclone DDS is by far the most performant and robust DDS implementation available on the +market. Moreover, Cyclone DDS is developed completely in the open as an Eclipse IoT project +(see [eclipse-cyclone-dds](https://projects.eclipse.org/projects/iot.cyclonedds)). # Getting Started -## Building Cyclone DDS -In order to build cyclone DDS you need to have installed on your host [cmake](https://cmake.org/download/) **v3.6.0** or higher, the [Java 8 JDK](http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html) or simply the [Java 8 RE](http://www.oracle.com/technetwork/java/javase/downloads/server-jre8-downloads-2133154.html), and [Apache Maven 3.5.x or higher](http://maven.apache.org/download.cgi). +## Building Eclipse Cyclone DDS -Assuming that **git** is also available on your machine then, simply do: +In order to build Cyclone DDS you need a Linux, Mac or Windows 10 machine with the following +installed on your host: - $ git clone https://github.com/eclipse/cyclonedds.git + * [CMake](https://cmake.org/download/), version 3.7 or later. (Version 3.6 should work but you + will have to edit the ``cmake_minimum_required`` version and may have to disable building the + tests.) + * [OpenSSL](https://www.openssl.org/), preferably version 1.1 or later. If you wish, you can + build without support for OpenSSL by setting DDSC\_ENABLE\_OPENSSL to FALSE on the ``cmake `` + command line (i.e., ``cmake -DDDSC_ENABLE_OPENSSL=FALSE`` ../src). In that, there is no need to + have openssl available. + * Java JDK, version 8 or later, e.g., [OpenJDK 11](http://jdk.java.net/11/). + * [Apache Maven](http://maven.apache.org/download.cgi), version 3.5 or later. + +The Java-based components are the preprocessor and a configurator tool. The run-time libraries are +pure C code, so there is no need to have Java available on "target" machines. + +To obtain Eclipse Cyclone DDS, do + + $ git clone https://github.com/eclipse-cyclonedds/cyclonedds.git $ cd cyclonedds $ mkdir build + +Depending on whether you want to develop applications using Cyclone DDS or contribute to it you can +follow different procedures + +### For application developers + +To build and install the required libraries needed to develop your own applications using Cyclone +DDS requires a few simple steps. There are some small differences between Linux and macOS on the one +hand, and Windows on the other. For Linux or macOS: + $ cd build - $ cmake ../src - $ make - $ make install + $ cmake -DCMAKE_INSTALL_PREFIX= ../src + $ cmake --build . -At this point you are ready to use **cyclonedds** for your next DDS project! +and for Windows: + $ cd build + $ cmake -G "" -DCMAKE_INSTALL_PREFIX= ../src + $ cmake --build . + +where you should replace ```` by the directory under which you would like to +install Cyclone DDS and ```` by one of the ways +CMake [generators](https://cmake.org/cmake/help/latest/manual/cmake-generators.7.html) offer for +generating build files. For example, "Visual Studio 15 2017 Win64" would target a 64-bit build +using Visual Studio 2017. + +To install it after a successful build, do: + + $ cmake --build . --target install + +which will copy everything to: + + * ``/lib`` + * ``/bin`` + * ``/include/ddsc`` + * ``/share/CycloneDDS`` + * ``/etc/CycloneDDS`` + +Depending on the installation location you may need administrator privileges. + +At this point you are ready to use Eclipse Cyclone DDS in your own projects. + +Note that the default build type is a release build with debug information included +(RelWithDebInfo), which is generally the most convenient type of build to use from applications +because of a good mix between performance and still being able to debug things. If you'd rather +have a Debug or pure Release build, set ``CMAKE_BUILD_TYPE`` accordingly. + +### Contributing to Eclipse Cyclone DDS + +We very much welcome all contributions to the project, whether that is questions, examples, bug +fixes, enhancements or improvements to the documentation, or anything else really. When considering +contributing code, it might be good to know that build configurations for Travis CI and AppVeyor are +present in the repository and that there is a test suite using CTest and CUnit that can be built +locally if desired. To build it, set the cmake variable ``BUILD_TESTING`` to on when configuring, e.g.: + + $ cd build + $ cmake -DCMAKE_BUILD_TYPE=Debug -DBUILD_TESTING=ON ../src + $ cmake --build . + $ ctest + +Such a build requires the presence of [CUnit](http://cunit.sourceforge.net/). You can install this +yourself, or you can choose to instead rely on the [Conan](https://conan.io) packaging system that +the CI build infrastructure also uses. In that case, install Conan and do: + + $ conan install .. + +in the build directory prior to running cmake. For Windows, depending on the generator, you might +also need to add switches to select the architecture and build type, e.g., ``conan install -s +arch=x86_64 -s build_type=Debug ..`` This will automatically download and/or build CUnit (and, at +the moment, OpenSSL). + +## Documentation + +The documentation is still rather limited, and at the moment only available in the sources (in the +form of restructured text files in ``src/docs`` and Doxygen comments in the header files), or as +a +[PDF](https://raw.githubusercontent.com/eclipse-cyclonedds/cyclonedds/assets/pdf/CycloneDDS-0.1.0.pdf). The +intent is to automate the process of building the documentation and have them available in more +convenient formats and in the usual locations. ## Performance Median small message throughput measured using the Throughput example between two Intel(R) Xeon(R) CPU E3-1270 V2 @ 3.50GHz (that's 2012 hardware ...) running Linux 3.8.13-rt14.20.el6rt.x86_64, -connected via a quiet GbE and when using gcc-6.2.0 for a RelWithDebInfo build is: +connected via a quiet GbE and when using gcc-6.2.0 for a default (i.e., "RelWithDebInfo") build is: -![Throughput](https://raw.githubusercontent.com/eclipse-cyclonedds/cyclonedds/assets/performance/throughput-polling.png) +Throughput This is with the subscriber in polling mode. Listener mode is marginally slower; using a waitset the message rate for minimal size messages drops to 600k sample/s in synchronous delivery mode and about 750k samples/s in asynchronous delivery mode. The configuration is an out-of-the-box configuration, tweaked only to increase the high-water mark for the reliability window on the writer side. For -details, see the scripts in the ``performance`` directory and the [data](https://raw.githubusercontent.com/eclipse-cyclonedds/cyclonedds/assets/performance/throughput.txt). +details, see the scripts in the ``performance`` directory and +the +[data](https://raw.githubusercontent.com/eclipse-cyclonedds/cyclonedds/assets/performance/throughput.txt). There is some data on roundtrip latency below. +## Building and Running the Roundtrip Example -## Examples -Now that you have built and installed **cyclonecdds** it is time to experiment with some examples. - -### Building and Running the Roundtrip Example -The first example we will show you how to build and run, measures cyclonedds latency and will allow you to see with your eyes how fast it is! - -Do as follows: +We will show you how to build and run an example program that measures latency. The examples are +built automatically when you build Cyclone DDS, so you don't need to follow these steps to be able +to run the program, it is merely to illustrate the process. $ cd cyclonedds/src/examples/roundtrip $ mkdir build @@ -54,12 +139,11 @@ Do as follows: $ cmake .. $ make -Now that you've build the roundtrip example it is time to run it. +On one terminal start the application that will be responding to pings: -On one terminal start the applications that will be responding to **cyclonedds** pings. $ ./RoundtripPong -On another terminal, start the application that will be sending the ping. +On another terminal, start the application that will be sending the pings: $ ./RoundtripPing 0 0 0 # payloadSize: 0 | numSamples: 0 | timeOut: 0 @@ -79,8 +163,12 @@ On another terminal, start the application that will be sending the ping. 9 28242 17 16 24 132 28242 8 6 28242 1 0 10 28075 17 16 23 46 28075 8 6 28075 1 0 - -The number above were measure on Mac running a 4,2 GHz Intel Core i7 on December 12th 2018. From these number you can see how the roundtrip is incredibly stable and the minimal latency is now down to 17 micro-seconds (used to be 25 micro-seconds) on this HW. +The numbers above were measured on Mac running a 4.2 GHz Intel Core i7 on December 12th 2018. From +these numbers you can see how the roundtrip is very stable and the minimal latency is now down to 17 +micro-seconds (used to be 25 micro-seconds) on this HW. -## Documentation -The Cyclone DDS documentation is available [here](http://cdds.io/docs). +# Trademarks + +* "Eclipse Cyclone DDS" and "Cyclone DDS" are trademarks of the Eclipse Foundation. + +* "DDS" is a trademark of the Object Management Group, Inc. diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 08a48ad..ab49099 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -9,7 +9,7 @@ # # SPDX-License-Identifier: EPL-2.0 OR BSD-3-Clause # -cmake_minimum_required(VERSION 3.6) +cmake_minimum_required(VERSION 3.7) # Set a default build type if none was specified set(default_build_type "RelWithDebInfo") @@ -38,8 +38,8 @@ execute_process(COMMAND git submodule update # Set module path before defining project so platform files will work. set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_LIST_DIR}/cmake/modules") -set(CMAKE_PROJECT_NAME_FULL "Cyclone DDS") -string(REPLACE " " "" PROJECT_NAME "${CMAKE_PROJECT_NAME_FULL}") +set(CMAKE_PROJECT_NAME_FULL "Eclipse Cyclone DDS") +set(PROJECT_NAME "CycloneDDS") project(${PROJECT_NAME} VERSION 0.1.0) # Set some convenience variants of the project-name diff --git a/src/core/ddsc/include/ddsc/dds.h b/src/core/ddsc/include/ddsc/dds.h index 41c04e9..0612ada 100644 --- a/src/core/ddsc/include/ddsc/dds.h +++ b/src/core/ddsc/include/ddsc/dds.h @@ -14,7 +14,7 @@ /** @file * - * @brief C DDS header + * @brief Eclipse Cyclone DDS C header */ #if defined (__cplusplus) diff --git a/src/core/ddsc/include/ddsc/dds_public_alloc.h b/src/core/ddsc/include/ddsc/dds_public_alloc.h index 5ad74e9..647272a 100644 --- a/src/core/ddsc/include/ddsc/dds_public_alloc.h +++ b/src/core/ddsc/include/ddsc/dds_public_alloc.h @@ -16,7 +16,7 @@ * @brief DDS C Allocation API * * This header file defines the public API of allocation convenience functions - * in the CycloneDDS C language binding. + * in the Eclipse Cyclone DDS C language binding. */ #ifndef DDS_ALLOC_H #define DDS_ALLOC_H diff --git a/src/core/ddsc/include/ddsc/dds_public_impl.h b/src/core/ddsc/include/ddsc/dds_public_impl.h index d1c041e..a34959b 100644 --- a/src/core/ddsc/include/ddsc/dds_public_impl.h +++ b/src/core/ddsc/include/ddsc/dds_public_impl.h @@ -16,7 +16,7 @@ * @brief DDS C Implementation API * * This header file defines the public API for all kinds of things in the - * CycloneDDS C language binding. + * Eclipse Cyclone DDS C language binding. */ #ifndef DDS_IMPL_H #define DDS_IMPL_H diff --git a/src/core/ddsc/include/ddsc/dds_public_listener.h b/src/core/ddsc/include/ddsc/dds_public_listener.h index bec465b..e749629 100644 --- a/src/core/ddsc/include/ddsc/dds_public_listener.h +++ b/src/core/ddsc/include/ddsc/dds_public_listener.h @@ -15,7 +15,7 @@ * @brief DDS C Listener API * * This header file defines the public API of listeners in the - * CycloneDDS C language binding. + * Eclipse Cyclone DDS C language binding. */ #ifndef _DDS_PUBLIC_LISTENER_H_ #define _DDS_PUBLIC_LISTENER_H_ diff --git a/src/core/ddsc/include/ddsc/dds_public_qos.h b/src/core/ddsc/include/ddsc/dds_public_qos.h index b7f2243..8f58517 100644 --- a/src/core/ddsc/include/ddsc/dds_public_qos.h +++ b/src/core/ddsc/include/ddsc/dds_public_qos.h @@ -15,7 +15,7 @@ * @brief DDS C QoS API * * This header file defines the public API of QoS and Policies in the - * CycloneDDS C language binding. + * Eclipse Cyclone DDS C language binding. */ #ifndef DDS_QOS_H #define DDS_QOS_H diff --git a/src/core/ddsc/include/ddsc/dds_public_status.h b/src/core/ddsc/include/ddsc/dds_public_status.h index 7ef5d32..aa79bcd 100644 --- a/src/core/ddsc/include/ddsc/dds_public_status.h +++ b/src/core/ddsc/include/ddsc/dds_public_status.h @@ -15,7 +15,7 @@ * @brief DDS C Communication Status API * * This header file defines the public API of the Communication Status in the - * CycloneDDS C language binding. + * Eclipse Cyclone DDS C language binding. */ #ifndef DDS_STATUS_H #define DDS_STATUS_H diff --git a/src/core/ddsc/include/ddsc/dds_public_stream.h b/src/core/ddsc/include/ddsc/dds_public_stream.h index fed0f7a..94ad667 100644 --- a/src/core/ddsc/include/ddsc/dds_public_stream.h +++ b/src/core/ddsc/include/ddsc/dds_public_stream.h @@ -15,7 +15,7 @@ * @brief DDS C Stream API * * This header file defines the public API of the Streams in the - * CycloneDDS C language binding. + * Eclipse Cyclone DDS C language binding. */ #ifndef DDS_STREAM_H #define DDS_STREAM_H diff --git a/src/core/ddsc/include/ddsc/dds_public_time.h b/src/core/ddsc/include/ddsc/dds_public_time.h index 9828b79..4ecaabc 100644 --- a/src/core/ddsc/include/ddsc/dds_public_time.h +++ b/src/core/ddsc/include/ddsc/dds_public_time.h @@ -15,7 +15,7 @@ * @brief DDS C Time support API * * This header file defines the public API of the in the - * CycloneDDS C language binding. + * Eclipse Cyclone DDS C language binding. */ #ifndef DDS_TIME_H #define DDS_TIME_H diff --git a/src/core/ddsi/include/ddsi/q_globals.h b/src/core/ddsi/include/ddsi/q_globals.h index 70e0317..e4c0d15 100644 --- a/src/core/ddsi/include/ddsi/q_globals.h +++ b/src/core/ddsi/include/ddsi/q_globals.h @@ -51,10 +51,10 @@ struct ut_thread_pool_s; struct debug_monitor; struct ddsi_tkmap; -typedef struct ospl_in_addr_node { +typedef struct config_in_addr_node { nn_locator_t loc; - struct ospl_in_addr_node *next; -} ospl_in_addr_node; + struct config_in_addr_node *next; +} config_in_addr_node; enum recvips_mode { RECVIPS_MODE_ALL, /* all MC capable interfaces */ @@ -174,7 +174,7 @@ struct q_globals { advertised in discovery messages (so that an external IP address on a NAT may be advertised), and the DDSI multi-cast address. */ enum recvips_mode recvips_mode; - struct ospl_in_addr_node *recvips; + struct config_in_addr_node *recvips; nn_locator_t extmask; nn_locator_t ownloc; diff --git a/src/core/ddsi/src/ddsi_mcgroup.c b/src/core/ddsi/src/ddsi_mcgroup.c index da20312..a148a0a 100644 --- a/src/core/ddsi/src/ddsi_mcgroup.c +++ b/src/core/ddsi/src/ddsi_mcgroup.c @@ -165,7 +165,7 @@ static int joinleave_mcgroup (ddsi_tran_conn_t conn, int join, const nn_locator_ static int interface_in_recvips_p (const struct nn_interface *interf) { - struct ospl_in_addr_node *nodeaddr; + struct config_in_addr_node *nodeaddr; for (nodeaddr = gv.recvips; nodeaddr; nodeaddr = nodeaddr->next) { if (locator_compare_no_port(&nodeaddr->loc, &interf->loc) == 0) diff --git a/src/core/ddsi/src/q_config.c b/src/core/ddsi/src/q_config.c index bbb898e..783d390 100644 --- a/src/core/ddsi/src/q_config.c +++ b/src/core/ddsi/src/q_config.c @@ -502,7 +502,7 @@ static const struct cfgelem heartbeat_interval_attrs[] = { }; static const struct cfgelem liveliness_monitoring_attrs[] = { - { LEAF("StackTraces"), 1, "true", ABSOFF(noprogress_log_stacktraces), 0, uf_boolean, 0, pf_boolean, + { ATTR("StackTraces"), 1, "true", ABSOFF(noprogress_log_stacktraces), 0, uf_boolean, 0, pf_boolean, "

This element controls whether or not to write stack traces to the DDSI2 trace when a thread fails to make progress (on select platforms only).

" }, END_MARKER }; diff --git a/src/core/ddsi/src/q_init.c b/src/core/ddsi/src/q_init.c index 892369d..b40ce17 100644 --- a/src/core/ddsi/src/q_init.c +++ b/src/core/ddsi/src/q_init.c @@ -204,7 +204,7 @@ static int set_recvips (void) #endif else { - struct ospl_in_addr_node **recvnode = &gv.recvips; + struct config_in_addr_node **recvnode = &gv.recvips; int i, j; gv.recvips_mode = RECVIPS_MODE_SOME; for (i = 0; config.networkRecvAddressStrings[i] != NULL; i++) @@ -225,7 +225,7 @@ static int set_recvips (void) DDS_ERROR("No interface bound to requested address '%s'\n", config.networkRecvAddressStrings[i]); return -1; } - *recvnode = os_malloc (sizeof (struct ospl_in_addr_node)); + *recvnode = os_malloc (sizeof (struct config_in_addr_node)); (*recvnode)->loc = loc; recvnode = &(*recvnode)->next; *recvnode = NULL; @@ -584,8 +584,7 @@ int rtps_config_prep (struct cfgst *cfgst) if it had been created using create_thread(). */ { - /* For Lite - Temporary - Thread states for each application thread is managed using thread_states structure + /* Temporary: thread states for each application thread is managed using thread_states structure */ #define USER_MAX_THREADS 50 @@ -864,8 +863,6 @@ int rtps_init (void) uint32_t port_data_uc = 0; bool mc_available = true; - /* Initialize implementation (Lite or OSPL) */ - ddsi_plugin_init (); ddsi_iid_init (); @@ -1386,7 +1383,7 @@ err_network_partition_addrset: err_set_ext_address: while (gv.recvips) { - struct ospl_in_addr_node *n = gv.recvips; + struct config_in_addr_node *n = gv.recvips; gv.recvips = n->next; os_free (n); } @@ -1670,7 +1667,7 @@ void rtps_fini (void) while (gv.recvips) { - struct ospl_in_addr_node *n = gv.recvips; + struct config_in_addr_node *n = gv.recvips; /* The compiler doesn't realize that n->next is always initialized. */ OS_WARNING_MSVC_OFF(6001); gv.recvips = n->next; diff --git a/src/core/xtests/rhc_torture.c b/src/core/xtests/rhc_torture.c index 7592784..8bc2808 100644 --- a/src/core/xtests/rhc_torture.c +++ b/src/core/xtests/rhc_torture.c @@ -587,7 +587,7 @@ static void test_conditions (dds_entity_t pp, dds_entity_t tp, const int count, if (conds[ci] <= 0) abort (); rhcconds[ci] = get_condaddr (conds[ci]); if (print) { - char buf[10]; + char buf[18]; snprintf (buf, sizeof (buf), "conds[%d]", ci); print_cond_w_addr (buf, conds[ci]); } diff --git a/src/docs/CMakeLists.txt b/src/docs/CMakeLists.txt index 79e14b0..0ce07fd 100644 --- a/src/docs/CMakeLists.txt +++ b/src/docs/CMakeLists.txt @@ -131,11 +131,9 @@ elseif(BUILD_DOCS) endif() # Process sphinx configuration file - set(sph_conf_author "ADLINK") - string(TIMESTAMP sph_conf_copyright "%Y, ADLINK") + set(sph_conf_author "Eclipse Cyclone DDS project") set(sph_conf_version "${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}.${PROJECT_VERSION_PATCH}") set(sph_conf_release "${PROJECT_VERSION}") - set(sph_logo "${PROJECT_SOURCE_DIR}/docs/_static/pictures/VORTEX_LOGO.png") configure_file(conf.py.in conf.py @ONLY) # Define a list of output formats (-b option for sphinx-build) diff --git a/src/docs/Doxyfile.in b/src/docs/Doxyfile.in index ea6b34a..32aebfe 100644 --- a/src/docs/Doxyfile.in +++ b/src/docs/Doxyfile.in @@ -2037,7 +2037,7 @@ INCLUDE_FILE_PATTERNS = # recursively expanded use the := operator instead of the = operator. # This tag requires that the tag ENABLE_PREPROCESSING is set to YES. -PREDEFINED = __restrict= __attribute__(x)= +PREDEFINED = __restrict= __attribute__(x)= __declspec(x)= # If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then this # tag can be used to specify a list of macro names that should be expanded. The @@ -2046,7 +2046,7 @@ PREDEFINED = __restrict= __attribute__(x)= # definition found in the source code. # This tag requires that the tag ENABLE_PREPROCESSING is set to YES. -EXPAND_AS_DEFINED = +EXPAND_AS_DEFINED = # If the SKIP_FUNCTION_MACROS tag is set to YES then doxygen's preprocessor will # remove all references to function-like macros that are alone on a line, have diff --git a/src/docs/GettingStartedGuide/helloworld.rst b/src/docs/GettingStartedGuide/helloworld.rst index 71e51ea..3b0169f 100644 --- a/src/docs/GettingStartedGuide/helloworld.rst +++ b/src/docs/GettingStartedGuide/helloworld.rst @@ -15,9 +15,9 @@ \newpage -############################### -Building CycloneDDS applications -############################### +######################################### +Building Eclipse Cyclone DDS applications +######################################### .. .. contents:: @@ -36,15 +36,12 @@ to be done to code the *Hello World!* example. The procedure used to build the *Hello World!* example can also be used for building your own applications. -:Windows: It is advised to have the CycloneDDS examples component installed (see - :ref:`Windows installation `) when actively - building the CycloneDDS examples on Windows. This chapter refers to the - CycloneDDS examples installed in the User Profile directory on Windows. +:Windows: ... -:Linux: It is advised to have copied the CycloneDDS examples to a user-friendly +:Linux: It is advised to have copied the Eclipse Cyclone DDS examples to a user-friendly location as described in :ref:`this ` - paragraph when actively building the CycloneDDS examples on Linux. - This chapter refers to the CycloneDDS examples installed + paragraph when actively building the Eclipse Cyclone DDS examples on Linux. + This chapter refers to the Eclipse Cyclone DDS examples installed in the user-defined location. @@ -116,8 +113,8 @@ Creating the *Hello World!* example executables is as simple as selecting the required configuration and building the solution. :code:`helloworld\vs\directories.props` contains the location of where -the CycloneDDS header files and libraries are be placed. These locations -are based on the default installation directory structure. When CycloneDDS +the Eclipse Cyclone DDS header files and libraries are be placed. These locations +are based on the default installation directory structure. When Eclipse Cyclone DDS is installed in a different directory, the following paths in :code:`helloworld\vs\directories.props` should be changed, like: @@ -191,7 +188,7 @@ scope of this document. .. _`CycloneDdsPackage`: Hello World! CMake (CycloneDDS Package) -====================================== +======================================= After the CMake digression, we're back with the *Hello World!* example. Apart from the native build files, CMake build files @@ -304,13 +301,13 @@ using the binaries that were just build. Be sure to use the right directories. Summary ******* -We've seen that a CycloneDDS application can be build by using a Makefile on Linux -or a Visual Studio Solutions on Windows. Also CMake can be used to build a CycloneDDS +We've seen that a Eclipse Cyclone DDS application can be build by using a Makefile on Linux +or a Visual Studio Solutions on Windows. Also CMake can be used to build a Eclipse Cyclone DDS application. In fact, it is the preferred way of building. In the end, a predefined way of generating and building the source code should -be followed when building CycloneDDS applications. The figure below shows how a -typical CycloneDDS application is build. +be followed when building Eclipse Cyclone DDS applications. The figure below shows how a +typical Eclipse Cyclone DDS application is build. .. image:: ../_static/pictures/BuildSchema.png :scale: 30 % diff --git a/src/docs/GettingStartedGuide/installation.rst b/src/docs/GettingStartedGuide/installation.rst index 2e09ba6..b55eaee 100644 --- a/src/docs/GettingStartedGuide/installation.rst +++ b/src/docs/GettingStartedGuide/installation.rst @@ -15,9 +15,9 @@ \newpage -################# -Install CycloneDDS -################# +############################## +Installing Eclipse Cyclone DDS +############################## .. .. contents:: @@ -28,31 +28,12 @@ Install CycloneDDS System requirements ******************* -Currently AdLink CycloneDDS is supported on the following platforms: - -+-------------------+--------------+--------------------+ -| Operating systems | Architecture | Compiler | -+===================+==============+====================+ -| Ubuntu 16.04 LTS | 64-bit | gcc 5.4 or later | -+-------------------+--------------+--------------------+ -| Windows 10 | 64 -bit | VS2015 | -+-------------------+--------------+--------------------+ +At the time of writing, Eclipse Cyclone DDS is known to run on Linux, macOS and Windows. The build-process is not yet able to generate native packages. - -***** -Linux -***** - -Ubuntu -====== - -On Ubuntu and other debian-derived platforms, the product can be installed using a native package. - -:: - - sudo dpkg -i cyclonedds__.deb - sudo dpkg -i cyclonedds-dev__.deb +*************** +Linux and macOS +*************** .. _`CopyLinuxExamplesToUserFriendlyLocation`: @@ -60,11 +41,10 @@ On Ubuntu and other debian-derived platforms, the product can be installed using Post install steps ~~~~~~~~~~~~~~~~~~ -The installation package installs examples in system directories. -In order to have a better user experience when building the CycloneDDS -examples, it is advised to copy the examples to a user-defined location. -This is to be able to build the examples natively and experiment with -the example source code. +The installation package installs examples in system directories. In order to have a better user +experience when building the Eclipse Cyclone DDS examples, it is advised to copy the examples to a +user-defined location. This is to be able to build the examples natively and experiment with the +example source code. For this, the installation package provides the vdds_install_examples script, located in /usr/bin. @@ -76,42 +56,15 @@ and the examples will be installed in the current location. Type :code:`vdds_install_examples -h` for more information. -Red Hat -======= - -Not supported yet (CHAM-326). - - -Tarball -======= - -For more generic Linux installations, different tar-balls (with the same -content) are provided. - -+----------------------------------+---------------------------------------+ -| Tarball | Description | -+==================================+=======================================+ -| CycloneDDS--Linux.tar.Z | Tar Compress compression. | -+----------------------------------+---------------------------------------+ -| CycloneDDS--Linux.tar.gz | Tar GZip compression. | -+----------------------------------+---------------------------------------+ -| CycloneDDS--Linux.tar.sh | Self extracting Tar GZip compression. | -+----------------------------------+---------------------------------------+ - -By extracting one of them at any preferred location, CycloneDDS can be used. - .. _`LinuxSetLibPath`: Paths ===== -To be able to run CycloneDDS executables, the required libraries (like -libddsc.so) need to be available to the executables. -Normally, these are installed in system default locations and it works -out-of-the-box. However, if they are not installed in those locations, -it is possible that the library search path has to be changed. -This can be achieved by executing the command: -:: +To be able to run Eclipse Cyclone DDS executables, the required libraries (like libddsc.so) need to +be available to the executables. Normally, these are installed in system default locations and it +works out-of-the-box. However, if they are not installed in those locations, it is possible that the +library search path has to be changed. This can be achieved by executing the command: :: export LD_LIBRARY_PATH=/lib:$LD_LIBRARY_PATH @@ -120,49 +73,19 @@ This can be achieved by executing the command: Windows ******* -.. _`WindowsInstallMSI`: - -MSI -=== - -The default deployment method on Windows is to install the product using the MSI installer. - -The installation process is self-explanatory. Three components are available: - -1. a runtime component, containing the runtime libraries -2. a development component, containing the header files, the IDL compiler, - a precompiled Hello Word! example and other examples. -3. an examples component, containing the source code of the CycloneDDS examples. - -The runtime and development components are (by default) installed in "Program Files" while -the CycloneDDS example component will be installed in the User Profile directory. -The CycloneDDS example code in the User Profile directory can be changed by the user. - - -ZIP -=== - -The Windows installation is also provided as a ZIP file. By extracting it -at any preferred location, CycloneDDS can be used. .. _`WindowsSetLibPath`: Paths ~~~~~ -To be able to run CycloneDDS executables, the required libraries (like -ddsc.dll) need to be available to the executables. -Normally, these are installed in system default locations and it works -out-of-the-box. However, if they are not installed on those locations, -it is possible that the library search path has to be changed. -This can be achieved by executing the command: -:: +To be able to run Eclipse Cyclone DDS executables, the required libraries (like ddsc.dll) need to be +available to the executables. Normally, these are installed in system default locations and it +works out-of-the-box. However, if they are not installed on those locations, it is possible that the +library search path has to be changed. This can be achieved by executing the command: :: set PATH=/bin;%PATH% -.. note:: - The MSI installer will add this path to the PATH environment - variable automatically. .. _`TestYourInstallation`: @@ -170,11 +93,9 @@ This can be achieved by executing the command: Test your installation ********************** -The installation provides a simple prebuilt :ref:`Hello World! ` application which -can be run in order to test your installation. The *Hello World!* application consists of two -executables: a so called HelloworldPublisher and a HelloworldSubscriber, typically located in -:code:`/usr/share/CycloneDDS/examples/helloworld/bin` on Linux and in -:code:`C:\Program Files\ADLINK\Cyclone DDS\share\CycloneDDS\examples\helloworld\bin` on Windows. +Eclipse Cyclone DDS includes a simple :ref:`Hello World! ` application which can be run +in order to test your installation. The *Hello World!* application consists of two executables: a so +called HelloworldPublisher and a HelloworldSubscriber. To run the example application, please open two console windows and navigate to the appropriate directory in both console windows. Run the HelloworldSubscriber in one of the console windows by the @@ -199,10 +120,3 @@ while the HelloworldSubscriber will be looking like this For more information on how to build this application your own and the code which has been used, please have a look at the :ref:`Hello World! ` chapter. - -******* -License -******* - -TODO: CHAM-325 - diff --git a/src/docs/GettingStartedGuide/next_steps.rst b/src/docs/GettingStartedGuide/next_steps.rst index 7c98511..5a70102 100644 --- a/src/docs/GettingStartedGuide/next_steps.rst +++ b/src/docs/GettingStartedGuide/next_steps.rst @@ -19,58 +19,25 @@ What's next? ############ -Want to know more about CycloneDDS? Please consider following a tutorial or -visit some of the pages listed below. +Want to know more about DDS? The primary source of information is the +OMG website at http://www.omg.org and specifically the `DDS Getting +Started `_ page and the +`DDS specification `_ itself. The +specification is a bit wordy and of course deals with minute details, +but it is surprisingly easy to follow for a specification. -************************* -The OMG DDS Specification -************************* +There are also various resources on the web dealing with DDS in general, +as the various vendors have posted tutorials, presentations, general +information and documentation on their products. While the details +between the various implementations do differ, they have much more in +common than what separates them, and so this information is also +applicable to Eclipse Cyclone DDS. The one thing in which +Eclipse Cyclone DDS really differs is in the details of API, but that's +just syntax. -PrismTech (aquired by AdLink) has been an active member of the Object Management -Group® (OMG®) for over several years and is heavily involved in the development of the -DDS specification. Please visit the OMG website at http://www.omg.org and -specifically the -`DDS Getting Started `_ -page and the `DDS specification `_ itself. +Obviously there are also things specific to Eclipse Cyclone DDS. The +level of documentation of Eclipse is not nearly what it should be, but +that will improve over time. -************************************* -AdLink Documentation and Tutorials -************************************* - -* `Documentation `_ -* `DDS Tutorial `_ - -******************************** -AdLink on Youtube and Slideshare -******************************** - -AdLink is also active on Youtube and Slideshare. Please following -the links below to view some interesting videos and presentations. - -* `Overview `_ -* `Vortex Youtube `_ -* `Vortex Slideshare `_ -* `Vortex Demo `_ - -********************** -AdLink on Social Media -********************** - -* `Twitter (@ADLINKTech_usa) `_ -* `Facebook `_ -* `LinkedIn `_ - - -***************** -The DDS community -***************** - -* `The AdLink DDS-community `_ -* `The AdLink DDS Forum `_ - -******* -Support -******* - -* `Knowledge base `_ -* `Support (registered users) `_ +And last but note least: please always feel welcome to ask questions on +GitHub! diff --git a/src/docs/GettingStartedGuide/uninstall.rst b/src/docs/GettingStartedGuide/uninstall.rst index b1fac60..8656953 100644 --- a/src/docs/GettingStartedGuide/uninstall.rst +++ b/src/docs/GettingStartedGuide/uninstall.rst @@ -15,53 +15,8 @@ \newpage -###################### -Uninstalling CycloneDDS -###################### +################################ +Uninstalling Eclipse Cyclone DDS +################################ -***** -Linux -***** - -Uninstalling CycloneDDS on Linux can be established by invoking -the following two commands (of which the first is optional): -:: - - sudo dpkg --remove cyclonedds-dev - sudo dpkg --remove cyclonedds - -.. note:: - Mind the order in which these commands are run. The development - package (:code:`cyclonedds-dev`) need to be removed first since - it depends on the library version (:code:`cyclonedds`). - -******* -Windows -******* - -There are two ways to uninstall CycloneDDS from Windows - -1. By using the original CycloneDDS :ref:`MSI ` file -2. By using Windows "Apps & features" - -Original MSI -============ - -Locate the original CycloneDDS MSI file on your system and start it. -After clicking :code:`Next`, an overview of options appears, amongst which -is the remove option. By clicking :code:`Remove`, all files and folders are -removed, except the CycloneDDS examples (if installed). - -Apps & features -=============== - -Go to :code:`Windows Settings` by clicking the :code:`Settings`-icon ( |settings_icon| ) -in the Windows Start Menu. Choose :code:`Apps` in the -:code:`Windows Settings` screen. A list of all installed apps -and programs pops up. Select :code:`CycloneDDS` and choose :code:`Uninstall`. -All installed files and folders will be removed, except the -CycloneDDS examples (if installed). - -.. |settings_icon| image:: ../_static/pictures/settings-icon.png - :height: 9 - :width: 9 +TBD. diff --git a/src/docs/conf.py.in b/src/docs/conf.py.in index 5c80038..5e0694f 100644 --- a/src/docs/conf.py.in +++ b/src/docs/conf.py.in @@ -49,7 +49,7 @@ source_suffix = '.rst' master_doc = 'index' # General information about the project. -project = u'@CMAKE_PROJECT_NAME@' +project = u'@CMAKE_PROJECT_NAME_FULL@' copyright = u'@sph_conf_copyright@' author = u'@sph_conf_author@' @@ -119,7 +119,7 @@ html_sidebars = { # -- Options for HTMLHelp output ------------------------------------------ # Output file base name for HTML help builder. -htmlhelp_basename = '@CMAKE_PROJECT_NAME@doc' +htmlhelp_basename = '@CMAKE_PROJECT_NAME_FULL@doc' # -- Options for LaTeX output --------------------------------------------- @@ -147,7 +147,7 @@ latex_elements = { # (source start file, target name, title, # author, documentclass [howto, manual, or own class]). latex_documents = [ - (master_doc, '@CMAKE_PROJECT_NAME@.tex', u'@CMAKE_PROJECT_NAME@', + (master_doc, '@CMAKE_PROJECT_NAME@.tex', u'@CMAKE_PROJECT_NAME_FULL@', u'@sph_conf_author@', 'manual'), ] @@ -158,7 +158,7 @@ latex_logo = u'@sph_logo@' # One entry per manual page. List of tuples # (source start file, name, description, authors, manual section). #man_pages = [ -# (master_doc, 'cyclonedds', u'CycloneDDS Documentation', +# (master_doc, 'cyclonedds', u'Eclipse Cyclone DDS Documentation', # [author], 1) #] @@ -169,7 +169,7 @@ latex_logo = u'@sph_logo@' # (source start file, target name, title, author, # dir menu entry, description, category) texinfo_documents = [ - (master_doc, '@CMAKE_PROJECT_NAME@', u'@CMAKE_PROJECT_NAME@ Documentation', + (master_doc, '@CMAKE_PROJECT_NAME_FULL@', u'@CMAKE_PROJECT_NAME_FULL@ Documentation', author, '@CMAKE_PROJECT_NAME@', 'One line description of project.', 'Miscellaneous'), ] diff --git a/src/docs/config.rst b/src/docs/config.rst index 8425ab5..7223357 100644 --- a/src/docs/config.rst +++ b/src/docs/config.rst @@ -1,14 +1,14 @@ -################################################### -A guide to the configuration options of Cyclone DDS -################################################### +########################################################### +A guide to the configuration options of Eclipse Cyclone DDS +########################################################### This document attempts to provide background information that will help in adjusting the -configuration of Cyclone DDS when the default settings do not give the desired behavior. +configuration of Eclipse Cyclone DDS when the default settings do not give the desired behavior. A full listing of all settings is out of scope for this document, but can be extracted from the sources. -.. _`DDSI Concepts` +.. _`DDSI Concepts`: DDSI Concepts ************* @@ -18,10 +18,10 @@ correspondence between the entities in DDSI and those in DCPS. However, this correspondence is not one-to-one. In this section we give a high-level description of the concepts of the DDSI -specification, with hardly any reference to the specifics of the Cyclone DDS +specification, with hardly any reference to the specifics of the Eclipse Cyclone DDS implementation, which are addressed in subsequent sections. This division was chosen to aid readers interested in interoperability to understand where the specification ends -and the Cyclone DDS implementation begins. +and the Eclipse Cyclone DDS implementation begins. .. _`Mapping of DCPS domains to DDSI domains`: @@ -89,7 +89,7 @@ are stored in the writer history cache (or *WHC*) of the DDSI writer. The DDSI is required to periodically send *Heartbeats* to its readers to ensure that all readers will learn of the presence of new samples in the WHC even when packets get lost. It is allowed to suppress these periodic Heartbeats if there is all samples in the WHC have -been acknowledged by all matched readers and the Cyclone DDS exploits this freedom. +been acknowledged by all matched readers and the Eclipse Cyclone DDS exploits this freedom. If a reader receives a Heartbeat and detects it did not receive all samples, it requests a retransmission by sending an *AckNack* message to the writer. The timing of this is @@ -106,7 +106,7 @@ from its WHC when it fills up too far, and allows readers to always receive all complication exists in the case of unresponsive readers, readers that do not respond to a Heartbeat at all, or that for some reason fail to receive some samples despite resending it. The specification leaves the way these get treated unspecified. The -default beahviour of Cyclone DDS is to never consider readers unresponsive, but it can +default beahviour of Eclipse Cyclone DDS is to never consider readers unresponsive, but it can be configured to consider them so after a certain length of time has passed at which point the participant containing the reader is undiscovered. @@ -135,7 +135,7 @@ sample for each existing instance. Naturally, once the DCPS writer is deleted (or disappears for whatever reason), the DDSI writer disappears as well, and with it, its history. For this reason, transient data is -generally much to be preferred over transient-local data. Cyclone DDS has a facility +generally much to be preferred over transient-local data. Eclipse Cyclone DDS has a facility for retrieving transient data from an suitably configured OpenSplice node, but does not yet include a native service for managing transient data. @@ -162,14 +162,14 @@ The protocol does allow for unicast-based discovery, which requires listing the addresses of machines where participants may be located and ensuring each participant uses one of a small set of port numbers. Because of this, some of the port numbers are derived not only from the domain id, but also from a *participant index*, which is a -small non-negative integer, unique to a participant within a node. (Cyclone DDS adds an +small non-negative integer, unique to a participant within a node. (Eclipse Cyclone DDS adds an indirection and uses at most one participant index for a domain for each process, regardless of how many DCPS participants are created by the process.) Once two participants have discovered each other and both have matched the DDSI built-in endpoints their peer is advertising in the SPDP message, the *Simple Endpoint Discovery Protocol* or *SEDP* takes over, exchanging information on the DCPS data readers and data -writers (and for Cyclone DDS, also publishers, subscribers and topics in a manner +writers (and for Eclipse Cyclone DDS, also publishers, subscribers and topics in a manner compatible with OpenSplice) in the two participants. The SEDP data is handled as reliable, transient-local data. Therefore, the SEDP writers @@ -183,10 +183,10 @@ participant is added to the system: *all* existing participants respond to the S message, following which all start exchanging SEDP data. -.. _`Cyclone DDS specifics`: +.. _`Eclipse Cyclone DDS specifics`: -Cyclone DDS specifics -********************* +Eclipse Cyclone DDS specifics +***************************** .. _`Discovery behaviour`: @@ -198,7 +198,7 @@ Discovery behaviour Proxy participants and endpoints -------------------------------- -Cyclone DDS is what the DDSI specification calls a *stateful* implementation. Writers +Eclipse Cyclone DDS is what the DDSI specification calls a *stateful* implementation. Writers only send data to discovered readers and readers only accept data from discovered writers. (There is one exception: the writer may choose to multicast the data, and anyone listening will be able to receive it, if a reader has already discovered the @@ -206,7 +206,7 @@ writer but not vice-versa; it may accept the data even though the connection is fully established yet. At present, not only can such asymmetrical discovery cause data to be delivered when it was perhaps not expected, it can also cause indefinite blocking if the situation persists for a long time.) Consequently, for each remote participant -and reader or writer, Cyclone DDS internally creates a proxy participant, proxy reader +and reader or writer, Eclipse Cyclone DDS internally creates a proxy participant, proxy reader or proxy writer. In the discovery process, writers are matched with proxy readers, and readers are matched with proxy writers, based on the topic and type names and the QoS settings. @@ -215,7 +215,7 @@ Proxies have the same natural hierarchy that ‘normal’ DDSI entities have: ea endpoint is owned by some proxy participant, and once the proxy participant is deleted, all of its proxy endpoints are deleted as well. Participants assert their liveliness periodically (called *automic* liveliness in the DCPS specification and the only mode -currently supported by Cyclone DDS), and when nothing has been heard from a participant +currently supported by Eclipse Cyclone DDS), and when nothing has been heard from a participant for the lease duration published by that participant in its SPDP message, the lease becomes expired triggering a clean-up. @@ -230,11 +230,11 @@ to expire. Sharing of discovery information -------------------------------- -As Cyclone DDS handles any number of participants in an integrated manner, the discovery +As Eclipse Cyclone DDS handles any number of participants in an integrated manner, the discovery protocol as sketched earlier is rather wasteful: there is no need for each individual -participant in a Cyclone DDS process to run the full discovery protocol for itself. +participant in a Eclipse Cyclone DDS process to run the full discovery protocol for itself. -Instead of implementing the protocol as suggested by the standard, Cyclone DDS shares +Instead of implementing the protocol as suggested by the standard, Eclipse Cyclone DDS shares all discovery activities amongst the participants, allowing one to add participants on a process with only a minimal impact on the system. It is even possible to have only a single DDSI participant in a process regardless of the number of DCPS participants @@ -246,7 +246,7 @@ affected. Because other implementations of the DDSI specification may be written on the assumption that all participants perform their own discovery, it is possible to simulate that with -Cyclone DDS. It will not actually perform the discovery for each participant +Eclipse Cyclone DDS. It will not actually perform the discovery for each participant independently, but it will generate the network traffic *as if* it does. These are controlled by the ``Internal/BuiltinEndpointSet`` and ``Internal/ConservativeBuiltinReaderStartup`` options. However, please note that at the @@ -267,12 +267,12 @@ Lingering writers When an application deletes a reliable DCPS data writer, there is no guarantee that all its readers have already acknowledged the correct receipt of all samples. In such a -case, Cyclone DDS lets the writer (and the owning participant if necessary) linger in +case, Eclipse Cyclone DDS lets the writer (and the owning participant if necessary) linger in the system for some time, controlled by the ``Internal/WriterLingerDuration`` option. The writer is deleted when all samples have been acknowledged by all readers or the linger duration has elapsed, whichever comes first. -Note that the writer linger duration setting is currently not applied when Cyclone DDS +Note that the writer linger duration setting is currently not applied when Eclipse Cyclone DDS is requested to terminate. @@ -281,7 +281,7 @@ is requested to terminate. Start-up mode ------------- -A similar issue exists when starting Cyclone DDS: DDSI discovery takes time, and when +A similar issue exists when starting Eclipse Cyclone DDS: DDSI discovery takes time, and when data is written immediately after the first participant was created, it is likely that the discovery process hasn’t completed yet and some remote readers have not yet been discovered. This would cause the writers to throw away samples for lack of interest, @@ -372,7 +372,7 @@ Network and discovery configuration Networking interfaces ===================== -Cyclone DDS uses a single network interface, the *preferred* interface, for transmitting +Eclipse Cyclone DDS uses a single network interface, the *preferred* interface, for transmitting its multicast packets and advertises only the address corresponding to this interface in the DDSI discovery protocol. @@ -398,7 +398,7 @@ is always preferred and is the only option that allows selecting the desired one multiple addresses are tied to a single interface. The default address family is IPv4, setting General/UseIPv6 will change this to IPv6. -Currently, Cyclone DDS does not mix IPv4 and IPv6 addressing. Consequently, all DDSI +Currently, Eclipse Cyclone DDS does not mix IPv4 and IPv6 addressing. Consequently, all DDSI participants in the network must use the same addressing mode. When interoperating, this behaviour is the same, i.e., it will look at either IPv4 or IPv6 addresses in the advertised address information in the SPDP and SEDP discovery protocols. @@ -412,7 +412,7 @@ DDS will operate in a *global addressing* mode and will only consider discovered non-link-local addresses. In this mode, one can select any set of interface for listening to multicasts. Note that this behaviour is essentially identical to that when using IPv4, as IPv4 does not have the formal notion of address scopes that IPv6 has. If -instead only a link-local address is available, Cyclone DDS will run in a *link-local +instead only a link-local address is available, Eclipse Cyclone DDS will run in a *link-local addressing* mode. In this mode it will accept any address in a discovery packet, assuming that a link-local address is valid on the preferred interface. To minimise the risk involved in this assumption, it only allows the preferred interface for listening @@ -431,7 +431,7 @@ in the same way as for network interfaces. Multicasting ------------ -Cyclone DDS allows configuring to what extent multicast (the regular, any-source +Eclipse Cyclone DDS allows configuring to what extent multicast (the regular, any-source multicast as well as source-specific multicast) is to be used: + whether to use multicast for data communications, @@ -463,7 +463,7 @@ TCP support The DDSI protocol is really a protocol designed for a transport providing connectionless, unreliable datagrams. However, there are times where TCP is the only practical network transport available (for example, across a WAN). Because of this, -Cyclone DDS can use TCP instead of UDP. +Eclipse Cyclone DDS can use TCP instead of UDP. The differences in the model of operation between DDSI and TCP are quite large: DDSI is based on the notion of peers, whereas TCP communication is based on the notion of a @@ -500,7 +500,7 @@ initiated. Raw Ethernet support -------------------- -As an additional option, on Linux, Cyclone DDS can use a raw Ethernet network interface +As an additional option, on Linux, Eclipse Cyclone DDS can use a raw Ethernet network interface to communicate without a configured IP stack. @@ -581,7 +581,7 @@ Endpoint discovery .................. Although the SEDP protocol never requires any configuration, network partitioning does -interact with it: so-called ‘ignored partitions’ can be used to instruct Cyclone DDS to +interact with it: so-called ‘ignored partitions’ can be used to instruct Eclipse Cyclone DDS to completely ignore certain DCPS topic and partition combinations, which will prevent data for these topic/partition combinations from being forwarded to and from the network. @@ -623,8 +623,8 @@ received for a participant that has not yet been discovered. Controlling port numbers ======================== -The port numbers used by by Cyclone DDS are determined as follows, where the first two -items are given by the DDSI specification and the third is unique to Cyclone DDS as a +The port numbers used by by Eclipse Cyclone DDS are determined as follows, where the first two +items are given by the DDSI specification and the third is unique to Eclipse Cyclone DDS as a way of serving multiple participants by a single DDSI instance: + 2 ‘well-known’ multicast ports: ``B`` and ``B+1`` @@ -649,7 +649,7 @@ PI is the most interesting, as it relates to having multiple processes in the sa domain on a single node. Its configured value is either *auto*, *none* or a non-negative integer. This setting matters: -+ When it is *auto* (which is the default), Cyclone DDS probes UDP port numbers on ++ When it is *auto* (which is the default), Eclipse Cyclone DDS probes UDP port numbers on start-up, starting with PI = 0, incrementing it by one each time until it finds a pair of available port numbers, or it hits the limit. The maximum PI it will ever choose is ``Discovery/MaxAutoParticipantIndex`` as a way of limiting the cost of unicast @@ -674,12 +674,12 @@ item in the list. These are used only because there exist some DDSI implementat that assume each domain participant advertises a unique port number as part of the discovery protocol, and hence that there is never any need for including an explicit destination participant id when intending to address a single domain participant by -using its unicast locator. Cyclone DDS never makes this assumption, instead opting to +using its unicast locator. Eclipse Cyclone DDS never makes this assumption, instead opting to send a few bytes extra to ensure the contents of a message are all that is needed. With other implementations, you will need to check. If all DDSI implementations in the network include full addressing information in the -messages like Cyclone DDS does, then the per-domain participant ports serve no purpose +messages like Eclipse Cyclone DDS does, then the per-domain participant ports serve no purpose at all. The default ``false`` setting of ``Compatibility/ManySocketsMode`` disables the creation of these ports. @@ -706,7 +706,7 @@ retransmitting the same sample over & over again to many different readers. Sim while readers should try to avoid requesting retransmissions too often, in an interoperable system the writers should be robust against it. -In Cyclone DDS, upon receiving a Heartbeat that indicates samples are missing, a reader +In Eclipse Cyclone DDS, upon receiving a Heartbeat that indicates samples are missing, a reader will schedule the second and following retransmission requests to be sent after ``Internal/NackDelay`` or combine it with an already scheduled request if possible. Any samples received in between receipt of the Heartbeat and the sending of the AckNack will @@ -734,7 +734,7 @@ the writer simply queues all these samples for retransmission, it may well resul huge backlog of samples to be retransmitted. As a result, the ones near the end of the queue may be delayed by so much that the reader issues another retransmit request. -Therefore, Cyclone DDS limits the number of samples queued for retransmission and +Therefore, Eclipse Cyclone DDS limits the number of samples queued for retransmission and ignores (those parts of) retransmission requests that would cause the retransmit queue to contain too many samples or take too much time to process. There are two settings governing the size of these queues, and the limits are applied per timed-event thread. @@ -754,7 +754,7 @@ Samples in DDS can be arbitrarily large, and will not always fit within a single datagram. DDSI has facilities to fragment samples so they can fit in UDP datagrams, and similarly IP has facilities to fragment UDP datagrams to into network packets. The DDSI specification states that one must not unnecessarily fragment at the DDSI level, but -Cyclone DDS simply provides a fully configurable behaviour. +Eclipse Cyclone DDS simply provides a fully configurable behaviour. If the serialised form of a sample is at least ``Internal/FragmentSize``, it will be fragmented using the DDSI fragmentation. All but the last fragment @@ -835,14 +835,14 @@ priority, effectively enabling synchronous delivery for all data. Maximum sample size =================== -Cyclone DDS provides a setting, ``Internal/MaxSampleSize``, to control the maximum size +Eclipse Cyclone DDS provides a setting, ``Internal/MaxSampleSize``, to control the maximum size of samples that the service is willing to process. The size is the size of the (CDR) serialised payload, and the limit holds both for built-in data and for application data. The (CDR) serialised payload is never larger than the in-memory representation of the data. On the transmitting side, samples larger than ``MaxSampleSize`` are dropped with a -warning in the. Cyclone DDS behaves as if the sample never existed. +warning in the. Eclipse Cyclone DDS behaves as if the sample never existed. Similarly, on the receiving side, samples large than ``MaxSampleSize`` are dropped as early as possible, immediately following the reception of a sample or fragment of one, @@ -904,10 +904,10 @@ partition mappings are specified in the configuration. The first matching mappi the one that will be used. The ``*`` and ``?`` wildcards are available for the DCPS partition/topic combination in the partition mapping. -As mentioned earlier (see `Local discovery and built-in topics`_), Cyclone DDS can be -instructed to ignore all DCPS data readers and writers for certain DCPS partition/topic -combinations through the use of *IgnoredPartitions*. The ignored partitions use the -same matching rules as normal mappings, and take precedence over the normal mappings. +As mentioned earlier, Eclipse Cyclone DDS can be instructed to ignore all DCPS data +readers and writers for certain DCPS partition/topic combinations through the use of +*IgnoredPartitions*. The ignored partitions use the same matching rules as normal +mappings, and take precedence over the normal mappings. .. _`Multiple matching mappings`: @@ -926,7 +926,7 @@ data the reader will receive; it only affects the addressing on the network. Thread configuration ******************** -Cyclone DDS creates a number of threads and each of these threads has a number of +Eclipse Cyclone DDS creates a number of threads and each of these threads has a number of properties that can be controlled individually. The properties that can be controlled are: @@ -941,7 +941,7 @@ anything not specified explicitly is left at the default value. The following threads exist: + *gc*: garbage collector, which sleeps until garbage collection is requested for an - entity, at which point it starts monitoring the state of Cyclone DDS, pushing the + entity, at which point it starts monitoring the state of Eclipse Cyclone DDS, pushing the entity through whatever state transitions are needed once it is safe to do so, ending with the freeing of the memory. + *recv*: accepts incoming network packets from all sockets/ports, performs all protocol @@ -949,7 +949,7 @@ The following threads exist: timed-event thread, queues for delivery or, in special cases, delivers it directly to the data readers. + *dq.builtins*: processes all discovery data coming in from the network. -+ *lease*: performs internal liveliness monitoring of Cyclone DDS. ++ *lease*: performs internal liveliness monitoring of Eclipse Cyclone DDS. + *tev*: timed-event handling, used for all kinds of things, such as: periodic transmission of participant discovery and liveliness messages, transmission of control messages for reliable writers and readers (except those that have their own @@ -973,7 +973,7 @@ When no channels are explicitly defined, there is one channel named *user*. Reporting and tracing ********************* -Cyclone DDS can produce highly detailed traces of all traffic and internal activities. +Eclipse Cyclone DDS can produce highly detailed traces of all traffic and internal activities. It enables individual categories of information, as well as having a simple verbosity level that enables fixed sets of categories. @@ -1058,26 +1058,21 @@ Compatibility and conformance Conformance modes ================= -Cyclone DDS operates in one of three modes: *pedantic*, *strict* and *lax*; the mode is +Eclipse Cyclone DDS operates in one of three modes: *pedantic*, *strict* and *lax*; the mode is configured using the ``Compatibility/StandardsConformance`` setting. The default is *lax*. The first, *pedantic* mode, is of such limited utility that it will be removed. The second mode, *strict*, attempts to follow the *intent* of the specification while -staying close to the letter of it. The points in which it deviates from the standard are -in all probability editing errors that will be rectified in the next update. When -operated in this mode, one would expect it to be fully interoperable with other vendors’ -implementations, but this is not the case. The deviations in other vendors’ -implementations are not required to implement DDSI 2.1 (or 2.2), as is proven by, e.g., -the OpenSplice DDSI2 service, and they cannot rightly be considered ‘true’ -implementations of the DDSI 2.1 (or 2.2) standard. +staying close to the letter of it. Recent developments at the OMG have resolved these +issues and this mode is no longer of any value. The default mode, *lax*, attempts to work around (most of) the deviations of other implementations, and generally provides good interoperability without any further -settings. In lax mode, the Cyclone DDS not only accepts some invalid messages, it will +settings. In lax mode, the Eclipse Cyclone DDS not only accepts some invalid messages, it will even transmit them. The consequences for interoperability of not doing this are simply -too severe. It should be noted that if one configures two Cyclone DDS processes with +too severe. It should be noted that if one configures two Eclipse Cyclone DDS processes with different compliancy modes, the one in the stricter mode will complain about messages sent by the one in the less strict mode. @@ -1095,7 +1090,7 @@ establish bidirectional communication between the two. Disposing data may also cause problems, as RTI DDS leaves out the serialised key value and instead expects the reader to rely on an embedded hash of the key value. In the -strict modes, Cyclone DDS requires a proper key value to be supplied; in the relaxed +strict modes, Eclipse Cyclone DDS requires a proper key value to be supplied; in the relaxed mode, it is willing to accept key hash, provided it is of a form that contains the key values in an unmangled form. @@ -1106,14 +1101,14 @@ maximum length larger than 11 bytes. See the DDSI specification for details. In *strict* mode, there is interoperation with RTI DDS, but at the cost of incredibly high CPU and network load, caused by a Heartbeats and AckNacks going back-and-forth -between a reliable RTI DDS data writer and a reliable Cyclone DDS data reader. The -problem is that once Cyclone DDS informs the RTI writer that it has received all data +between a reliable RTI DDS data writer and a reliable Eclipse Cyclone DDS data reader. The +problem is that once Eclipse Cyclone DDS informs the RTI writer that it has received all data (using a valid AckNack message), the RTI writer immediately publishes a message listing the range of available sequence numbers and requesting an acknowledgement, which becomes an endless loop. There is furthermore also a difference of interpretation of the meaning of the -‘autodispose_unregistered_instances’ QoS on the writer. Cyclone DDS aligns with +‘autodispose_unregistered_instances’ QoS on the writer. Eclipse Cyclone DDS aligns with OpenSplice. diff --git a/src/docs/ddsc.rst b/src/docs/ddsc.rst index 3469f93..8df7fba 100644 --- a/src/docs/ddsc.rst +++ b/src/docs/ddsc.rst @@ -9,8 +9,8 @@ SPDX-License-Identifier: EPL-2.0 OR BSD-3-Clause -Cyclone DDS C API Reference -========================== +Eclipse Cyclone DDS C API Reference +=================================== .. doxygenindex:: :project: ddsc_api diff --git a/src/docs/index.rst b/src/docs/index.rst index f174ebb..0d729a9 100644 --- a/src/docs/index.rst +++ b/src/docs/index.rst @@ -9,10 +9,10 @@ SPDX-License-Identifier: EPL-2.0 OR BSD-3-Clause -.. CycloneDDS documentation master file +.. Eclipse Cyclone DDS documentation master file -Welcome to CycloneDDS's documentation! -===================================== +Welcome to Eclipse Cyclone DDS's documentation! +=============================================== .. toctree:: :maxdepth: 3 @@ -20,6 +20,7 @@ Welcome to CycloneDDS's documentation! GettingStartedGuide/index ddsc + config Indices and tables ================== diff --git a/src/examples/examples.rst b/src/examples/examples.rst index 96e6fe0..b9ee6d4 100644 --- a/src/examples/examples.rst +++ b/src/examples/examples.rst @@ -23,24 +23,26 @@ Examples Configuration ************* -Cyclone DDS has various configuration parameters and comes with a default built-in configuration. -To run an example, or any application that uses Cyclone DDS for its data exchange, this default -configuration is usually fine and no further action is required. +Eclipse Cyclone DDS has various configuration parameters and comes with a default built-in +configuration. To run an example, or any application that uses Eclipse Cyclone DDS for its data +exchange, this default configuration is usually fine and no further action is required. -Configuration parameters for CycloneDDS are expressed in XML and grouped together in a single XML file. -To use a custom XML configuration in an application, the ``CYCLONEDDS_URI`` environment variable needs -to be set prior to starting the application and pointed to the location of the configuration file to -be used. +Configuration parameters for Eclipse CycloneDDS are expressed in XML and grouped together in a +single XML file. To use a custom XML configuration in an application, the ``CYCLONEDDS_URI`` +environment variable needs to be set prior to starting the application and pointed to the location +of the configuration file to be used. | *Example* | **Windows:** ``set CYCLONEDDS_URI=file://%USERPROFILE%/CycloneDDS/my-config.xml`` | **Linux:** ``export CYCLONEDDS_URI="file://$HOME/CycloneDDS/my-config.xml"`` -The CycloneDDS installation comes with a set of standard configuration files for common use cases. -You update existing configuration files or create your own by using the CycloneDDS Configurator tool, -which provides context-sensitive help on available configuration parameters and their applicability. +The Eclipse CycloneDDS installation comes with a configuration file that corresponds to the default +behaviour. You can modify it or add your using any text or XML editor, or using by using the +Eclipse CycloneDDS Configurator tool, which provides context-sensitive help on available +configuration parameters and their applicability. -You can start the CycloneDDS Configuration tool through the CycloneDDS Launcher, or from your command-prompt -by entering the tools directory and running ``java -jar cycloneddsconf.jar``. The default location of the tools -directory is ``/usr/share/CycloneDDS/tools`` on Linux or ``C:\Program Files\ADLINK\Vortex DDS\share\CycloneDDS\tools`` -on Windows. +One very important part of the configuration settings are the "tracing" settings: these allow +letting Eclipse Cyclone DDS trace very detailed information to a file, and this includes the actual +configuration settings in use, including all those that are set at the default. When editing +configuration files by hand, this overview can be very useful. Increasing the Verbosity from +"warning" to, e.g., "config" already suffices for getting this information written to the log. diff --git a/src/examples/helloworld/readme.rst b/src/examples/helloworld/readme.rst index 7bb4954..80e24bf 100644 --- a/src/examples/helloworld/readme.rst +++ b/src/examples/helloworld/readme.rst @@ -16,7 +16,7 @@ Description *********** The basic HelloWorld example is used to illustrate the necessary steps to setup DCPS entities. -Note it is also used in the Getting Started Guide to explain the usage of CycloneDDS. +Note it is also used in the Getting Started Guide to explain the usage of Eclipse Cyclone DDS. Design ****** diff --git a/src/idlc/src/org/eclipse/cyclonedds/Compiler.java b/src/idlc/src/org/eclipse/cyclonedds/Compiler.java index 0caec31..6c945e5 100644 --- a/src/idlc/src/org/eclipse/cyclonedds/Compiler.java +++ b/src/idlc/src/org/eclipse/cyclonedds/Compiler.java @@ -50,11 +50,6 @@ public class Compiler try { - if (!LicenseMgr.checkout (Project.nameCaps + "_IDLC")) - { - System.exit (1); - } - String pathSep = System.getProperty ("file.separator"); String outpath = (opts.outputdir == null) ? "" : opts.outputdir + pathSep; String fileRoot; @@ -98,7 +93,7 @@ public class Compiler { System.err.println ("Input IDL file " + idl.getPath () + " is not valid"); - licenseCheckAndExit (1); + System.exit (1); } fileRoot = idl.getName ().substring (0, idl.getName ().lastIndexOf ('.')); @@ -109,12 +104,12 @@ public class Compiler if (!ppstatus.isOK ()) { System.err.println ("Error: At " + ppstatus.getFilename () + ":" + ppstatus.getLine () + ", " + ppstatus.getMessage ()); - licenseCheckAndExit(1); + System.exit(1); } if (opts.pponly) { System.out.println (ppresult.toCharArray ()); - licenseCheckAndExit (0); + System.exit (0); } ANTLRInputStream input = @@ -136,7 +131,7 @@ public class Compiler System.out.println (t.getText ()); } } - licenseCheckAndExit (0); + System.exit (0); } params.linetab = @@ -149,7 +144,7 @@ public class Compiler ParserRuleContext tree = (ParserRuleContext)parser.specification (); if (parser.getNumberOfSyntaxErrors () != 0) { - licenseCheckAndExit (1); + System.exit (1); } if (opts.dumptree) { @@ -164,7 +159,7 @@ public class Compiler jd.setModalityType (java.awt.Dialog.ModalityType.APPLICATION_MODAL); jd.setVisible (true); } - licenseCheckAndExit(0); + System.exit(0); } params.symtab = new SymbolTable (); @@ -172,18 +167,18 @@ public class Compiler gst.visit (tree); if (gst.getErrorCount () != 0) { - licenseCheckAndExit (1); + System.exit (1); } if (gst.unresolvedSymbols ()) { - licenseCheckAndExit (1); + System.exit (1); } if (opts.dumpsymbols) { System.out.println ("Symbol table pass complete, symbols are:"); params.symtab.dump (); - licenseCheckAndExit (0); + System.exit (0); } params.basename = fileRoot; @@ -209,13 +204,13 @@ public class Compiler catch (IOException x) { System.err.format("IOException: %s%n", x); - licenseCheckAndExit (1); + System.exit (1); } } catch (RecognitionException r) { r.printStackTrace (); - licenseCheckAndExit (1); + System.exit (1); } } } @@ -223,16 +218,6 @@ public class Compiler { e.printStackTrace (); } - finally - { - LicenseMgr.checkin (); - } - } - - private static void licenseCheckAndExit (int exitStatus) - { - LicenseMgr.checkin (); - System.exit (exitStatus); } private static void version () diff --git a/src/idlc/src/org/eclipse/cyclonedds/LicenseMgr.java.dummy b/src/idlc/src/org/eclipse/cyclonedds/LicenseMgr.java.dummy deleted file mode 100644 index f252b50..0000000 --- a/src/idlc/src/org/eclipse/cyclonedds/LicenseMgr.java.dummy +++ /dev/null @@ -1,25 +0,0 @@ -/* - * 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 - */ -package org.eclipse.cyclonedds; - -class LicenseMgr -{ - static boolean checkout (String feature) - { - return true; - } - - static boolean checkin () - { - return true; - } -} diff --git a/src/idlc/src/org/eclipse/cyclonedds/LicenseMgr.java.rlm b/src/idlc/src/org/eclipse/cyclonedds/LicenseMgr.java.rlm deleted file mode 100644 index 28cb679..0000000 --- a/src/idlc/src/org/eclipse/cyclonedds/LicenseMgr.java.rlm +++ /dev/null @@ -1,304 +0,0 @@ -/* - * 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 - */ -package org.eclipse.cyclonedds; - -import com.reprisesoftware.rlm.RlmHandle; -import com.reprisesoftware.rlm.RlmLicense; -import com.reprisesoftware.rlm.RlmException; - -import java.util.Properties; -import java.io.FileInputStream; -import java.io.FileNotFoundException; -import java.io.File; - -class LicenseMgr -{ - private static final String FS = System.getProperty ("file.separator"); - - private static final String LIC_PROPS_FILE = "license.properties"; - private static final String LIC_FEATURE = Project.nameCaps + "_IDLC"; - private static final String LIC_VERSION = "#VERSION#"; - private static final String LIC_REL_PATH = "etc"; - private static final String LIC_FILE_NAME = "license.lic"; - private static final String PROJECT_HOME_PROP = Project.nameCaps + "_HOME"; - - private static final String LIC_RLM_PROP = "RLM_LICENSE"; - private static final String LIC_LOC_PROP = "prismtech_LICENSE"; - - private static RlmLicense license = null; - private static RlmHandle handle = null; - - private static String vlHome = System.getProperty (PROJECT_HOME_PROP); - private static String licPropsPath; - private static String defaultLic; - private static String licRelPath; - private static String licLoc = null; // Final var that contains where it is - - private LicenseMgr () - { - } - - private static boolean getProjectHome() - { - // Use the property, if null then fall back to the env - if (vlHome == null) - { - vlHome = System.getenv(Project.nameCaps + "_HOME"); - if (vlHome == null) - { - System.err.println (Project.nameCaps + "_HOME environment variable or property must be set"); - return false; - } - } - // Need to re-ajust each time we get osplHome - setupGlobals(); - return true; - } - - private static void setupGlobals() - { - licRelPath = vlHome + FS + LIC_REL_PATH + FS; - licPropsPath = licRelPath + LIC_PROPS_FILE; - defaultLic = licRelPath + LIC_FILE_NAME; - } - - - /* Locations for license: - 1 : ${PROJECTNAME}_HOME/etc/ANY.lic - 2 : ../../../license/ANY.lic - 3 : Read from environment variable prismtech_LICENSE or RLM_LICENSE - */ - - static boolean checkout (String feature) - { - try - { - String licLocProp = System.getProperty (LIC_LOC_PROP); - if (licLocProp == null) - { - licLocProp = System.getenv(LIC_LOC_PROP); - } - - if (licLocProp != null && licLocProp.length() != 0) - { - File f = new File(licLocProp); - if (f.exists()) - { - // Property pointed at a license file directly - licLoc = licLocProp; - } - else - { - String licFileLoc = licLocProp+FS+LIC_FILE_NAME; - f = new File(licFileLoc); - if (f.exists()) - { - // Property pointed at the directory containing - // a license.lic - licLoc = licFileLoc; - } - else - { - // Try whatever they put on the property as it could - // be the server setting - licLoc = licLocProp; - } - } - } - else - { - // check RLM_LICENSE - String licRlmProp = System.getProperty (LIC_RLM_PROP); - - if (licRlmProp == null) - { - licRlmProp = System.getenv(LIC_RLM_PROP); - } - - if (licRlmProp != null && licRlmProp.length() != 0) - { - File f = new File(licRlmProp); - if (f.exists()) - { - // Property pointed at a license file directly - licLoc = licRlmProp; - } - else - { - String licFileLoc = licRlmProp+FS+LIC_FILE_NAME; - f = new File(licFileLoc); - if (f.exists()) - { - // Property pointed at the directory containing - // a license.lic - licLoc = licFileLoc; - } - else - { - // Try whatever they put on the property as it could - // be the server setting - licLoc = licRlmProp; - } - } - } - } - - - // NOTE: VortexLite - This section is not used?? - if (licLoc == null) - { - // No Property set lets check for a properties file - FileInputStream fis = null; - Properties licProps = null; - - if (!getProjectHome()) - { - return false; - } - - // check for license file location in properties file - File f = new File(licPropsPath); - if (f.exists()) - { - licProps = new Properties (); - try - { - fis = new FileInputStream (licPropsPath); - licProps.load (fis); - } - catch (FileNotFoundException ex) - {} // Ignore - finally - { - fis.close(); - } - String licFileLoc = licProps.getProperty (LIC_LOC_PROP); - if (licFileLoc == null) - { - licFileLoc = System.getenv(LIC_LOC_PROP); - } - if (licFileLoc != null) - { - // Property pointed at the directory containing it - licLoc = licFileLoc; - } - } - } - - if (licLoc == null) - { - // No valid source set or found use the default as - // ${PROJECTNAME}_HOME/etc/license.lic as fall back - if (!getProjectHome()) - { - return false; - } - - File f = new File(defaultLic); - if (f.exists()) - { - // Property pointed at the directory containing a license.lic - licLoc = defaultLic; - } - else - { - // Try whatever they put on the property - licLoc = licRelPath; - } - } - - handle = new RlmHandle(licLoc, "", ""); - license = new RlmLicense(handle, feature, LIC_VERSION, 1); - return true; - } - catch (Exception ex) - { - // From Vortex_v2 there will be a license directory under Vortex_v2 where - // a license can be installed for use by all products. If a valid license - // is not found in the normal locations then we check this directory for a - // valid license. The location of the Vortex_v2 directory will be set by - // the release.com/release.bat file. - - String altLicRelPath = vlHome + FS + ".." + FS + ".." + FS + ".." + FS + "license"; - String altDefaultLic = null; - - if (altLicRelPath != null) - { - try - { - altDefaultLic = altLicRelPath + FS + "license" + FS + LIC_FILE_NAME; - File f = new File(altDefaultLic); - if (f.exists()) - { - // Property pointed at the directory containing a license.lic - licLoc = altDefaultLic; - } - else - { - // Try whatever they put on the property - licLoc = altLicRelPath; - } - handle = new RlmHandle(licLoc, "", ""); - license = new RlmLicense(handle, feature, LIC_VERSION, 1); - return true; - } - catch (Exception ex2) - { - System.err.println ("dds_idlc: License checkout failed!"); - System.err.print (" Caught " + ex2.getClass().getName() + ": "); - System.err.println (ex2.getMessage()); - } - } - else - { - System.err.println ("dds_idlc: License checkout failed!"); - System.err.print (" Caught " + ex.getClass().getName() + ": "); - System.err.println (ex.getMessage()); - } - - // If we get here then we have not found a valid license - if (license != null) - { - license.checkin (); - } - if (handle != null) - { - handle.close(); - } - } - return false; - } - - static boolean checkin () - { - if (license != null) - { - try - { - license.checkin (); - if (handle != null) - { - handle.close (); - } - return true; - } - catch (Exception ex) - { - System.err.println ("dds_idlc: License checkin failed!"); - System.err.print (" Caught " + ex.getClass().getName() + ": "); - System.err.println (ex.getMessage()); - } - } - - return false; - } -} diff --git a/src/idlc/src/org/eclipse/cyclonedds/compilers/IdlcCmdOptions.java b/src/idlc/src/org/eclipse/cyclonedds/compilers/IdlcCmdOptions.java index 4830424..2788bab 100644 --- a/src/idlc/src/org/eclipse/cyclonedds/compilers/IdlcCmdOptions.java +++ b/src/idlc/src/org/eclipse/cyclonedds/compilers/IdlcCmdOptions.java @@ -35,7 +35,8 @@ public class IdlcCmdOptions extends CmdOptions io.println (" -notopics Generate type definitions only"); io.println (" -nostamp Do not timestamp generated code"); io.println (" -lax Skip over structs containing unsupported datatypes"); - io.println (" -quiet Suppress console output other than error messages"); + io.println (" -quiet Suppress console output other than error messages (default)"); + io.println (" -verbose Enable console ouptut other than error messages"); io.println (" -map_wide Map the unsupported wchar and wstring types to char and string"); io.println (" -map_longdouble Map the unsupported long double type to double"); } @@ -72,6 +73,10 @@ public class IdlcCmdOptions extends CmdOptions { quiet = true; } + else if (arg1.equals ("-verbose") || arg1.equals ("-v")) + { + quiet = false; + } else if (arg1.equals ("-lax")) { lax = true; @@ -111,7 +116,7 @@ public class IdlcCmdOptions extends CmdOptions public boolean allstructs; public boolean notopics; public boolean nostamp; - public boolean quiet; + public boolean quiet = true; public boolean lax; public boolean mapwide; public boolean mapld; diff --git a/src/idlc/src/org/eclipse/cyclonedds/compilers/Idlcpp.java b/src/idlc/src/org/eclipse/cyclonedds/compilers/Idlcpp.java index dfe02ed..e56157a 100644 --- a/src/idlc/src/org/eclipse/cyclonedds/compilers/Idlcpp.java +++ b/src/idlc/src/org/eclipse/cyclonedds/compilers/Idlcpp.java @@ -34,7 +34,7 @@ public class Idlcpp if (opts.version) { - System.out.print ("Cyclone DDS "); + System.out.print ("Eclipse Cyclone DDS "); System.out.println ("IDL to C++ compiler v" + Project.version); } else diff --git a/src/idlc/src/org/eclipse/cyclonedds/templates/c/banner.st b/src/idlc/src/org/eclipse/cyclonedds/templates/c/banner.st index 1efea42..d27deb4 100644 --- a/src/idlc/src/org/eclipse/cyclonedds/templates/c/banner.st +++ b/src/idlc/src/org/eclipse/cyclonedds/templates/c/banner.st @@ -9,20 +9,9 @@ // SPDX-License-Identifier: EPL-2.0 OR BSD-3-Clause banner (file, date, version) ::= << -/* - * 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 - */ /**************************************************************** - Generated by Cyclone DDS IDL to C Translator + Generated by Eclipse Cyclone DDS IDL to C Translator File name: .c Source: .idl Generated: diff --git a/src/idlc/src/org/eclipse/cyclonedds/templates/h/banner.st b/src/idlc/src/org/eclipse/cyclonedds/templates/h/banner.st index 1f03b35..84c3044 100644 --- a/src/idlc/src/org/eclipse/cyclonedds/templates/h/banner.st +++ b/src/idlc/src/org/eclipse/cyclonedds/templates/h/banner.st @@ -9,20 +9,9 @@ // SPDX-License-Identifier: EPL-2.0 OR BSD-3-Clause banner (file, date, version) ::= << -/* - * 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 - */ /**************************************************************** - Generated by Cyclone DDS IDL to C Translator + Generated by Eclipse Cyclone DDS IDL to C Translator File name: .h Source: .idl Generated: diff --git a/src/idlc/src/pom.xml.in b/src/idlc/src/pom.xml.in index 9767115..f5e8ad9 100644 --- a/src/idlc/src/pom.xml.in +++ b/src/idlc/src/pom.xml.in @@ -95,17 +95,6 @@ target/generated-sources/idlc/org/eclipse/cyclonedds/Project.java - - copy-LicenseMgr - generate-sources - - copy - - - ${basedir}/org/eclipse/cyclonedds/LicenseMgr.java.dummy - target/generated-sources/idlc/org/eclipse/cyclonedds/LicenseMgr.java - - diff --git a/src/os/src/snippets/code/os_stdlib_getopt.c b/src/os/src/snippets/code/os_stdlib_getopt.c index 18f06b7..130e0a8 100644 --- a/src/os/src/snippets/code/os_stdlib_getopt.c +++ b/src/os/src/snippets/code/os_stdlib_getopt.c @@ -1,14 +1,3 @@ -/* - * 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 - */ /* ::[[ @(#) getopt.c 1.5 89/03/11 05:40:23 ]]:: */ #ifndef LINT static const char Id[] = "$Id: os_stdlib_getopt.c,v 1.2 2008-11-17 09:53:45 hansv Exp $"; diff --git a/src/tools/config/CMakeLists.txt b/src/tools/config/CMakeLists.txt index 65da738..3f7bded 100644 --- a/src/tools/config/CMakeLists.txt +++ b/src/tools/config/CMakeLists.txt @@ -13,7 +13,7 @@ find_package(Java 1.8 REQUIRED) include(UseJava) set(CONFJAR_TARGET "${CMAKE_PROJECT_NAME_SMALL}conf") -set(CMAKE_JAVA_COMPILE_FLAGS "-source" "1.8" "-target" "1.8") +#set(CMAKE_JAVA_COMPILE_FLAGS "-source" "1.8" "-target" "1.8" -Xlint:deprecation) # Oddly enough, add_jar can't deal with a resource having an absolute path (experienced on Windows), so # generate into the list-dir. diff --git a/src/tools/config/metaconfig.xml.in b/src/tools/config/metaconfig.xml.in index 903b67a..15c2ffd 100644 --- a/src/tools/config/metaconfig.xml.in +++ b/src/tools/config/metaconfig.xml.in @@ -12,94 +12,78 @@ --> - + @CMAKE_PROJECT_NAME@ is highly configurable, allowing many configuration parameters to be chosen by the user at deployment time by means of easily maintainable XML-file(s).

]]>
- + The Domain identifies the scope of communication.

]]>
- + - 0 - 230 - 0 - + 0 + any +
- - - - + + DDSI2 settings ...

- ]]> -
+ ]]>
CDR_CLIENT - - - + This element is used to group a set of channels. The channels are independent data paths through DDSI2E and by using separate threads and setting their priorities appropriately, chanenls can be used to map transport priorities to operating system scheduler priorities, ensuring system-wide end-to-end priority preservation.

- ]]> -
- - - + + This element defines a channel.

- ]]> -
- - - + + This attribute specifies name of this channel. The name should uniquely identify the channel.

- ]]> -
+ ]]>
0 - - - + This attribute sets the transport priority threshold for the channel. Each DCPS data writer has a "transport_priority" QoS and this QoS is used to select a channel for use by this writer. The selected channel is the one with the largest threshold not greater than the writer's transport priority, and if no such channel exists, the channel with the lowest threshold.

- ]]> -
+ ]]>
0
- - - + This element specifies the maximum transmit rate of auxiliary traffic on this channel (e.g. retransmits, heartbeats, etc). Bandwidth limiting uses a leaky bucket scheme. The default value "inf" means DDSI2E imposes no limitation, the underlying operating system and hardware will likely limit the maimum transmit rate.

The unit must be specified explicitly. Recognised units: Xb/s, Xbps for bits/s or XB/s, XBps for bytes/s; where X is an optional prefix: k for 103, Ki for 210, M for 106, Mi for 220, G for 109, Gi for 230.

- ]]> -
+ ]]>
0 inf
- - - + This element specifies the maximum transmit rate of new samples and directly related data, for this channel. Bandwidth limiting uses a leaky bucket scheme. The default value "inf" means DDSI2E imposes no limitation, the underlying operating system and hardware will likely limit the maimum transmit rate.

The unit must be specified explicitly. Recognised units: Xb/s, Xbps for bits/s or XB/s, XBps for bytes/s; where X is an optional prefix: k for 103, Ki for 210, M for 106, Mi for 220, G for 109, Gi for 230.

- ]]> -
+ ]]>
0 inf
- - - + This element describes the DiffServ setting the channel will apply to the networking messages. This parameter determines the value of the diffserv field of the IP version 4 packets sent on this channel which allows QoS setting to be applied to the network traffic send on this channel.
Windows platform support for setting the diffserv field is dependent on the OS version.
For Windows versions XP SP2 and 2003 to use the diffserv field the following parameter should be added to the register:

@@ -108,300 +92,231 @@ The type of this parameter is a DWORD and its value should be set to 0 to allow For Windows version 7 or higher a new API (qWAVE) has been introduced. For these platforms the specified diffserv value is mapped to one of the support traffic types. The mapping is as follows: 1-8 background traffic; 9-40 excellent traffic; 41-55 audio/video traffic; 56 voice traffic; 57-63 control traffic. When an application is run without Administrative priveleges then only the diffserv value of 0, 8, 40 or 56 is allowed.

- ]]> -
+ ]]>
0
- - - + The Compatibility elements allows specifying various settings related to compatability with standards and with other DDSI implementations.

- ]]> -
- - - + + This element governs the representation of an acknowledgement message that does not also negatively-acknowledge some samples. If set to 0, the generated acknowledgements have an invalid form and will be reject by the strict and pedantic conformance modes, but several other implementation require this setting for smooth interoperation.

If set to 1, all acknowledgements sent by DDSI2E adhere the form of acknowledgement messages allowed by the standard, but this causes problems when interoperating with these other implementations. The strict and pedantic standards conformance modes always overrule an AckNackNumbitsEmptySet=0 to prevent the transmitting of invalid messages.

- ]]> -
+ ]]>
0 - - - + When set to true, arrival of a message from a peer asserts liveliness of that peer. When set to false, only SPDP and explicit lease renewals have this effect.

- ]]> -
+ ]]>
true
- - - + This option assumes ParticipantMessageData endpoints required by the liveliness protocol are present in RTI participants even when not properly advertised by the participant discovery protocol.

- ]]> -
+ ]]>
false
- - - + This element specifies whether QoS settings set to default values are explicitly published in the discovery protocol. Implementations are to use the default value for QoS settings not published, which allows a significant reduction of the amount of data that needs to be exchanged for the discovery protocol, but this requires all implementations to adhere to the default values specified by the specifications.

When interoperability is required with an implementation that does not follow the specifications in this regard, setting this option to true will help.

- ]]> -
+ ]]>
false
- - - + This option specifies whether a network socket will be created for each domain participant on a host. The specification seems to assume that each participant has a unique address, and setting this option will ensure this to be the case. This is not the defeault.

Disabling it slightly improves performance and reduces network traffic somewhat. It also causes the set of port numbers needed by DDSI2E to become predictable, which may be useful for firewall and NAT configuration.

- ]]> -
- false -
- - - + false + true + single + none + many + single + + + This element allows a closer mimicking of the behaviour of some other DDSI implementations, albeit at the cost of generating even more invalid messages. Setting it to true ensures a Heartbeat can be sent at any time when a remote node requests one, setting it to false delays it until a valid one can be sent.

The latter is fully compliant with the specification, and no adverse effects have been observed. It is the default.

- ]]> -
+ ]]> false
- - - + This element sets the level of standards conformance of this instance of the DDSI2E Service. Stricter conformance typically means less interoperability with other implementations. Currently three modes are defined:

  • pedantic: very strictly conform to the specification, ultimately for compliancy testing, but currently of little value because it adheres even to what will most likely turn out to be editing errors in the DDSI standard. Arguably, as long as no errata have been published it is the current text that is in effect, and that is what pedantic currently does.
  • strict: a slightly less strict view of the standard than does pedantic: it follows the established behaviour where the standard is obviously in error.
  • lax: attempt to provide the smoothest possible interoperability, anticipating future revisions of elements in the standard in areas that other implementations do not adhere to, even though there is no good reason not to.

The default setting is "lax".

- ]]> -
+ ]]>
lax strict pedantic lax
- - - + The Discovery element allows specifying various parameters related to the discovery of peers.

- ]]> -
- - - + + This element controls whether or not DDSI2E advertises writers for the built-in topics from its discovery for backwards compatibility with older OpenSplice versions.

- ]]> -
+ ]]>
true - - - + This setting controls for how long endpoints discovered via a Cloud discovery service will survive after the discovery service disappeared, allowing reconnect without loss of data when the discovery service restarts (or another instance takes over).

Valid values are finite durations with an explicit unit or the keyword 'inf' for infinity. Recognised units: ns, us, ms, s, min, hr, day.

- ]]> -
+ ]]>
0 30 s
- - - + This element specifies the default multicast address for all traffic other than participant discovery packets. It defaults to Discovery/SPDPMulticastAddress.

- ]]> -
+ ]]>
0 auto
- - - This element allows overriding of the DDS Domain Id that is used for DDSI2E.

- ]]> -
- 0 - default -
- - - + Do not use.

- ]]> -
+ ]]>
true
- - - + This element specifies the maximum DDSI participant index selected by this instance of the DDSI2E service if the Discovery/ParticipantIndex is "auto".

- ]]> -
+ ]]>
9
- - - + This element specifies the DDSI participant index used by this instance of the DDSI2E service for discovery purposes. Only one such participant id is used, independent of the number of actual DomainParticipants on the node. It is either:

-
  • auto: which will attempt to automatically determine an available participant index (see also Discovery/MaxAutoParticipantIndex), or
  • \n \
  • a non-negative integer less than 120, or
  • +
    • auto: which will attempt to automatically determine an available participant index (see also Discovery/MaxAutoParticipantIndex), or
    • +
    • a non-negative integer less than 120, or
    • none:, which causes it to use arbitrary port numbers for unicast sockets which entirely removes the constraints on the participant index but makes unicast discovery impossible.

    The default is auto. The participant index is part of the port number calculation and if predictable port numbers are needed and fixing the participant index has no adverse effects, it is recommended that the second be option be used.

    - ]]> - + ]]> 0 none - - - + This element statically configures addresses for discovery.

    Valid values are finite durations with an explicit unit or the keyword 'inf' for infinity. Recognised units: ns, us, ms, s, min, hr, day.

    - ]]> -
    + ]]>
    0 - - - + This element statically configures a fault tolerant group of addresses for discovery. Each member of the group is tried in sequence until one succeeds.

    - ]]> -
    - - - + + This element statically configures an addresses for discovery.

    - ]]> -
    - - - + + This element specifies an IP address to which discovery packets must be sent, in addition to the default multicast address (see also General/AllowMulticast). Both a hostnames and a numerical IP address is accepted; the hostname or IP address may be suffixed with :PORT to explicitly set the port to which it must be sent. Multiple Peers may be specified.

    - ]]> -
    + ]]>
    0
    - - - + This element statically configures an addresses for discovery.

    - ]]> -
    - - - + + This element specifies an IP address to which discovery packets must be sent, in addition to the default multicast address (see also General/AllowMulticast). Both a hostnames and a numerical IP address is accepted; the hostname or IP address may be suffixed with :PORT to explicitly set the port to which it must be sent. Multiple Peers may be specified.

    - ]]> -
    + ]]>
    0
    - - - + The Ports element allows specifying various parameters related to the port numbers used for discovery. These all have default values specified by the DDSI 2.1 specification and rarely need to be changed.

    - ]]> -
    - - - + + This element specifies the base port number (refer to the DDSI 2.1 specification, section 9.6.1, constant PB).

    - ]]> -
    + ]]>
    1 65535 7400 - - - + This element specifies the domain gain, relating domain ids to sets of port numbers (refer to the DDSI 2.1 specification, section 9.6.1, constant DG).

    - ]]> -
    + ]]>
    250
    - - - + This element specifies the port number for multicast meta traffic (refer to the DDSI 2.1 specification, section 9.6.1, constant d2).

    - ]]> -
    + ]]>
    1
    - - - + This element specifies the port number for multicast meta traffic (refer to the DDSI 2.1 specification, section 9.6.1, constant d0).

    - ]]> -
    + ]]>
    0
    - - - + This element specifies the participant gain, relating p0, articipant index to sets of port numbers (refer to the DDSI 2.1 specification, section 9.6.1, constant PG).

    - ]]> -
    + ]]>
    2
    - - - + This element specifies the port number for unicast meta traffic (refer to the DDSI 2.1 specification, section 9.6.1, constant d3).

    - ]]> -
    + ]]>
    11
    - - - + This element specifies the port number for unicast meta traffic (refer to the DDSI 2.1 specification, section 9.6.1, constant d1).

    - ]]> -
    + ]]>
    10
    - - - + This element specifies the interval between spontaneous transmissions of participant discovery packets.

    The unit must be specified explicitly. Recognised units: ns, us, ms, s, min, hr, day.

    - ]]> -
    + ]]>
    0 1hr 0 30 s
    - - - + This element specifies the multicast address that is used as the destination for the participant discovery packets. In IPv4 mode the default is the (standardised) 239.255.0.1, in IPv6 mode it becomes ff02::ffff:239.255.0.1, which is a non-standardised link-local multicast address.

    - ]]> -
    + ]]>
    0 239.255.0.1
    - - - + The General element specifies overall DDSI2E service settings.

    - ]]> -
    - - - + + This element controls whether DDSI2E uses multicasts for data traffic.

    It is a comma-separated list of some of the following keywords: "spdp", "asm", "ssm", or either of "false" or "true".

      @@ -410,77 +325,62 @@ When an application is run without Administrative priveleges then only the diffs
    • ssm: enables the use of SSM (source-specific multicast) for all non-SPDP traffic (if supported)

    When set to "false" all multicasting is disabled. The default, "true" enables full use of multicasts. Listening for multicasts can be controlled by General/MulticastRecvNetworkInterfaceAddresses.

    - ]]> -
    + ]]>
    0 true - - - + This element allows setting the SO_DONTROUTE option for outgoing packets, to bypass the local routing tables. This is generally useful only when the routing tables cannot be trusted, which is highly unusual.

    - ]]> -
    + ]]>
    false
    - - - This element specifies whether DDSI packets are visible to all DDSI participants in the same process. It must be "true" for intra-process communications, i.e. a reader and writer communicating in the same address space. If enabled and using multicast then EnableMulticastLoopback must also be enabled.

    - ]]> -
    + + This element specifies whether DDSI packets are visible to all DDSI participants in the same process. It must be "true" for intra-process communications, i.e. a reader and writer communicating in the same address space. If enabled and using multicast then EnableMulticastLoopback must also be enabled.

    + ]]>
    false
    - - - + This element specifies whether DDSI2E allows IP multicast packets to be visible to all DDSI participants in the same node, including itself. It must be "true" for intra-node multicast communications, but if a node runs only a single DDSI2E service and does not host any other DDSI-capable programs, it should be set to "false" for improved performance.

    - ]]> -
    + ]]>
    true
    - - - + This element allows explicitly overruling the network address DDSI2E advertises in the discovery protocol, which by default is the address of the preferred network interface (General/NetworkInterfaceAddress), to allow DDSI2E to communicate across a Network Address Translation (NAT) device.

    - ]]> -
    + ]]>
    0 auto
    - - - + This element specifies the network mask of the external network address. This element is relevant only when an external network address (General/ExternalNetworkAddress) is explicitly configured. In this case locators received via the discovery protocol that are within the same external subnet (as defined by this mask) will be translated to an internal address by replacing the network portion of the external address with the corresponding portion of the preferred network interface address. This option is IPv4-only.

    - ]]> -
    + ]]>
    0 0.0.0.0
    - - - + This element specifies the size of DDSI sample fragments generated by DDSI2E. Samples larger than FragmentSize are fragmented into fragments of FragmentSize bytes each, except the last one, which may be smaller. The DDSI spec mandates a minimum fragment size of 1025 bytes, but DDSI2E will do whatever size is requested, accepting fragments of which the size is at least the minimum of 1025 and FragmentSize.

    The unit must be specified explicitly. Recognised units: B (bytes), kB & KiB (210 bytes), MB & MiB (220 bytes), GB & GiB (230 bytes).

    - ]]> -
    + ]]>
    0 1280 B
    - - - + This element specifies the maximum size of the UDP payload that DDSI2E will generate. DDSI2E will try to maintain this limit within the bounds of the DDSI specification, which means that in some cases (especially for very low values of MaxMessageSize) larger payloads may sporadically be observed (currently up to 1192 B).

    On some networks it may be necessary to set this item to keep the packetsize below the MTU to prevent IP fragmentation. In those cases, it is generally advisable to also consider reducing Internal/FragmentSize.

    The unit must be specified explicitly. Recognised units: B (bytes), kB & KiB (210 bytes), MB & MiB (220 bytes), GB & GiB (230 bytes).

    - ]]> -
    + ]]>
    0 4096 B
    - - - + This element specifies on which network interfaces DDSI2E listens to multicasts. The following options are available:

    • all: listen for multicasts on all multicast-capable interfaces; or
    • @@ -490,269 +390,700 @@ When an application is run without Administrative priveleges then only the diffs
    • a comma-separated list of network addresses: configures DDSI2E to listen for multicasts on all of the listed addresses.

    If DDSI2E is in IPv6 mode and the address of the preferred network interface is a link-local address, "all" is treated as a synonym for "preferred" and a comma-separated list is treated as "preferred" if it contains the preferred interface and as "none" if not.

    - ]]> -
    + ]]>
    0 preferred
    - - - + This element specifies the time-to-live setting for outgoing multicast packets.

    - ]]> -
    + ]]>
    0 255 32
    - - - + This element specifies the preferred network interface for use by DDSI2E. The preferred network interface determines the IP address that DDSI2E advertises in the discovery protocol (but see also General/ExternalNetworkAddress), and is also the only interface over which multicasts are transmitted. The interface can be identified by its IP address, network interface name or network portion of the address. If the value "auto" is entered here, DDSI2E will select what it considers the most suitable interface.

    - ]]> -
    + ]]>
    0 auto
    - - - + This element configures whether startup-mode should also cover transient and persistent data, for configurations where the durability service does not take care of it. Configurations without defined merge policies best leave this enabled.

    - ]]> -
    + ]]>
    true
    - - - + This element specifies how long the DDSI2E remains in its "startup" mode. While in "startup" mode all volatile reliable data published on the local node is retained as-if it were transient-local data, allowing existing readers on remote nodes to obtain the data even though discovering them takes some time. Best-effort data by definition need not arrive, and transient and persistent data are covered by the durability service.

    Once the system is stable, DDSI2E keeps track of the existence of remote readers whether or not matching writers exist locally, avoiding this discovery delay and ensuring this is merely a node startup issue.

    Setting General/StartupModeDuration to 0s will disable it.

    The unit must be specified explicitly. Recognised units: ns, us, ms, s, min, hr, day.

    - ]]> -
    + ]]>
    0 60000 0 2 s
    - - - This element can be used to DDSI2E use IPv6 instead of IPv4. This is currently an either/or switch.

    - ]]> -
    + + This element allows selecting the transport to be used (udp, udp6, tcp, tcp6, raweth)

    + ]]>
    + 0 + default +
    + + Deprecated (use Transport instead)

    + ]]>
    + false + true + default + default +
    +
    + + The Internal elements deal with a variety of settings that evolving and that are not necessarily fully supported. For the vast majority of the Internal settings, the functionality per-se is supported, but the right to change the way the options control the functionality is reserved. This includes renaming or moving options.

    + ]]>
    + + Internal

    Proxy readers that are assumed to sill be retrieving historical data get this many samples retransmitted when they NACK something, even if some of these samples have sequence numbers outside the set covered by the NACK.

    + ]]>
    + 0 +
    + + Internal

    This element controls whether to drop a reliable sample from a DDSI2E WHC before all readers have acknowledged it as soon as a later sample becomes available. It only affects DCPS data writers with a history QoS setting of KEEP_LAST with depth 1. The default setting, false, mimics the behaviour of the OpenSplice RT networking and is necessary to make the behaviour of wait_for_acknowledgements() consistent across the networking services.

    + ]]>
    + true +
    + + Internal

    This element controls which network interfaces are assumed to be capable of multicasting even when the interface flags returned by the operating system state it is not (this provides a workaround for some platforms). It is a comma-separated lists of patterns (with ? and * wildcards) against which the interface names are matched.

    + ]]>
    + 0 + +
    + + Internal

    This setting controls the interval with which a reader will continue NACK'ing missing samples in the absence of a response from the writer, as a protection mechanism against writers incorrectly stopping the sending of HEARTBEAT messages.

    +

    Valid values are finite durations with an explicit unit or the keyword 'inf' for infinity. Recognised units: ns, us, ms, s, min, hr, day.

    + ]]>
    + 0 + 1 s +
    + + Internal

    This element specifies the maximum transmit rate of auxiliary traffic not bound to a specific channel, such as discovery traffic, as well as auxiliary traffic related to a certain channel if that channel has elected to share this global AuxiliaryBandwidthLimit. Bandwidth limiting uses a leaky bucket scheme. The default value "inf" means DDSI2E imposes no limitation, the underlying operating system and hardware will likely limit the maimum transmit rate.

    +

    The unit must be specified explicitly. Recognised units: Xb/s, Xbps for bits/s or XB/s, XBps for bytes/s; where X is an optional prefix: k for 103, Ki for 210, M for 106, Mi for 220, G for 109, Gi for 230.

    + ]]>
    + 0 + inf +
    + + Internal

    This element controls which participants will have which built-in endpoints for the discovery and liveliness protocols. Valid values are:

    +
    • full: all participants have all endpoints;
    • +
    • writers: all participants have the writers, but just one has the readers;
    • +
    • minimal: only one participant has built-in endpoints.
    +

    The default is writers, as this is thought to be compliant and reasonably efficient. Minimal may or may not be compliant but is most efficient, and full is inefficient but certain to be compliant. See also Internal/ConservativeBuiltinReaderStartup.

    + ]]>
    + full + writers + minimal + writers +
    + + Internal

    This element forces all DDSI2E built-in discovery-related readers to request all historical data, instead of just one for each "topic". There is no indication that any of the current DDSI implementations requires changing of this setting, but it is conceivable that an implementation might track which participants have been informed of the existence of endpoints and which have not been, refusing communication with those that have "can't" know.

    +

    Should it be necessary to hide DDSI2E's shared discovery behaviour, set this to true and Internal/BuiltinEndpointSet to full.

    + ]]>
    false
    + + Internal

    The ControlTopic element allows configured whether DDSI2E provides a special control interface via a predefined topic or not.

    + ]]> + + Internal[DEPRECATED] + "

    This element controls whether DDSI2E should create a topic to control DDSI2E's behaviour dynamically.

    " + }, + + ]]> + false + + + Internal[DEPRECATED] + "

    This element controls after how much time an initial deaf/mute state will automatically reset.

    " + }, + +

    Valid values are finite durations with an explicit unit or the keyword 'inf' for infinity. Recognised units: ns, us, ms, s, min, hr, day.

    + ]]>
    + 0 + inf + + + Internal[DEPRECATED] + "

    This element controls whether DDSI2E defaults to deaf mode or to normal mode. This controls both the initial behaviour and what behaviour it auto-reverts to.

    + ]]>
    + 0 + false +
    + + Internal[DEPRECATED] + "

    This element controls whether DDSI2E defaults to mute mode or to normal mode. This controls both the initial behaviour and what behaviour it auto-reverts to.

    + ]]>
    + 0 + false +
    +
    + + Internal

    This element sets the maximum number of extra threads for an experimental, undocumented and unsupported direct mode.

    + ]]>
    + 1 +
    + + Internal

    This element sets the maximum number of samples that can be defragmented simultaneously for a reliable writer. This has to be large enough to handle retransmissions of historical data in addition to new samples.

    + ]]>
    + 16 +
    + + Internal

    This element sets the maximum number of samples that can be defragmented simultaneously for a best-effort writers.

    + ]]>
    + 4 +
    + + Internal

    This element controls the Maximum size of a delivery queue, expressed in samples. Once a delivery queue is full, incoming samples destined for that queue are dropped until space becomes available again.

    + ]]>
    + 256 +
    + + Internal

    Forward all messages from a writer, rather than trying to forward each sample only once. The default of trying to forward each sample only once filters out duplicates for writers in multiple partitions under nearly all circumstances, but may still publish the odd duplicate. Note: the current implementation also can lose in contrived test cases, that publish more than 2**32 samples using a single data writer in conjunction with carefully controlled management of the writer history via cooperating local readers.

    + ]]>
    + false +
    + + Internal

    When true, include keyhashes in outgoing data for topics with keys.

    + ]]>
    + false +
    + + Internal

    This elemnents allows configuring the base interval for sending writer heartbeats and the bounds within it can vary.

    +

    Valid values are finite durations with an explicit unit or the keyword 'inf' for infinity. Recognised units: ns, us, ms, s, min, hr, day.

    + ]]>
    + 0 + 100 ms + + Internal

    This attribute sets the maximum interval for periodic heartbeats.

    +

    Valid values are finite durations with an explicit unit or the keyword 'inf' for infinity. Recognised units: ns, us, ms, s, min, hr, day.

    + ]]>
    + 0 + 8 s +
    + + Internal

    This attribute sets the minimum interval that must have passed since the most recent heartbeat from a writer, before another asynchronous (not directly related to writing) will be sent.

    +

    Valid values are finite durations with an explicit unit or the keyword 'inf' for infinity. Recognised units: ns, us, ms, s, min, hr, day.

    + ]]>
    + 0 + 5 ms +
    + + Internal

    This attribute sets the minimum interval for periodic heartbeats. Other events may still cause heartbeats to go out.

    +

    Valid values are finite durations with an explicit unit or the keyword 'inf' for infinity. Recognised units: ns, us, ms, s, min, hr, day.

    + ]]>
    + 0 + 20 ms +
    +
    + + Internal

    Ack a sample only when it has been delivered, instead of when committed to delivering it.

    + ]]>
    + false +
    + + Internal

    This setting controls the default participant lease duration.

    +

    The unit must be specified explicitly. Recognised units: ns, us, ms, s, min, hr, day.

    + ]]>
    + 0 + 1hr + 0 + 10 s +
    + + Internal

    This option enables a backwards-compatible, non-compliant setting and interpretation of the control flags in fragmented data messages. To be enabled only when requiring interoperability between compliant and non-compliant versions of DDSI2E for large messages.

    + ]]>
    + false +
    + + Internal

    This element controls whether or not implementation should internally monitor its own liveliness. If liveliness monitoring is enabled, stack traces can be dumped automatically when some thread appears to have stopped making progress.

    + ]]>
    + false + + Internal

    This element controls whether or not to write stack traces to the DDSI2 trace when a thread fails to make progress (on select platforms only).

    + ]]>
    + true +
    +
    + + Internal

    This elements configures the maximum number of DCPS domain participants this DDSI2E instance is willing to service. 0 is unlimited.

    + ]]>
    + 0 +
    + + Internal

    This setting limits the maximum number of bytes queued for retransmission. The default value of 0 is unlimited unless an AuxiliaryBandwidthLimit has been set, in which case it becomes NackDelay * AuxiliaryBandwidthLimit. It must be large enough to contain the largest sample that may need to be retransmitted.

    +

    The unit must be specified explicitly. Recognised units: B (bytes), kB & KiB (210 bytes), MB & MiB (220 bytes), GB & GiB (230 bytes).

    + ]]>
    + 0 + 50 kB +
    + + Internal

    This settings limits the maximum number of samples queued for retransmission.

    + ]]>
    + 200 +
    + + Internal

    This setting controls the maximum (CDR) serialised size of samples that DDSI2E will forward in either direction. Samples larger than this are discarded with a warning.

    +

    The unit must be specified explicitly. Recognised units: B (bytes), kB & KiB (210 bytes), MB & MiB (220 bytes), GB & GiB (230 bytes).

    + ]]>
    + 0 + 2147483647 B +
    + + Internal

    This element enables heartbeat-to-ack latency among DDSI2E services by prepending timestamps to Heartbeat and AckNack messages and calculating round trip times. This is non-standard behaviour. The measured latencies are quite noisy and are currently not used anywhere.

    + ]]>
    + false +
    + + Internal

    This setting controls the minimum size of socket receive buffers. The operating system provides some size receive buffer upon creation of the socket, this option can be used to increase the size of the buffer beyond that initially provided by the operating system. If the buffer size cannot be increased to the specified size, an error is reported.

    +

    The default setting is the word "default", which means DDSI2E will attempt to increase the buffer size to 1MB, but will silently accept a smaller buffer should that attempt fail.

    +

    The unit must be specified explicitly. Recognised units: B (bytes), kB & KiB (210 bytes), MB & MiB (220 bytes), GB & GiB (230 bytes).

    + ]]>
    + 0 + default +
    + + Internal

    This setting controls the minimum size of socket send buffers. This setting can only increase the size of the send buffer, if the operating system by default creates a larger buffer, it is left unchanged.

    +

    The unit must be specified explicitly. Recognised units: B (bytes), kB & KiB (210 bytes), MB & MiB (220 bytes), GB & GiB (230 bytes).

    + ]]>
    + 0 + 64 KiB +
    + + Internal

    This element allows configuring a service that dumps a text description of part the internal state to TCP clients. By default (-1), this is disabled; specifying 0 means a kernel-allocated port is used; a positive number is used as the TCP port number.

    + ]]>
    + -1 +
    + + Internal

    This element controls whether all traffic is handled by a single receive thread or whether multiple receive threads may be used to improve latency. Currently multiple receive threads are only used for connectionless transport (e.g., UDP) and ManySocketsMode not set to single (the default).

    + ]]>
    + true + + Internal

    Receive threads dedicated to a single socket can only be triggered for termination by sending a packet. Reception of any packet will do, so termination failure due to packet loss is exceedingly unlikely, but to eliminate all risks, it will retry as many times as specified by this attribute before aborting.

    + ]]>
    + 0 + 4294967295 +
    +
    + + Internal

    This setting controls the delay between receipt of a HEARTBEAT indicating missing samples and a NACK (ignored when the HEARTBEAT requires an answer). However, no NACK is sent if a NACK had been scheduled already for a response earlier than the delay requests: then that NACK will incorporate the latest information.

    +

    The unit must be specified explicitly. Recognised units: ns, us, ms, s, min, hr, day.

    + ]]>
    + 0 + 1hr + 0 + 10 ms +
    + + Internal

    This setting controls the delay between the discovering a remote writer and sending a pre-emptive AckNack to discover the range of data available.

    +

    The unit must be specified explicitly. Recognised units: ns, us, ms, s, min, hr, day.

    + ]]>
    + 0 + 1hr + 0 + 10 ms +
    + + Internal

    This element sets the maximum size in samples of a primary re-order administration. Each proxy writer has one primary re-order administration to buffer the packet flow in case some packets arrive out of order. Old samples are forwarded to secondary re-order administrations associated with readers in need of historical data.

    + ]]>
    + 64 +
    + + Internal

    This element controls whether retransmits are prioritized over new data, speeding up recovery.

    + ]]>
    + true +
    + + Internal

    This element controls for how long a remote participant that was previously deleted will remain on a blacklist to prevent rediscovery, giving the software on a node time to perform any cleanup actions it needs to do. To some extent this delay is required internally by DDSI2E, but in the default configuration with the 'enforce' attribute set to false, DDSI2E will reallow rediscovery as soon as it has cleared its internal administration. Setting it to too small a value may result in the entry being pruned from the blacklist before DDSI2E is ready, it is therefore recommended to set it to at least several seconds.

    +

    Valid values are finite durations with an explicit unit or the keyword 'inf' for infinity. Recognised units: ns, us, ms, s, min, hr, day.

    + ]]>
    + 0 + 10s + + Internal

    This attribute controls whether the configured time during which recently deleted participants will not be rediscovered (i.e., "black listed") is enforced and following complete removal of the participant in DDSI2E, or whether it can be rediscovered earlier provided all traces of that participant have been removed already.

    + ]]>
    + false +
    +
    + + Internal

    This elements controls the addressing and timing of retransmits. Possible values are:

    +
    • never: retransmit only to the NACK-ing reader;
    • +
    • adaptive: attempt to combine retransmits needed for reliability, but send historical (transient-local) data to the requesting reader only;
    • +
    • always: do not distinguish between different causes, always try to merge.
    +

    The default is adaptive. See also Internal/RetransmitMergingPeriod.

    + ]]>
    + never + adaptive + always + adaptive +
    + + Internal

    This setting determines the size of the time window in which a NACK of some sample is ignored because a retransmit of that sample has been multicasted too recently. This setting has no effect on unicasted retransmits.

    +

    See also Internal/RetransmitMerging.

    +

    The unit must be specified explicitly. Recognised units: ns, us, ms, s, min, hr, day.

    + ]]>
    + 0 + 1s + 0 + 5 ms +
    + + Internal

    Whether or not to locally retry pushing a received best-effort sample into the reader caches when resource limits are reached.

    + ]]>
    + false +
    + + Internal

    Maximum pseudo-random delay in milliseconds between discovering a remote participant and responding to it.

    +

    The unit must be specified explicitly. Recognised units: ns, us, ms, s, min, hr, day.

    + ]]>
    + 0 + 1s + 0 + 0 ms +
    + + Internal

    This setting allows the timing of scheduled events to be rounded up so that more events can be handled in a single cycle of the event queue. The default is 0 and causes no rounding at all, i.e. are scheduled exactly, whereas a value of 10ms would mean that events are rounded up to the nearest 10 milliseconds.

    +

    The unit must be specified explicitly. Recognised units: ns, us, ms, s, min, hr, day.

    + ]]>
    + 0 + 1hr + 0 + 0 ms +
    + + Internal

    This element sets the maximum size in samples of a secondary re-order administration. The secondary re-order administration is per reader in need of historical data.

    + ]]>
    + 16 +
    + + Internal

    This element controls whether the actual sending of packets occurs on the same thread that prepares them, or is done asynchronously by another thread.

    + ]]>
    + false +
    + + Internal

    This element controls whether DDSI2E advertises all the domain participants it serves in DDSI (when set to false), or rather only one domain participant (the one corresponding to the DDSI2E process; when set to true). In the latter case DDSI2E becomes the virtual owner of all readers and writers of all domain participants, dramatically reducing discovery traffic (a similar effect can be obtained by setting Internal/BuiltinEndpointSet to "minimal" but with less loss of information).

    + ]]>
    + false +
    + + Internal

    The element controls whether the mandatory multicasting of the participant discovery packets occurs. Completely disabling multicasting requires this element be set to true, and generally requires explicitly listing peers to ping for unicast discovery.

    +

    See also General/AllowMulticast.

    + ]]>
    + false +
    + + Internal

    This element controls whether samples sent by a writer with QoS settings transport_priority >= SynchronousDeliveryPriorityThreshold and a latency_budget at most this element's value will be delivered synchronously from the "recv" thread, all others will be delivered asynchronously through delivery queues. This reduces latency at the expense of aggregate bandwidth.

    +

    Valid values are finite durations with an explicit unit or the keyword 'inf' for infinity. Recognised units: ns, us, ms, s, min, hr, day.

    + ]]>
    + 0 + inf +
    + + Internal

    This element controls whether samples sent by a writer with QoS settings latency_budget <= SynchronousDeliveryLatencyBound and transport_priority greater than or equal to this element's value will be delivered synchronously from the "recv" thread, all others will be delivered asynchronously through delivery queues. This reduces latency at the expense of aggregate bandwidth.

    + ]]>
    + 0 +
    + + Internal

    Testing options.

    + ]]>
    + + Internal

    This element controls the fraction of outgoing packets to drop, specified as samples per thousand.

    + ]]>
    + 0 +
    +
    + + Internal

    This element controls whether the response to a newly discovered participant is sent as a unicasted SPDP packet, instead of rescheduling the periodic multicasted one. There is no known benefit to setting this to false.

    + ]]>
    + true +
    + + Internal

    Do not use.

    + ]]>
    + 0 +
    + + Internal

    Watermarks for flow-control.

    + ]]>
    + + Internal

    This element controls whether DDSI2E will adapt the high-water mark to current traffic conditions, based on retransmit requests and transmit pressure.

    + ]]>
    + true +
    + + Internal

    This element sets the maximum allowed high-water mark for the DDSI2E WHCs, expressed in bytes. A writer is suspended when the WHC reaches this size.

    +

    The unit must be specified explicitly. Recognised units: B (bytes), kB & KiB (210 bytes), MB & MiB (220 bytes), GB & GiB (230 bytes).

    + ]]>
    + 0 + 100 kB +
    + + Internal

    This element sets the initial level of the high-water mark for the DDSI2E WHCs, expressed in bytes.

    +

    The unit must be specified explicitly. Recognised units: B (bytes), kB & KiB (210 bytes), MB & MiB (220 bytes), GB & GiB (230 bytes).

    + ]]>
    + 0 + 30 kB +
    + + Internal

    This element sets the low-water mark for the DDSI2E WHCs, expressed in bytes. A suspended writer resumes transmitting when its DDSI2E WHC shrinks to this size.

    +

    The unit must be specified explicitly. Recognised units: B (bytes), kB & KiB (210 bytes), MB & MiB (220 bytes), GB & GiB (230 bytes).

    + ]]>
    + 0 + 1 kB +
    +
    + + Internal

    This element enables the batching of write operations. By default each write operation writes through the write cache and out onto the transport. Enabling write batching causes multiple small write operations to be aggregated within the write cache into a single larger write. This gives greater throughput at the expense of latency. Currently there is no mechanism for the write cache to automatically flush itself, so that if write batching is enabled, the application may havee to use the dds_write_flush function to ensure thta all samples are written.

    + ]]>
    + false +
    + + Internal

    This setting controls the maximum duration for which actual deletion of a reliable writer with unacknowledged data in its history will be postponed to provide proper reliable transmission.

    +

    The unit must be specified explicitly. Recognised units: ns, us, ms, s, min, hr, day.

    + ]]>
    + 0 + 1hr + 0 + 1 s +
    - - - The Internal elements deal with a variety of settings that evolving and that are not necessarily fully supported. For the vast majority of the Internal settings, the functionality per-se is supported, but the right to change the way the options control the functionality is reserved. This includes renaming or moving options.

    - ]]> -
    -
    - - - + The Partitioning element specifies DDSI2E network partitions and how DCPS partition/topic combinations are mapped onto the network partitions.

    - ]]> -
    - - - + + The IgnoredPartitions element specifies DCPS partition/topic combinations that are not distributed over the network.

    - ]]> -
    - - - + + This element can be used to prevent certain combinations of DCPS partition and topic from being transmitted over the network. DDSI2E will complete ignore readers and writers for which all DCPS partitions as well as their topic is ignored, not even creating DDSI readers and writers to mirror the DCPS ones.

    - ]]> -
    - - - + + This attribute specifies a partition and a topic expression, separated by a single '.', that are used to determine if a given partition and topic will be ignored or not. The expressions may use the usual wildcards '*' and '?'. DDSI2E will consider an wildcard DCPS partition to match an expression iff there exists a string that satisfies both expressions.

    - ]]> -
    + ]]>
    0
    - - - + The NetworkPartitions element specifies the DDSI2E network partitions.

    - ]]> -
    - - - + + This element defines a DDSI2E network partition.

    - ]]> -
    - - - + + This attribute specifies the multicast addresses associated with the network partition as a comma-separated list. Readers matching this network partition (cf. Partitioning/PartitionMappings) will listen for multicasts on all of these addresses and advertise them in the discovery protocol. The writers will select the most suitable address from the addresses advertised by the readers.

    - ]]> -
    + ]]>
    0 - - - + This attribute is a placeholder.

    - ]]> -
    + ]]>
    true
    - - - + This attribute specifies the name of this DDSI2E network partition. Two network partitions cannot have the same name.

    - ]]> -
    + ]]>
    0
    - - - + This attribute selects the DDSI2E security profile for encrypting the traffic mapped to this DDSI2E network partition. The default "null" means the network partition is unsecured; any other name refers to a security profile defined using the Security/SecurityProfile elements.

    - ]]> -
    + ]]>
    0 null
    - - - + The PartitionMappings element specifies the mapping from DCPS partition/topic combinations to DDSI2E network partitions.

    - ]]> -
    - - - + + This element defines a mapping from a DCPS partition/topic combination to a DDSI2E network partition. This allows partitioning data flows by using special multicast addresses for part of the data and possibly also encrypting the data flow.

    - ]]> -
    - - - + + This attribute specifies a partition and a topic expression, separated by a single '.', that are used to determine if a given partition and topic maps to the DDSI2E network partition named by the NetworkPartition attribute in this PartitionMapping element. The expressions may use the usual wildcards '*' and '?'. DDSI2E will consider a wildcard DCPS partition to match an expression if there exists a string that satisfies both expressions.

    - ]]> -
    + ]]>
    0 - - - + This attribute specifies which DDSI2E network partition is to be used for DCPS partition/topic combinations matching the DCPSPartitionTopic attribute within this PartitionMapping element.

    - ]]> -
    + ]]>
    0
    - - - + The SSL element allows specifying various parameters related to using SSL/TLS for DDSI over TCP.

    - ]]> -
    - - - + + If disabled this allows SSL connections to occur even if an X509 certificate fails verification.

    - ]]> -
    + ]]>
    true - - - + The set of ciphers used by SSL/TLS

    - ]]> -
    + ]]>
    0 ALL:!ADH:!LOW:!EXP:!MD5:@STRENGTH
    - - - + This enables SSL/TLS for TCP.

    - ]]> -
    + ]]>
    false
    - - - + The SSL/TLS random entropy file name.

    - ]]> -
    + ]]>
    0
    - - - + The SSL/TLS key pass phrase for encrypted keys.

    - ]]> -
    + ]]>
    0 secret
    - - - + The SSL/TLS key and certificate store file name. The keystore must be in PEM format.

    - ]]> -
    + ]]>
    0 keystore
    - - - + The minimum TLS version that may be negotiated, valid values are 1.2 and 1.3.

    + ]]>
    + 1.2 + 1.3 + 1.3 + + + This enables the use of self signed X509 certificates.

    - ]]> -
    + ]]>
    false
    - - - + This enables an SSL server checking the X509 certificate of a connecting client.

    - ]]> -
    - false + ]]>
    + true
    - - - + The Security element specifies DDSI2E security profiles that can be used to encrypt traffic mapped to DDSI2E network partitions.

    - ]]> -
    - - - + + This element defines a DDSI2E security profile.

    - ]]> -
    - - - + + This attribute specifies the cipher to be used for encrypting traffic over network partitions secured by this security profile. The possible ciphers are:

    • aes128: AES with a 128-bit key;
    • aes192: AES with a 192-bit key;
    • @@ -760,8 +1091,7 @@ When an application is run without Administrative priveleges then only the diffs
    • blowfish: the Blowfish cipher with a 128 bit key;
    • null: no encryption;

    SHA1 is used on conjunction with all ciphers except "null" to ensure data integrity.

    - ]]> -
    + ]]>
    null blowfish aes128 @@ -769,194 +1099,162 @@ When an application is run without Administrative priveleges then only the diffs aes256 null - - - + The CipherKey attribute is used to define the secret key required by the cipher selected using the Cipher attribute. The value can be a URI referencing an external file containing the secret key, or the secret key can be defined in-place as a string value.

    The key must be specified as a hexadecimal string with each character representing 4 bits of the key. E.g., 1ABC represents the 16-bit key 0001 1010 1011 1100. The key should not follow a well-known pattern and must exactly match the key length of the selected cipher.

    A malformed key will cause the security profile to be marked as invalid, and disable all network partitions secured by the (invalid) security profile to prevent information leaks.

    As all DDS applications require read access to the XML configuration file, for security reasons it is recommended to store the secret key in an external file in the file system, referenced by its URI. The file should be protected against read and write access from other users on the host.

    - ]]> -
    + ]]>
    0
    - - - + This attribute specifies the name of this DDSI2E security profile. Two security profiles cannot have the same name.

    - ]]> -
    + ]]>
    0
    - - - + The Sizing element specifies a variety of configuration settings dealing with expected system sizes, buffer sizes, &c.

    - ]]> -
    - - - + + This element specifies the size of one allocation unit in the receive buffer. Must be greater than the maximum packet size by a modest amount (too large packets are dropped). Each allocation is shrunk immediately after processing a message, or freed straightaway.

    The unit must be specified explicitly. Recognised units: B (bytes), kB & KiB (210 bytes), MB & MiB (220 bytes), GB & GiB (230 bytes).

    - ]]> -
    + ]]>
    0 128 KiB - - - This element sets the size of a single receive buffer. Many receive buffers may be needed. Their size must be greater than ReceiveBufferChunkSize by a modest amount.

    - ]]> -
    - - - + This element sets the size of a single receive buffer. Many receive buffers may be needed. Their size must be greater than ReceiveBufferChunkSize by a modest amount.

    + ]]>
    + + This element controls whether DDSI2E will adapt the high-water mark to current traffic conditions, based on retransmit requests and transmit pressure.

    - ]]> -
    + ]]>
    true
    - - - + This element sets the maximum allowed high-water mark for the DDSI2E WHCs, expressed in bytes. A writer is suspended when the WHC reaches this size.

    The unit must be specified explicitly. Recognised units: B (bytes), kB & KiB (210 bytes), MB & MiB (220 bytes), GB & GiB (230 bytes).

    - ]]> -
    + ]]>
    0 100 kB
    - - - + This element sets the initial level of the high-water mark for the DDSI2E WHCs, expressed in bytes.

    The unit must be specified explicitly. Recognised units: B (bytes), kB & KiB (210 bytes), MB & MiB (220 bytes), GB & GiB (230 bytes).

    - ]]> -
    + ]]>
    0 30 kB
    - - - + This element sets the low-water mark for the DDSI2E WHCs, expressed in bytes. A suspended writer resumes transmitting when its DDSI2E WHC shrinks to this size.

    The unit must be specified explicitly. Recognised units: B (bytes), kB & KiB (210 bytes), MB & MiB (220 bytes), GB & GiB (230 bytes).

    - ]]> -
    + ]]>
    0 1 kB
    - - - + The TCP element allows specifying various parameters related to running DDSI over TCP.

    - ]]> -
    - - - This element enables the optional TCP transport.

    - ]]> -
    + ]]>
    + + Setting this to true means the unicast addresses in SPDP packets will be ignored and the peer address from the TCP connection will be used instead. This may help work around incorrectly advertised addresses when using TCP.

    + ]]>
    false
    - - - + This element enables the optional TCP transport - deprecated, use General/Transport instead.

    + ]]>
    + false + true + default + default + + + This element enables the TCP_NODELAY socket option, preventing multiple DDSI messages being sent in the same TCP request. Setting this option typically optimises latency over throughput.

    - ]]> -
    + ]]>
    true
    - - - + This element specifies the TCP port number on which DDSI2E accepts connections. If the port is set it is used in entity locators, published with DDSI discovery. Dynamically allocated if zero. Disabled if -1 or not configured. If disabled other DDSI services will not be able to establish connections with the service, the service can only communicate by establishing connections to other services.

    - ]]> -
    + ]]>
    -1 65535 -1
    - - - + This element specifies the timeout for blocking TCP read operations. If this timeout expires then the connection is closed.

    The unit must be specified explicitly. Recognised units: ns, us, ms, s, min, hr, day.

    - ]]> -
    + ]]>
    0 1hr 0 2 s
    - - - + This element specifies the timeout for blocking TCP write operations. If this timeout expires then the connection is closed.

    The unit must be specified explicitly. Recognised units: ns, us, ms, s, min, hr, day.

    - ]]> -
    + ]]>
    0 1hr 0 2 s
    - - - + The ThreadPool element allows specifying various parameters related to using a thread pool to send DDSI messages to multiple unicast addresses (TCP or UDP).

    - ]]> -
    - - - + + This element enables the optional thread pool.

    - ]]> -
    + ]]>
    false - - - + This elements configures the maximum number of threads in the thread pool.

    - ]]> -
    + ]]>
    8
    - - - + This elements configures the initial number of threads in the thread pool.

    - ]]> -
    + ]]>
    4
    - - - + This element is used to set thread properties.

    - ]]> -
    - - - + + This element is used to set thread properties.

    - ]]> -
    - - - + + The Name of the thread for which properties are being set. The following threads exist:

    • gc: garbage collector thread involved in deleting entities;
    • recv: receive thread, taking data from the network and running the protocol state machine;
    • @@ -966,68 +1264,54 @@ When an application is run without Administrative priveleges then only the diffs
    • xmit.CHAN: transmit thread for channel CHAN;
    • dq.CHAN: delivery thread for channel CHAN;
    • tev.CHAN: timed-even thread for channel CHAN.
    - ]]> -
    + ]]>
    0 - - - + This element configures the scheduling properties of the thread.

    - ]]> -
    + ]]>
    0 - - - + This element specifies the thread scheduling class (realtime, timeshare or default). The user may need special privileges from the underlying operating system to be able to assign some of the privileged scheduling classes.

    - ]]> -
    + ]]>
    realtime timeshare default default
    - - - + This element specifies the thread priority (decimal integer or default). Only priorities that are supported by the underlying operating system can be assigned to this element. The user may need special privileges from the underlying operating system to be able to assign some of the privileged priorities.

    - ]]> -
    + ]]>
    0 default
    - - - + This element configures the stack size for this thread. The default value default leaves the stack size at the operating system default.

    The unit must be specified explicitly. Recognised units: B (bytes), kB & KiB (210 bytes), MB & MiB (220 bytes), GB & GiB (230 bytes).

    - ]]> -
    + ]]>
    0 default
    - - - + The Tracing element controls the amount and type of information that is written into the tracing log by the DDSI service. This is useful to track the DDSI service during application development.

    - ]]> -
    - - - + + This option specifies whether the output is to be appended to an existing log file. The default is to create a new log file each time, which is generally the best option if a detailed log is generated.

    - ]]> -
    + ]]>
    false - - - + This element enables individual logging categories. These are enabled in addition to those enabled by Tracing/Verbosity. Recognised categories are:

    • fatal: all fatal errors, errors causing immediate termination
    • error: failures probably impacting correctness but not necessarily causing immediate termination
    • @@ -1045,48 +1329,38 @@ When an application is run without Administrative priveleges then only the diffs
    • >i>plist: tracing of discovery parameter list interpretation

    In addition, there is the keyword trace that enables all but radmin, topic, plist and whc

    .

    The categorisation of tracing output is incomplete and hence most of the verbosity levels and categories are not of much use in the current release. This is an ongoing process and here we describe the target situation rather than the current situation. Currently, the most useful is trace.

    - ]]> -
    + ]]>
    0
    - - - + This option specifies where the logging is printed to. Note that stdout and stderr are treated as special values, representing "standard out" and "standard error" respectively. No file is created unless logging categories are enabled using the Tracing/Verbosity or Tracing/EnabledCategory settings.

    - ]]> -
    + ]]>
    0 - DDSC_PROJECTNAME_SMALL"-trace.log" + .log
    - - - + This option specifies the file to which received and sent packets will be logged in the "pcap" format suitable for analysis using common networking tools, such as WireShark. IP and UDP headers are ficitious, in particular the destination address of received packets. The TTL may be used to distinguish between sent and received packets: it is 255 for sent packets and 128 for received ones. Currently IPv4 only.

    - ]]> -
    + ]]>
    0
    - - - + This option has no effect.

    - ]]> -
    + ]]>
    true - - - + This option has no effect

    - ]]> -
    + ]]>
    true
    - - - + This element enables standard groups of categories, based on a desired verbosity level. This is in addition to the categories enabled by the Tracing/EnableCategory setting. Recognised verbosity levels and the categories they map to are:

    • none: no DDSI2E log
    • severe: error and fatal
    • @@ -1098,8 +1372,7 @@ When an application is run without Administrative priveleges then only the diffs
    • finest: finer + trace

    While none prevents any message from being written to a DDSI2 log file.

    The categorisation of tracing output is incomplete and hence most of the verbosity levels and categories are not of much use in the current release. This is an ongoing process and here we describe the target situation rather than the current situation. Currently, the most useful verbosity levels are config, fine and finest.

    - ]]> -
    + ]]>
    finest finer fine @@ -1111,42 +1384,32 @@ When an application is run without Administrative priveleges then only the diffs none
    - - - + This element specifies the type of OS scheduling class will be used by the thread that announces its liveliness periodically.

    - ]]> -
    - - - + + This element specifies the type of OS scheduling class will be used by the thread that announces its liveliness periodically.

    - ]]> -
    - - - + + This element specifies the thread scheduling class that will be used by the watchdog thread. The user may need the appropriate privileges from the underlying operating system to be able to assign some of the privileged scheduling classes.

    - ]]> -
    + ]]>
    realtime timeshare default default - - - + This element specifies the thread priority. Only priorities that are supported by the underlying operating system can be assigned to this element. The user may need special privileges from the underlying operating system to be able to assign some of the privileged priorities.

    - ]]> -
    + ]]>
    0 - - - + This attribute specifies whether the specified Priority is a relative or absolute priority.

    - ]]> -
    + ]]>
    relative absolute relative @@ -1155,6 +1418,6 @@ When an application is run without Administrative priveleges then only the diffs
    - + diff --git a/src/tools/config/org/eclipse/cyclonedds/common/util/Config.java b/src/tools/config/org/eclipse/cyclonedds/common/util/Config.java index 76859e6..ab41971 100644 --- a/src/tools/config/org/eclipse/cyclonedds/common/util/Config.java +++ b/src/tools/config/org/eclipse/cyclonedds/common/util/Config.java @@ -103,153 +103,6 @@ public class Config { return config; } - /** - * Loads the release information from a file named RELEASEINFO located in - * the etc directory of the installation. - * - * @return true if the release information could be loaded, false otherwise. - */ - public boolean loadReleaseInfo(){ - FileInputStream fis = null; - if (config == null){ - config = new Properties (); - } - boolean result = true; - String homeDir = System.getenv("OSPL_HOME"); - String separator = System.getProperty("file.separator"); - File releaseFile = new File (homeDir + separator + "etc" + separator + "RELEASEINFO"); - if(releaseFile.exists()) { - try { - fis = new FileInputStream(releaseFile); - config.load(fis); - } catch (FileNotFoundException e) { - result = false; - } catch (IOException e) { - result = false; - } finally { - if (fis != null) { - try { - fis.close(); - } catch (IOException ie) { - result = false; - } - } - } - } - - // If we don't have a value for the version property then try - // to load the value from the development tree RELEASE file - String version = config.getProperty("PACKAGE_VERSION"); - if (version == null) { - releaseFile = new File (homeDir + separator + "release_info" + separator + "RELEASE"); - if(releaseFile.exists()) { - try { - fis = new FileInputStream(releaseFile); - config.load(fis); - } catch (FileNotFoundException e) { - result = false; - } catch (IOException e) { - result = false; - } finally { - if (fis != null) { - try { - fis.close(); - } catch (IOException ie) { - result = false; - } - } - } - } - } - if(!result){ - config = null; - } - return result; - } - - /** - * Loads the default configuration. This located in the home directory of - * the user in the '.splice_tooling.properties' file. - * - * @return true if the default configuration could be loaded, false - * otherwise. - */ - public boolean loadDefault(){ - String key, value; - boolean result = true; - String homeDir = System.getProperty("user.home"); - String separator = System.getProperty("file.separator"); - config = new Properties(); - FileInputStream fis = null; - - // Load the release information so that we have the PACKAGE_VERSION property. - result = loadReleaseInfo(); - - if (result) { - String version = config.getProperty("PACKAGE_VERSION"); - if (version != null) { - version = version.replaceAll("\"", ""); - version = new String ("." + version); - } else { - version = new String (""); - } - configFile = new File(homeDir + separator + ".ospl_tooling.properties" + version); - } else { - configFile = new File(homeDir + separator + ".ospl_tooling.properties"); - // Reset the result flag. - result = true; - } - - if(!(configFile.exists())) { - try { - configFile.createNewFile(); - } catch (IOException e) { - result = false; - } - } else { - try { - fis = new FileInputStream(configFile); - config.load(fis); - Properties newConfig = new Properties(config); - if(validator != null){ - Iterator iter = config.keySet().iterator(); - - while(iter.hasNext()){ - key = (String)iter.next(); - value = config.getProperty(key); - value = validator.getValidatedValue(key, value); - - if(value == null){ - newConfig.remove(key); - } else { - newConfig.setProperty(key, value); - } - } - } - config = newConfig; - } catch (FileNotFoundException e) { - result = false; - } catch (IOException e) { - result = false; - } finally { - if (fis != null) { - try { - fis.close(); - } catch (IOException ie) { - result = false; - } - } - } - } - if(!result){ - config = null; - configFile = null; - } - return result; - } - - - /** * Loads the configuration from the supplied URI. * diff --git a/src/tools/config/org/eclipse/cyclonedds/common/util/ConfigModeIntializer.java b/src/tools/config/org/eclipse/cyclonedds/common/util/ConfigModeIntializer.java deleted file mode 100644 index a70f6b6..0000000 --- a/src/tools/config/org/eclipse/cyclonedds/common/util/ConfigModeIntializer.java +++ /dev/null @@ -1,32 +0,0 @@ -/* - * 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 - */ -package org.eclipse.cyclonedds.common.util; - -public class ConfigModeIntializer { - - public static final String COMMUNITY = "COMMUNITY"; - public static final String COMMERCIAL = "COMMERCIAL"; - public static final int COMMUNITY_MODE = 1; - public static final int COMMERCIAL_MODE = 2; - public static final int COMMUNITY_MODE_FILE_OPEN = 3; - public static final int LITE_MODE = 4; - public static int CONFIGURATOR_MODE = COMMERCIAL_MODE; - - public static void setMode(int mode) { - CONFIGURATOR_MODE = mode; - } - - public int getMode() { - return CONFIGURATOR_MODE; - } - -} diff --git a/src/tools/config/org/eclipse/cyclonedds/common/util/Initializer.java b/src/tools/config/org/eclipse/cyclonedds/common/util/Initializer.java index b4d3342..8123553 100644 --- a/src/tools/config/org/eclipse/cyclonedds/common/util/Initializer.java +++ b/src/tools/config/org/eclipse/cyclonedds/common/util/Initializer.java @@ -22,8 +22,7 @@ import javax.swing.JOptionPane; /** * Base class for tooling initializers. Its responsibilities are to initialize - * logging facilities according to commandline parameters and to validate - * whether the correct Java Vitual Machine version is used. + * logging facilities according to commandline parameters. * * @date Sep 1, 2004 */ @@ -48,14 +47,6 @@ public class Initializer { if(args.length > 0){ Report.getInstance().writeInfoLog("Reading configuration from " + args[0] + "."); result = Config.getInstance().load(args[0]); - - if(!result){ - Report.getInstance().writeInfoLog("Applying default configuration."); - result = Config.getInstance().loadDefault(); - } - } - else{ - result = Config.getInstance().loadDefault(); } if(!result){ @@ -95,75 +86,4 @@ public class Initializer { } } } - - /** - * Validates whether a compatible Java virtual machine is used. - * - * The version of Java must be >= 1.4 and should be >= 1.5.0. If the - * used version is &st; 1.4, the application exits with an error message. If - * 1.4 &st;= version &st; 1.5, false is returned, but the application - * proceeds. - * - * @return true, if java version >= 1.5 and false otherwise. - */ - public boolean validateJVMVersion(){ - int token; - boolean result = true; - - String version = System.getProperty("java.version"); - StringTokenizer tokenizer = new StringTokenizer(version, "."); - - if(tokenizer.hasMoreTokens()){ - token = Integer.parseInt(tokenizer.nextToken()); - - if(token < 1){ - this.printVersionErrorAndExit(version); - } - - if(tokenizer.hasMoreTokens()){ - token = Integer.parseInt(tokenizer.nextToken()); - - if(token < 4){ - this.printVersionErrorAndExit(version); - } else if(token == 4){ - result = false; - } - } - else{ - this.printVersionErrorAndExit(version); - result = false; - } - } - else{ - this.printVersionErrorAndExit(version); - result = false; - } - return result; - } - - /** - * Prints JVM version demands as well as the used version and exits the - * application. - */ - private void printVersionErrorAndExit(String version){ - System.err.println("Your Java version is '" + version + "', but version >= '1.4' is required.\nBailing out..."); - System.exit(0); - } - - /** - * Displays a Java version warning. - * - * @param parent - * The GUI parent which must be used as parent for displaying the - * message. If the supplied component == null, the version - * warning is displayed on standard out (System.out). - */ - public void showVersionWarning(Component parent){ - if(parent != null){ - JOptionPane.showMessageDialog(parent, "You are using Java version " + System.getProperty("java.version") + ",\nbut version >= 1.5.0 is recommended.", "Warning", JOptionPane.WARNING_MESSAGE); - } else{ - System.err.println("You are using Java version " + System.getProperty("java.version") - + ",\nbut version >= 1.5.0 is recommended."); - } - } } diff --git a/src/tools/config/org/eclipse/cyclonedds/config/SpliceConfig.java b/src/tools/config/org/eclipse/cyclonedds/config/SpliceConfig.java index ceea796..71a3d0d 100644 --- a/src/tools/config/org/eclipse/cyclonedds/config/SpliceConfig.java +++ b/src/tools/config/org/eclipse/cyclonedds/config/SpliceConfig.java @@ -34,7 +34,6 @@ public class SpliceConfig extends Initializer { String uri = null; SpliceConfig t = new SpliceConfig(); - t.validateJVMVersion(); for (int i = 0; i < args.length; i++) { if ("-noredirect".equals(args[i])) { diff --git a/src/tools/config/org/eclipse/cyclonedds/config/data/DataConfiguration.java b/src/tools/config/org/eclipse/cyclonedds/config/data/DataConfiguration.java index fefb241..729f799 100644 --- a/src/tools/config/org/eclipse/cyclonedds/config/data/DataConfiguration.java +++ b/src/tools/config/org/eclipse/cyclonedds/config/data/DataConfiguration.java @@ -32,7 +32,6 @@ import javax.xml.transform.TransformerFactory; import javax.xml.transform.dom.DOMSource; import javax.xml.transform.stream.StreamResult; -import org.eclipse.cyclonedds.common.util.ConfigModeIntializer; import org.eclipse.cyclonedds.common.util.Report; import org.eclipse.cyclonedds.config.meta.MetaAttribute; import org.eclipse.cyclonedds.config.meta.MetaConfiguration; @@ -100,161 +99,6 @@ public class DataConfiguration { } this.initExisting(repair); this.file = file; - - if (ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.LITE_MODE) { - // The following code is document validation specific to OpenSplice - int currentMode = ConfigModeIntializer.CONFIGURATOR_MODE; - - if (ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.COMMERCIAL_MODE) { - ConfigModeIntializer.setMode(ConfigModeIntializer.COMMERCIAL_MODE); - } - /* correct service tags */ - DataElement dataDomain = findDataElement(this.rootElement, "Domain"); - ArrayList domainServices = new ArrayList(); - /* collect all service tags */ - for (DataNode dn : dataDomain.getChildren()) { - if (dn instanceof DataElement) { - if (dn.getNode().getNodeName().equals("Service")) { - domainServices.add((DataElement) dn); - } - } - } - - ArrayList tmpServices = new ArrayList(services); - ArrayList tmpDomainServices = new ArrayList(domainServices); - ArrayList comServices = new ArrayList(); - /* domain element is not a service */ - tmpServices.remove(dataDomain); - - for (DataElement de : domainServices) { - if (dataDomain != de) { - String domainserviceName = de.getNode().getAttributes().getNamedItem("name").getNodeValue(); - for (DataElement del : services) { - Node node = del.getNode().getAttributes().getNamedItem("name"); - if (node != null) { - String serviceName = node.getNodeValue(); - if (serviceName.equals(domainserviceName)) { - tmpDomainServices.remove(de); - } - } - } - } - } - - /* - * tmpDomainServices now contains a list of services that are - * not in the configuration file but which are configured in the - * domain tag - */ - - for (DataElement de : tmpDomainServices) { - String serviceName = de.getNode().getAttributes().getNamedItem("name").getNodeValue(); - MetaNode[] mn = ((MetaElement) this.getRootElement().getMetadata()).getChildren(); - - for (MetaNode m : mn) { - if (m instanceof MetaElement) { - MetaElement metaDomainService = findMetaElement((MetaElement) rootElement.getMetadata(), - "Service"); - MetaElement maDomainCommand = findMetaElement(metaDomainService, "Command"); - MetaAttribute maServiceName = findMetaAttribute((MetaElement) m, "name"); - if (maServiceName != null && maDomainCommand != null) { - DataValue serviceNameValue = findDataValueforMetaValue(de, maServiceName.getValue()); - - DataValue domainCommandValue = findDataValueforMetaValue(de, - ((MetaValue) maDomainCommand.getChildren()[0])); - String name = getServiceForCommand((String) domainCommandValue.getValue()); - if (((MetaElement) m).getName().equals(name)) { - /* we got the service we need to add */ - comServices.add(m); - DataNode dn = this.addNodeWithDependency(rootElement, m); - serviceNameValue = findDataValueforMetaValue((DataElement) dn, maServiceName - .getValue()); - - /* set name for service Element */ - serviceNameValue.setValue(serviceName); - } - } - } - } - } - - for (DataElement de : services) { - if (dataDomain != de) { - String serviceName = de.getNode().getAttributes().getNamedItem("name").getNodeValue(); - for (DataElement del : domainServices) { - String domainserviceName = del.getNode().getAttributes().getNamedItem("name") - .getNodeValue(); - if (serviceName.equals(domainserviceName)) { - /* - * found a match in both service and domain - * elements remove it from the tmp services - * object - */ - tmpServices.remove(de); - MetaAttribute maDomainName = findMetaAttribute((MetaElement) del.getMetadata(), "name"); - DataValue domainNameValue = findDataValueforMetaValueInCurrentElement(del, maDomainName - .getValue()); - this.serviceNames.add(domainNameValue); - - MetaAttribute maServiceName = findMetaAttribute((MetaElement) de.getMetadata(), "name"); - DataValue serviceNameValue = findDataValueforMetaValue(de, maServiceName.getValue()); - this.serviceNames.add(serviceNameValue); - - getServiceNames().add(serviceNameValue); - getServiceNames().add(domainNameValue); - - /* set dependencies */ - domainNameValue.addDataValueDependency(serviceNameValue); - serviceNameValue.addDataValueDependency(domainNameValue); - de.addDependency(del); - del.addDependency(de); - - } - } - } - } - - ConfigModeIntializer.setMode(currentMode); - /* - * tmpServices now contains all services that are missing from - * the domain service element, we can add them now - */ - if ((!tmpDomainServices.isEmpty() || !tmpServices.isEmpty()) && !repair) { - if (!tmpDomainServices.isEmpty() && !tmpServices.isEmpty()) { - throw new DataException("There is/are " + tmpServices.size() - + " service(s) that is/are not configured in the Domain tag and " - + tmpDomainServices.size() - + " service element(s) that do not match a configured service"); - } else if (!tmpDomainServices.isEmpty()) { - throw new DataException("There are " + tmpDomainServices.size() - + " service element(s) that do not match a configured service"); - } else { - throw new DataException("There is/are " + tmpServices.size() - + " service(s) that is/are not configured in the Domain tag"); - } - } - - if (!tmpServices.isEmpty() && repair) { - for (DataElement de : tmpServices) { - String serviceName = de.getNode().getAttributes().getNamedItem("name").getNodeValue(); - createDomainServiceForSerivce(de, de.getMetadata(), serviceName); - } - } - /* remove commerial items from xml tree in community mode */ - for (MetaNode m : comServices) { - if (m.getVersion().equals(ConfigModeIntializer.COMMERCIAL) - && (currentMode == ConfigModeIntializer.COMMUNITY_MODE || currentMode == ConfigModeIntializer.COMMUNITY_MODE_FILE_OPEN)) { - NodeList nl = this.getDocument().getElementsByTagName( - ((MetaElement) m).getName()); - for (int i = 0; i < nl.getLength(); i++) { - Node child = nl.item(i); - if (child != null) { - child.getParentNode().removeChild(child); - } - } - } - } - } } } catch (SAXException se) { throw new DataException(se.getMessage()); @@ -352,9 +196,6 @@ public class DataConfiguration { public void addNode(DataElement parent, MetaNode child) throws DataException { if((parent.getOwner().equals(this))){ - if (ConfigModeIntializer.CONFIGURATOR_MODE == ConfigModeIntializer.COMMUNITY_MODE_FILE_OPEN) { - ConfigModeIntializer.setMode(ConfigModeIntializer.COMMUNITY_MODE); - } DataNode added = this.createDataForMeta(parent, child); if(parent.equals(this.rootElement)){ @@ -372,9 +213,6 @@ public class DataConfiguration { public DataNode addNodeWithDependency(DataElement parent, MetaNode child) throws DataException { DataNode result = null; if ((parent.getOwner().equals(this))) { - if (ConfigModeIntializer.CONFIGURATOR_MODE == ConfigModeIntializer.COMMUNITY_MODE_FILE_OPEN) { - ConfigModeIntializer.setMode(ConfigModeIntializer.COMMUNITY_MODE); - } DataNode added = this.createDataForMeta(parent, child); if (parent.equals(this.rootElement)) { @@ -432,11 +270,6 @@ public class DataConfiguration { /* get the newly created domain element */ dataDomain = (DataElement) addNodeWithDependency(dataDomain, metaDomainService); - if (metaNode.getVersion().equals(ConfigModeIntializer.COMMERCIAL) - && (ConfigModeIntializer.CONFIGURATOR_MODE == ConfigModeIntializer.COMMUNITY_MODE || ConfigModeIntializer.CONFIGURATOR_MODE == ConfigModeIntializer.COMMUNITY_MODE_FILE_OPEN)) { - commercialServices.add(dataDomain.getNode()); - } - /* * find name and command DataValue objects for the domain element */ @@ -581,7 +414,7 @@ public class DataConfiguration { try{ TransformerFactory tFactory = TransformerFactory.newInstance(); - tFactory.setAttribute("indent-number", new Integer(4)); + tFactory.setAttribute("indent-number", Integer.valueOf(4)); Transformer transformer = tFactory.newTransformer(); transformer.setOutputProperty(OutputKeys.OMIT_XML_DECLARATION, "yes"); transformer.setOutputProperty(OutputKeys.METHOD, "xml"); @@ -863,10 +696,6 @@ public class DataConfiguration { throw new DataException("RootElement is 'null'."); } this.document.appendChild(domElement); - if (ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.LITE_MODE) { - domElement.setAttribute("version", Double.toString(this.metadata.getVersion())); - } - this.rootElement = new DataElement(metaElement, domElement); this.rootElement.setOwner(this); diff --git a/src/tools/config/org/eclipse/cyclonedds/config/data/DataElement.java b/src/tools/config/org/eclipse/cyclonedds/config/data/DataElement.java index 4048405..dae6ae6 100644 --- a/src/tools/config/org/eclipse/cyclonedds/config/data/DataElement.java +++ b/src/tools/config/org/eclipse/cyclonedds/config/data/DataElement.java @@ -13,7 +13,6 @@ package org.eclipse.cyclonedds.config.data; import java.util.ArrayList; -import org.eclipse.cyclonedds.common.util.ConfigModeIntializer; import org.eclipse.cyclonedds.config.meta.MetaAttribute; import org.eclipse.cyclonedds.config.meta.MetaElement; import org.eclipse.cyclonedds.config.meta.MetaNode; @@ -82,10 +81,6 @@ public class DataElement extends DataNode { } if(nodeMeta instanceof MetaElement){ - if (nodeMeta.getVersion().equals(ConfigModeIntializer.COMMERCIAL) - && (ConfigModeIntializer.CONFIGURATOR_MODE == ConfigModeIntializer.COMMUNITY_MODE || ConfigModeIntializer.CONFIGURATOR_MODE == ConfigModeIntializer.COMMUNITY_MODE_FILE_OPEN)) { - addToDOM = 0; - } if(count == ((MetaElement)nodeMeta).getMaxOccurrences()){ throw new DataException("Maximum number of occurrences for " + ((MetaElement)nodeMeta).getName()+ " reached."); @@ -99,10 +94,6 @@ public class DataElement extends DataNode { this.node.appendChild(textNode); } } else if(nodeMeta instanceof MetaAttribute){ - if (nodeMeta.getVersion().equals(ConfigModeIntializer.COMMERCIAL) - && (ConfigModeIntializer.CONFIGURATOR_MODE == ConfigModeIntializer.COMMUNITY_MODE || ConfigModeIntializer.CONFIGURATOR_MODE == ConfigModeIntializer.COMMUNITY_MODE_FILE_OPEN)) { - addToDOM = 0; - } if (addToDOM == 1) { ((Element)this.node).setAttributeNode((Attr)node.getNode()); } @@ -170,29 +161,15 @@ public class DataElement extends DataNode { if(count == ((MetaElement)nodeMeta).getMinOccurrences()){ throw new DataException("Minimum number of occurrences for " + ((MetaElement)nodeMeta).getName()+ " reached."); - } else if (ConfigModeIntializer.CONFIGURATOR_MODE == ConfigModeIntializer.COMMERCIAL_MODE) { + } else ((Element) this.node).removeChild(node.getNode()); - } else { - if (!nodeMeta.getVersion().equals( - ConfigModeIntializer.COMMERCIAL)) { - if (!node.getOwner().getCommercialServices() - .contains(node.getNode())) { - ((Element) this.node).removeChild(node.getNode()); - } - } - } } else if(nodeMeta instanceof MetaAttribute){ if(((MetaAttribute)nodeMeta).isRequired()){ throw new DataException("Cannot remove required attribute " + ((MetaAttribute)nodeMeta).getName()+ "."); - } else if (ConfigModeIntializer.CONFIGURATOR_MODE == ConfigModeIntializer.COMMERCIAL_MODE) { + } else { ((Element) this.node) .removeAttributeNode((Attr) node.getNode()); - } else { - if (!nodeMeta.getVersion().equals( - ConfigModeIntializer.COMMERCIAL)) { - ((Element)this.node).removeAttributeNode((Attr)node.getNode()); - } } } else { ((Element)this.node).removeChild(node.getNode()); diff --git a/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaAttribute.java b/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaAttribute.java index 45214eb..afd4682 100644 --- a/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaAttribute.java +++ b/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaAttribute.java @@ -17,8 +17,8 @@ public class MetaAttribute extends MetaNode { private MetaValue value; public MetaAttribute(String doc, String name, boolean required, - MetaValue value, String version, String dimension) { - super(doc, version, dimension); + MetaValue value, String dimension) { + super(doc, dimension); this.name = name; this.required = required; this.value = value; @@ -88,7 +88,6 @@ public class MetaAttribute extends MetaNode { result += "\nAttribute\n"; result += "-Name: " + this.name + "\n"; result += "-Required: " + this.required + "\n"; - result += "-Version: " + this.version + "\n"; result += "-Value: " + value.toString(); return result; diff --git a/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaConfiguration.java b/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaConfiguration.java index 85038ca..cd683af 100644 --- a/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaConfiguration.java +++ b/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaConfiguration.java @@ -22,7 +22,6 @@ import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.parsers.ParserConfigurationException; -import org.eclipse.cyclonedds.common.util.ConfigModeIntializer; import org.eclipse.cyclonedds.common.util.Report; import org.w3c.dom.Attr; import org.w3c.dom.Document; @@ -36,16 +35,13 @@ import org.xml.sax.SAXParseException; public class MetaConfiguration { - private double version; private final MetaElement rootElement; private final ArrayList services; private static HashMap serviceMapping = new HashMap(); - private static final double LATEST_VERSION_OSPL = 6.1; private static MetaConfiguration instance = null; - private MetaConfiguration(double version, MetaElement rootElement, ArrayList services) { - this.version = version; + private MetaConfiguration(MetaElement rootElement, ArrayList services) { this.rootElement = rootElement; this.services = services; } @@ -76,10 +72,6 @@ public class MetaConfiguration { return retVal; } - public double getVersion() { - return this.version; - } - private static MetaConfiguration load(String fileName){ MetaConfiguration config = null; @@ -87,9 +79,6 @@ public class MetaConfiguration { if(is != null){ config = load(is); - if (config != null) { - config.version = LATEST_VERSION_OSPL; - } } return config; } @@ -147,7 +136,6 @@ public class MetaConfiguration { @Override public String toString(){ StringBuffer buf = new StringBuffer(); - buf.append("MetaConfiguration version: " + this.version + "\n"); buf.append("ROOT_ELEMENT:"); buf.append(this.rootElement.toString().replaceAll("\n", "\n\t")); for(MetaElement me: this.services){ @@ -167,8 +155,6 @@ public class MetaConfiguration { try{ ArrayList metaElements = new ArrayList(); Element rootElement = dom.getDocumentElement(); - float version = Float.parseFloat(rootElement.getAttribute("version")); - NodeList children = rootElement.getChildNodes(); @@ -179,10 +165,6 @@ public class MetaConfiguration { if(childElement instanceof Element){ if("rootElement".equals(childName)){ rootMetaElement = parseElement((Element)childElement, true); - if (rootMetaElement.getName().equals("Lite") - || rootMetaElement.getName().equals("CycloneDDS")){ - ConfigModeIntializer.setMode(ConfigModeIntializer.LITE_MODE); - } } else if("element".equals(childName)){ metaElement = parseElement((Element)childElement, false); if(metaElement != null){ @@ -192,19 +174,12 @@ public class MetaConfiguration { rootMetaElement.addChild(metaElement); metaElements.add(metaElement); } - } else if ("serviceMapping".equals(childName) - && ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.LITE_MODE) { - // Service mapping only for configuring OSPL systems. - res = parseServiceMapping((Element) childElement, false); - if (!res) { - throw new MetaException("Could not resolve meta configuration for service mapping."); - } } } } - if((rootMetaElement != null) && (version != 0.0)){ - configuration = new MetaConfiguration(version, rootMetaElement, metaElements); + if((rootMetaElement != null)){ + configuration = new MetaConfiguration(rootMetaElement, metaElements); } } catch(Exception exc){ @@ -306,12 +281,10 @@ public class MetaConfiguration { String nodeName, name; int minOccurrences, maxOccurrences; String comment = null; - String version = null; String dimension = null; try{ name = element.getAttribute("name"); - version = element.getAttribute("version"); //if(!isRootElement){ minOccurrences = Integer.parseInt(element.getAttribute("minOccurrences")); @@ -372,7 +345,7 @@ public class MetaConfiguration { } if(name != null){ result = new MetaElement(comment, name, minOccurrences, - maxOccurrences, metaChildren, version, dimension); + maxOccurrences, metaChildren, dimension); } else { throw getException(element, "No name found"); } @@ -421,7 +394,7 @@ public class MetaConfiguration { MetaValue data; ArrayList metaChildren; NodeList children; - String name, comment, nodeName, version, dimension; + String name, comment, nodeName, dimension; int minOccurrences, maxOccurrences; Node node; NodeList nodes; @@ -430,7 +403,6 @@ public class MetaConfiguration { dimension = null; comment = parseComment(element); name = element.getAttribute("name"); - version = element.getAttribute("version"); minOccurrences = Integer.parseInt(element.getAttribute("minOccurrences")); maxOccurrences = Integer.parseInt(element.getAttribute("maxOccurrences")); @@ -478,7 +450,7 @@ public class MetaConfiguration { } } result = new MetaElement(comment, name, minOccurrences, - maxOccurrences, metaChildren, version, dimension); + maxOccurrences, metaChildren, dimension); } else { throw getException(element, "No data found"); } @@ -494,7 +466,7 @@ public class MetaConfiguration { private static MetaAttribute parseAttribute(Element element) throws MetaException{ MetaAttribute result; MetaValue data; - String name, comment, version; + String name, comment; boolean required; String dimension; @@ -502,15 +474,13 @@ public class MetaConfiguration { comment = parseComment(element); name = element.getAttribute("name"); required = Boolean.parseBoolean(element.getAttribute("required")); - version = element.getAttribute("version"); if(name != null){ data = parseValue(element, element.getNodeName().substring(9)); if(data != null){ dimension = getDimensionChild(element); - result = new MetaAttribute(comment, name, required, data, - version, dimension); + result = new MetaAttribute(comment, name, required, data, dimension); } else { throw getException(element, "No data found"); } diff --git a/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaElement.java b/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaElement.java index 8417800..b6afe34 100644 --- a/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaElement.java +++ b/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaElement.java @@ -20,9 +20,9 @@ public class MetaElement extends MetaNode { private ArrayList children; public MetaElement(String doc, String name, int minOccurrences, - int maxOccurrences, ArrayList children, String version, + int maxOccurrences, ArrayList children, String dimension) { - super(doc, version, dimension); + super(doc, dimension); this.name = name; this.minOccurrences = minOccurrences; this.maxOccurrences = maxOccurrences; @@ -106,7 +106,6 @@ public class MetaElement extends MetaNode { StringBuffer buf = new StringBuffer(); buf.append("\nElement\n"); buf.append("-Name: " + this.name + "\n"); - buf.append("-Version: " + this.version + "\n"); buf.append("-MinOcccurrences: " + this.minOccurrences + "\n"); buf.append("-MaxOcccurrences: " + this.maxOccurrences + "\n"); if(this.children.size() > 0){ diff --git a/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaNode.java b/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaNode.java index e52d7f5..8c5efe3 100644 --- a/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaNode.java +++ b/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaNode.java @@ -13,12 +13,10 @@ package org.eclipse.cyclonedds.config.meta; public abstract class MetaNode { String doc; - String version; String dimension; - public MetaNode(String doc, String version, String dimension) { + public MetaNode(String doc, String dimension) { this.doc = doc; - this.version = version; this.dimension = dimension; } @@ -30,10 +28,6 @@ public abstract class MetaNode { this.doc = doc; } - public String getVersion() { - return this.version; - } - public String getDimension() { return this.dimension; } diff --git a/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaValue.java b/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaValue.java index 67ebe17..ead300f 100644 --- a/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaValue.java +++ b/src/tools/config/org/eclipse/cyclonedds/config/meta/MetaValue.java @@ -11,13 +11,11 @@ */ package org.eclipse.cyclonedds.config.meta; -import org.eclipse.cyclonedds.common.util.ConfigModeIntializer; - public abstract class MetaValue extends MetaNode { Object defaultValue; public MetaValue(String doc, Object defaultValue, String dimension) { - super(doc, ConfigModeIntializer.COMMUNITY, dimension); + super(doc, dimension); this.defaultValue = defaultValue; } diff --git a/src/tools/config/org/eclipse/cyclonedds/config/swing/ConfigWindow.java b/src/tools/config/org/eclipse/cyclonedds/config/swing/ConfigWindow.java index 5aeb648..26dc2ed 100644 --- a/src/tools/config/org/eclipse/cyclonedds/config/swing/ConfigWindow.java +++ b/src/tools/config/org/eclipse/cyclonedds/config/swing/ConfigWindow.java @@ -34,7 +34,6 @@ import javax.swing.JTabbedPane; import javax.swing.KeyStroke; import javax.swing.SwingUtilities; -import org.eclipse.cyclonedds.common.util.ConfigModeIntializer; import org.eclipse.cyclonedds.common.view.MainWindow; import org.eclipse.cyclonedds.common.view.StatusPanel; import org.eclipse.cyclonedds.config.data.DataConfiguration; @@ -71,15 +70,10 @@ public class ConfigWindow extends MainWindow implements DataConfigurationListene private DataNodePopup popupSupport = null; private ConfigTransferHandler transferHandler = null; - private String windowTitle = "Configurator"; - public static final String OSPL_WINDOW_TITLE = "Vortex OpenSplice Configurator"; - public static final String LITE_WINDOW_TITLE = "Vortex DDS Configurator"; + private String windowTitle = "Eclipse Cyclone DDS Configurator"; - public static final String OSPL_SERVICE_LABEL = "Service"; - public static final String LITE_SERVICE_LABEL = "Component"; - - public static String SERVICE_LABEL; - public static String SERVICE_TEXT; + public static String SERVICE_LABEL = "Component"; + public static String SERVICE_TEXT = "component"; /** * This is the default constructor @@ -237,12 +231,7 @@ public class ConfigWindow extends MainWindow implements DataConfigurationListene return this.controller; } - public void setWindowTitle (int configMode) { - if (configMode == ConfigModeIntializer.LITE_MODE) { - this.windowTitle = LITE_WINDOW_TITLE; - } else { - this.windowTitle = OSPL_WINDOW_TITLE; - } + public void setWindowTitle () { super.setTitle(this.windowTitle); } @@ -351,10 +340,6 @@ public class ConfigWindow extends MainWindow implements DataConfigurationListene private void initialize() { this.setSize(800, 600); this.controller = new ConfigWindowController(this); - // setServiceLabel relies on the - // ConfigModeIntializer.CONFIGURATOR_MODE variable which - // has been set during construction of ConfigWndowController - this.setServiceLabel(); this.popupSupport = new DataNodePopup(); this.transferHandler = new ConfigTransferHandler(this); this.setDefaultCloseOperation(JFrame.DO_NOTHING_ON_CLOSE); @@ -373,22 +358,6 @@ public class ConfigWindow extends MainWindow implements DataConfigurationListene this.setAppLogo(); } - /** - * Set the proper service label to be used throughout the configurator UI. - * Ospl uses the label "Service" while Lite uses the label "Component" - * (since the concept of service does not really exist) - * - */ - private void setServiceLabel(){ - if (ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.LITE_MODE){ - SERVICE_LABEL = OSPL_SERVICE_LABEL; - SERVICE_TEXT = OSPL_SERVICE_LABEL.toLowerCase(); - } else { - SERVICE_LABEL = LITE_SERVICE_LABEL; - SERVICE_TEXT = LITE_SERVICE_LABEL.toLowerCase(); - } - } - /** * This method initializes jContentPane * @@ -497,7 +466,7 @@ public class ConfigWindow extends MainWindow implements DataConfigurationListene helpContentsItem.setMnemonic(KeyEvent.VK_C); helpContentsItem.setActionCommand("help"); helpContentsItem.addActionListener(getController()); - helpContentsItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_H, Event.CTRL_MASK, false)); + helpContentsItem.setAccelerator(KeyStroke.getKeyStroke("control H")); } return helpContentsItem; } @@ -530,7 +499,7 @@ public class ConfigWindow extends MainWindow implements DataConfigurationListene newItem = new JMenuItem(); newItem.setText("New..."); newItem.setMnemonic(KeyEvent.VK_N); - newItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_N, Event.CTRL_MASK, false)); + newItem.setAccelerator(KeyStroke.getKeyStroke("control N")); newItem.setActionCommand("new"); newItem.addActionListener(controller); } @@ -547,7 +516,7 @@ public class ConfigWindow extends MainWindow implements DataConfigurationListene openItem = new JMenuItem(); openItem.setText("Open..."); openItem.setMnemonic(KeyEvent.VK_O); - openItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_O, Event.CTRL_MASK, false)); + openItem.setAccelerator(KeyStroke.getKeyStroke("control O")); openItem.setActionCommand("open"); openItem.addActionListener(controller); } @@ -564,7 +533,7 @@ public class ConfigWindow extends MainWindow implements DataConfigurationListene saveItem = new JMenuItem(); saveItem.setText("Save"); saveItem.setMnemonic(KeyEvent.VK_S); - saveItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_S, Event.CTRL_MASK, false)); + saveItem.setAccelerator(KeyStroke.getKeyStroke("control S")); saveItem.setActionCommand("save"); saveItem.addActionListener(controller); } @@ -613,7 +582,7 @@ public class ConfigWindow extends MainWindow implements DataConfigurationListene exitItem = new JMenuItem(); exitItem.setText("Exit"); exitItem.setMnemonic(KeyEvent.VK_X); - exitItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_F4, Event.ALT_MASK, false)); + exitItem.setAccelerator(KeyStroke.getKeyStroke("alt F4")); exitItem.setActionCommand("exit"); exitItem.addActionListener(controller); } @@ -630,7 +599,7 @@ public class ConfigWindow extends MainWindow implements DataConfigurationListene printItem = new JMenuItem(); printItem.setText("Print..."); printItem.setMnemonic(KeyEvent.VK_P); - printItem.setAccelerator(KeyStroke.getKeyStroke(KeyEvent.VK_P, Event.CTRL_MASK, false)); + printItem.setAccelerator(KeyStroke.getKeyStroke("control P")); printItem.setActionCommand("print"); printItem.addActionListener(controller); } diff --git a/src/tools/config/org/eclipse/cyclonedds/config/swing/ConfigWindowController.java b/src/tools/config/org/eclipse/cyclonedds/config/swing/ConfigWindowController.java index 601e612..2611ff8 100644 --- a/src/tools/config/org/eclipse/cyclonedds/config/swing/ConfigWindowController.java +++ b/src/tools/config/org/eclipse/cyclonedds/config/swing/ConfigWindowController.java @@ -27,7 +27,6 @@ import javax.swing.JOptionPane; import javax.swing.SwingUtilities; import javax.swing.filechooser.FileFilter; -import org.eclipse.cyclonedds.common.util.ConfigModeIntializer; import org.eclipse.cyclonedds.common.util.Report; import org.eclipse.cyclonedds.config.data.DataConfiguration; import org.eclipse.cyclonedds.config.data.DataException; @@ -60,25 +59,12 @@ public class ConfigWindowController implements ActionListener { // Initialize the MetaConfiguration. This is done so the Configurator can know for // which product its meant for, according to the meta config file. MetaConfiguration.getInstance(); - view.setWindowTitle(ConfigModeIntializer.CONFIGURATOR_MODE); + view.setWindowTitle(); - String osplHome = System.getenv("OSPL_HOME"); File f = null; String fileSep = System.getProperty("file.separator"); - if(osplHome == null){ - f = new File(System.getProperty("user.dir") + fileSep); - } else { - f = new File(osplHome + fileSep + "etc" + fileSep + "config" + fileSep); - - if((!f.exists()) || (!f.isDirectory())){ - f = new File(osplHome + fileSep + "etc" + fileSep); - - if((!f.exists()) || (!f.isDirectory())){ - f = new File(System.getProperty("user.dir") + fileSep); - } - } - } + f = new File(System.getProperty("user.dir") + fileSep); this.openFileChooser.setCurrentDirectory(f); this.openFileChooser.setDialogTitle("Open configuration"); this.openFileChooser.setMultiSelectionEnabled(false); @@ -242,52 +228,9 @@ public class ConfigWindowController implements ActionListener { DataConfiguration config = null; try { - if (ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.COMMERCIAL_MODE && - ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.LITE_MODE) { - ConfigModeIntializer.setMode(ConfigModeIntializer.COMMUNITY_MODE_FILE_OPEN); - } - config = new DataConfiguration(f, false); } catch (DataException e) { Report.getInstance().writeInfoLog("ConfigWindowController handleOpen\n" + e.getMessage()); - if (ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.LITE_MODE) { - if (ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.COMMERCIAL_MODE) { - ConfigModeIntializer.setMode(ConfigModeIntializer.COMMUNITY_MODE); - } - - int answer = JOptionPane.showConfirmDialog( - view, - "The configuration is not valid.\nReason: " + - e.getMessage() + - "\nTry automatic repairing?", - "Invalid configuration", - JOptionPane.YES_NO_OPTION); - - if(answer == JOptionPane.YES_OPTION){ - try { - config = new DataConfiguration(f, true); - - view.setStatus("Configuration repaired successfully.", false); - } catch (DataException e1) { - JOptionPane.showMessageDialog(view, - "Configuration could not be repaired.\nReason: '" + - e.getMessage() + "'" - , "Error", JOptionPane.ERROR_MESSAGE); - handleSetStatus("Configuration could not be repaired.", false); - handleNextAction(); - } - } else if(answer == JOptionPane.NO_OPTION){ - handleSetStatus("Configuration not opened.", false); - handleNextAction(); - } - } else { - JOptionPane.showConfirmDialog( - view, - "The configuration is not valid.\nReason: " + - e.getMessage(), - "Invalid configuration", - JOptionPane.PLAIN_MESSAGE); - } } if(config != null){ view.setDataConfiguration(config); @@ -326,23 +269,11 @@ public class ConfigWindowController implements ActionListener { DataConfiguration config = null; try { - if (ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.COMMERCIAL_MODE && - ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.LITE_MODE) { - ConfigModeIntializer - .setMode(ConfigModeIntializer.COMMUNITY_MODE_FILE_OPEN); - } - config = new DataConfiguration(f, false); } catch (DataException e) { Report.getInstance().writeInfoLog( "ConfigWindowController handleOpen\n" + e.getMessage()); - if (ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.COMMERCIAL_MODE && - ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.LITE_MODE) { - ConfigModeIntializer - .setMode(ConfigModeIntializer.COMMUNITY_MODE); - } - int answer = JOptionPane.showConfirmDialog( view, "The configuration is not valid.\nReason: " @@ -533,9 +464,6 @@ public class ConfigWindowController implements ActionListener { public void run(){ view.setDataConfiguration(null); newInProgress = false; - if (ConfigModeIntializer.CONFIGURATOR_MODE == ConfigModeIntializer.COMMUNITY_MODE_FILE_OPEN) { - ConfigModeIntializer.setMode(ConfigModeIntializer.COMMUNITY_MODE); - } try { DataConfiguration config = new DataConfiguration(); view.setDataConfiguration(config); @@ -628,13 +556,8 @@ public class ConfigWindowController implements ActionListener { public static final String CONFIG_SUFFIX = ".xml"; public ConfigChooseFilter(){ - if (ConfigModeIntializer.CONFIGURATOR_MODE == ConfigModeIntializer.LITE_MODE) { - ConfigChooseFilter.description = "Cyclone DDS config files (*" + - ConfigChooseFilter.CONFIG_SUFFIX + ")"; - } else { - ConfigChooseFilter.description = "OpenSplice config files (*" + - ConfigChooseFilter.CONFIG_SUFFIX + ")"; - } + ConfigChooseFilter.description = "Eclipse Cyclone DDS config files (*" + + ConfigChooseFilter.CONFIG_SUFFIX + ")"; } @Override diff --git a/src/tools/config/org/eclipse/cyclonedds/config/swing/DataElementTableCellRenderer.java b/src/tools/config/org/eclipse/cyclonedds/config/swing/DataElementTableCellRenderer.java index a2f1c3a..d9b1844 100644 --- a/src/tools/config/org/eclipse/cyclonedds/config/swing/DataElementTableCellRenderer.java +++ b/src/tools/config/org/eclipse/cyclonedds/config/swing/DataElementTableCellRenderer.java @@ -18,7 +18,6 @@ import java.util.logging.Logger; import javax.swing.JTable; import javax.swing.table.DefaultTableCellRenderer; -import org.eclipse.cyclonedds.common.util.ConfigModeIntializer; import org.eclipse.cyclonedds.config.data.DataNode; public class DataElementTableCellRenderer extends DefaultTableCellRenderer { @@ -43,27 +42,9 @@ public class DataElementTableCellRenderer extends DefaultTableCellRenderer { node = node.getParent(); table.setToolTipText(null); - if (ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.COMMERCIAL_MODE) { - if (node.getMetadata().getVersion().equals(ConfigModeIntializer.COMMERCIAL)) { - if (ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.COMMUNITY_MODE_FILE_OPEN) { - comp.setBackground (Color.LIGHT_GRAY); - comp.setForeground (Color.GRAY); - table.setToolTipText("This element is not part of the community edition"); - } else { - comp.setBackground (Color.RED); - comp.setForeground (Color.BLACK); - table.setToolTipText("This element is found in the configuration file but not part of the community edition"); - } - } else { - comp.setBackground (Color.WHITE); - comp.setForeground (Color.BLACK); - table.setToolTipText(null); - } - } else { - comp.setBackground (Color.WHITE); - comp.setForeground (Color.BLACK); - table.setToolTipText(null); - } + comp.setBackground (Color.WHITE); + comp.setForeground (Color.BLACK); + table.setToolTipText(null); return comp; } } diff --git a/src/tools/config/org/eclipse/cyclonedds/config/swing/DataElementTableModel.java b/src/tools/config/org/eclipse/cyclonedds/config/swing/DataElementTableModel.java index a7fe7a7..6499527 100644 --- a/src/tools/config/org/eclipse/cyclonedds/config/swing/DataElementTableModel.java +++ b/src/tools/config/org/eclipse/cyclonedds/config/swing/DataElementTableModel.java @@ -16,7 +16,6 @@ import java.util.ArrayList; import javax.swing.SwingUtilities; import javax.swing.table.DefaultTableModel; -import org.eclipse.cyclonedds.common.util.ConfigModeIntializer; import org.eclipse.cyclonedds.config.data.DataAttribute; import org.eclipse.cyclonedds.config.data.DataConfiguration; import org.eclipse.cyclonedds.config.data.DataConfigurationListener; @@ -131,9 +130,7 @@ public class DataElementTableModel extends DefaultTableModel implements DataConf public boolean isCellEditable(int row, int column) { boolean result; - if(column == 1 && ConfigModeIntializer.CONFIGURATOR_MODE == ConfigModeIntializer.COMMERCIAL_MODE) { - result = true; - } else if (column == 1 && !element.getMetadata().getVersion().equals(ConfigModeIntializer.COMMERCIAL)) { + if(column == 1) { result = true; } else { result = false; diff --git a/src/tools/config/org/eclipse/cyclonedds/config/swing/DataNodePopup.java b/src/tools/config/org/eclipse/cyclonedds/config/swing/DataNodePopup.java index 36166fb..3c6fda3 100644 --- a/src/tools/config/org/eclipse/cyclonedds/config/swing/DataNodePopup.java +++ b/src/tools/config/org/eclipse/cyclonedds/config/swing/DataNodePopup.java @@ -34,7 +34,6 @@ import org.eclipse.cyclonedds.config.meta.MetaAttribute; import org.eclipse.cyclonedds.config.meta.MetaElement; import org.eclipse.cyclonedds.config.meta.MetaNode; import org.eclipse.cyclonedds.config.meta.MetaValue; -import org.eclipse.cyclonedds.common.util.ConfigModeIntializer; public class DataNodePopup implements MouseListener, ActionListener { @@ -137,10 +136,6 @@ public class DataNodePopup implements MouseListener, ActionListener { if(parentParent != null){ current = this.countOccurrences((DataElement)parent.getParent(), parent.getMetadata()); min = ((MetaElement)metaParent).getMinOccurrences(); - if (ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.COMMERCIAL_MODE && metaParent.getVersion().equals(ConfigModeIntializer.COMMERCIAL)) { - reset.setEnabled(false); - } - if(min == 0){ remove.setEnabled(true); } else if(current > min){ @@ -151,10 +146,6 @@ public class DataNodePopup implements MouseListener, ActionListener { } } else if(parent instanceof DataAttribute){ metaParent = parent.getMetadata(); - if (ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.COMMERCIAL_MODE && metaParent.getVersion().equals(ConfigModeIntializer.COMMERCIAL)) { - reset.setEnabled(false); - } - if(((MetaAttribute)metaParent).isRequired()){ remove.setEnabled(false); } @@ -387,40 +378,8 @@ public class DataNodePopup implements MouseListener, ActionListener { public void addService(DataNode dataNode, MetaNode metaNode) throws DataException { if (dataNode instanceof DataElement) { - if (ConfigModeIntializer.CONFIGURATOR_MODE != ConfigModeIntializer.LITE_MODE){ - String serviceName = null; - - String suggestedName = dataNode.getOwner().getMetaAttributeValue((MetaElement) metaNode, "name"); - /* - * generate a new name if there is already a service with the - * default name - */ - if (dataNode.getOwner().containsServiceName(suggestedName)) { - String tmp = suggestedName + "_1"; - for (int i = 1; dataNode.getOwner().containsServiceName(tmp); i++) { - tmp = suggestedName + "_" + i; - } - suggestedName = tmp; - } - - serviceName = (String) JOptionPane.showInputDialog(null, "Please enter a service name:", - "Set the service name", JOptionPane.QUESTION_MESSAGE, null, null, suggestedName); - - if (serviceName != null) { - if (!dataNode.getOwner().containsServiceName(serviceName)) { - /* get the newly created service element */ - dataNode = dataNode.getOwner().addNodeWithDependency((DataElement) dataNode, metaNode); - dataNode.getOwner().createDomainServiceForSerivce(dataNode, metaNode, serviceName); - } else { - this.notifyStatus("Error: Servicename is already in use", false, false); - } - } else { - this.notifyStatus("Error: Please fill in a servicename", false, false); - } - } else { - /* get the newly created service element */ - dataNode.getOwner().addNode((DataElement) dataNode, metaNode); - } + /* get the newly created service element */ + dataNode.getOwner().addNode((DataElement) dataNode, metaNode); } else { this.notifyStatus("Error: Unexpected type of parent found: '" + dataNode.getClass() + "'.", false, false); } diff --git a/src/tools/config/org/eclipse/cyclonedds/config/swing/HelpWindow.java b/src/tools/config/org/eclipse/cyclonedds/config/swing/HelpWindow.java index 06bc875..d167ffd 100644 --- a/src/tools/config/org/eclipse/cyclonedds/config/swing/HelpWindow.java +++ b/src/tools/config/org/eclipse/cyclonedds/config/swing/HelpWindow.java @@ -18,7 +18,6 @@ import javax.swing.JFrame; import javax.swing.WindowConstants; import javax.swing.JSplitPane; -import org.eclipse.cyclonedds.common.util.ConfigModeIntializer; import org.eclipse.cyclonedds.common.view.StatusPanel; import org.eclipse.cyclonedds.config.meta.MetaConfiguration; @@ -37,8 +36,7 @@ public class HelpWindow extends JFrame implements TreeSelectionListener { private JScrollPane docScrollPane = null; private MetaNodeDocPane docPane = null; - public static final String OSPL_HELP_WINDOW_TITLE = "Vortex OpenSplice Configurator | Help"; - public static final String LITE_HELP_WINDOW_TITLE = "Vortex DDS Configurator | Help"; + public static final String HELP_WINDOW_TITLE = "Eclipse Cyclone DDS Configurator | Help"; /** * This is the default constructor @@ -58,18 +56,13 @@ public class HelpWindow extends JFrame implements TreeSelectionListener { this.setSize(640, 480); this.setDefaultCloseOperation(WindowConstants.DISPOSE_ON_CLOSE); this.setContentPane(getJContentPane()); - setWindowTitle(ConfigModeIntializer.CONFIGURATOR_MODE); + setWindowTitle(); getElementTree().getSelectionModel().addTreeSelectionListener(this); getDocPane().setNode(getElementTree().getSelectedMetaElement()); } - public void setWindowTitle (int configMode) { - String windowTitle = "Configurator | Help"; - if (configMode == ConfigModeIntializer.LITE_MODE) { - windowTitle = LITE_HELP_WINDOW_TITLE; - } else { - windowTitle = OSPL_HELP_WINDOW_TITLE; - } + public void setWindowTitle () { + String windowTitle = HELP_WINDOW_TITLE; this.setTitle(windowTitle); }