Commit graph

303 commits

Author SHA1 Message Date
Erik Boasson
e631567c35 extend sertopic interface and move the concept of a type descriptor to just the sertopic definition
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-12-14 14:02:08 +01:00
Erik Boasson
29f542b916 iid and tkmap are integral to this DDSI stack and should be part of it
They were made available from the DCPS layer to DDSI using some function pointers, but it makes more sense to have them as part of the DDSI core.

Signed-off-by: Erik Boasson <eb@ilities.com>
2018-12-14 14:02:08 +01:00
Firas Sahli
9f51f6f9dc
Rename get and set filter functions for topic
Signed-off-by: Firas Sahli <firas.sahli@adlinktech.com>
2018-12-11 11:07:09 +01:00
Firas Sahli
05f961dec1
Rename get and set of enabled status to mask
Signed-off-by: Firas Sahli <firas.sahli@adlinktech.com>
2018-12-11 11:07:09 +01:00
Firas Sahli
99f410bc49
Rename dds_instance_lookup to dds_lookup_instance
Signed-off-by: Firas Sahli <firas.sahli@adlinktech.com>
2018-12-11 11:06:50 +01:00
Firas Sahli
af7e34f143
Remove ddsv2.h
Signed-off-by: Firas Sahli <firas.sahli@adlinktech.com>
2018-12-11 11:06:27 +01:00
Jeroen Koekkoek
3c5a209389 Fix build warnings by passing a message to CU_PASS
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-12-10 13:05:59 +01:00
Jeroen Koekkoek
74a48c5731 Replace Criterion by CUnit
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-12-06 14:48:30 +01:00
Erik Boasson
e62abe623a fix warnings on qos function names and constness
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-12-01 10:01:13 +01:00
Jeroen Koekkoek
1cf03332ca Simplify logging and remove unwanted functions from abstraction layer
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-11-30 23:42:19 +01:00
eboasson
69f563be5b
Merge pull request #60 from FirasSahliADLinktech/multiple_tests
Some missing unit tests and correct signature
2018-11-30 12:07:44 +01:00
Firas Sahli
6908e3deea
Correct signature and add tests for dds_instance_get_key
Signed-off-by: Firas Sahli <firas.sahli@adlinktech.com>
2018-11-28 10:52:14 +01:00
Firas Sahli
8aa6ceff81
Add test for dds_qos_copy and extra check to dds_qset_partition
Signed-off-by: Firas Sahli <firas.sahli@adlinktech.com>
2018-11-28 10:41:24 +01:00
Firas Sahli
4b627fd9aa
Add simple test for dds_time
Signed-off-by: Firas Sahli <firas.sahli@adlinktech.com>
2018-11-28 10:38:07 +01:00
Erik Boasson
ec68eeac29 Bring listener operations naming scheme in line with the rest
The main naming scheme is OPER_TYPE (i.e., dds_create_participant) but the listener operations were named TYPE_OPER (i.e., dds_listener_create). This commit brings the listener scheme in line with the rest, retaining the old names as a deprecated interface.

Signed-off-by: Erik Boasson <eb@ilities.com>
2018-11-09 14:18:51 +01:00
Erik Boasson
651bdfee06 Bring QoS operations naming scheme in line with the rest
The main naming scheme is OPER_TYPE (i.e., dds_create_participant) but the QoS operations were named TYPE_OPER (i.e., dds_qos_create). This commit brings the QoS scheme in line with the rest, retaining the old names as a deprecated interface.

Signed-off-by: Erik Boasson <eb@ilities.com>
2018-11-09 14:18:47 +01:00
Erik Boasson
4a4f4e22d1 dds_stream_extract_key: reserve space in destination before calling dds_stream_read_fixed_buffer
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-29 21:37:06 +08:00
Erik Boasson
f2f436bde3 wrap indirect calls to WHC in inline functions
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-29 13:28:19 +08:00
Erik Boasson
3e343d032a reduce dependency on sertopic->status_cb_entity
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-29 13:26:24 +08:00
Erik Boasson
7cb80e7851 minor refactor of CDR-to-key/keyhash generation
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-29 13:24:07 +08:00
Erik Boasson
259e4676dc fix sequencing of internal liveliness monitoring and rtps init/term
liveliness monitoring requires rtps stack initialised if initially deaf, so starting the monitoring thread must happen after rtps_init

Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-28 13:54:17 +08:00
Erik Boasson
9cab5e769c various interconnected changes for ddsi_serdata
- topic-erased key-only serdata for use in tkmap
- restoration of including key values in invalid samples
- special handling of keyless topics
- keyhash generation via streams
- elimination of dynamically allocated buffers in keyhash
- removal of the last vestiges of "serstate"

Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-28 13:31:23 +08:00
Erik Boasson
8e20ae547e avoid declaring an array on stack with non-constant size
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-26 20:34:35 +08:00
Erik Boasson
e841e4bf94 add back in the broken filter and query condition support
the implementation was and is terrible, but without it too many tests fail

Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-26 20:05:18 +08:00
Erik Boasson
a25f683bcf abstract the internal representation of a sample
besides the old state being in dire need of cleaning up, this also paves the way for having any number of different sample representations in the system

Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-26 16:25:26 +08:00
Erik Boasson
bb92294f4e Let dds_create_participant determine domain id if config specifies "any" (new default)
Note: DDS_DOMAIN_DEFAULT with a configuration specifying "any" results in domain 0.
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-10-14 14:02:47 +08:00
Erik Boasson
e040d61246 transmit path should use unicast socket
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-09-21 11:00:43 +02:00
Erik Boasson
e84e644702 remove unused global mutex
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-09-21 11:00:43 +02:00
Erik Boasson
b3bf57de00 fix incorrect warning fix in dds_entity_observer_unregister
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-08-09 09:23:03 +02:00
Erik Boasson
b7487b18a6 stricter warning checks and the corresponding fixes
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-08-09 09:23:03 +02:00
Jeroen Koekkoek
70f208cbd3 fix export of CYCLONEDDS_URI in test environment
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-08-06 15:10:29 +02:00
Jeroen Koekkoek
3752f93e78 remove debug message for Criterion_ddsc_config_simple_udp setup
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-08-06 15:10:23 +02:00
Jeroen Koekkoek
a7bd8f05aa use test environment set by add_criterion_executable for Criterion_ddsc_config_simple_udp test
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-08-06 15:10:16 +02:00
Jeroen Koekkoek
7147eac330 add shared library directory to PATH in test environment for Criterion_ddsc_config_simple_udp
Signed-off-by: Jeroen Koekkoek <jeroen@koekkoek.nl>
2018-08-06 15:09:33 +02:00
Erik Boasson
5c0bdddc2a clean up unused variables/functions
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-08-03 11:32:08 +02:00
Erik Boasson
28c2dd2198 remove superfluous lock from dds writer
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-08-03 11:32:08 +02:00
Erik Boasson
61d98b46a6 abstract WHC and pull it out of core DDSI code
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-08-03 11:32:02 +02:00
Erik Boasson
a72a581cb0 make internal thread liveliness monitoring optional
Internal thread liveliness monitoring means having a thread that wakes up periodically, doing nothing but checking whether all seems well. In most case, this is not worth the resources and energy.

Signed-off-by: Erik Boasson <eb@ilities.com>
2018-08-01 08:57:40 +02:00
Erik Boasson
e47ad57f09 change order of cleanup steps in (internal) dds_fini to match match initialisation order
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-08-01 08:44:01 +02:00
Erik Boasson
f4824b0b5d replace temporary hack that is dds_writecdr by a better but nonetheless still temporary hack
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-07-18 17:44:54 +02:00
Erik Boasson
bfb5874373 fix crashes when C++ global destructors call DDS code
- properly count invocations of os_osInit/os_osExit
- handle concurrent invocations of those
- provide a single mutex for use by dds_init
- eliminate use of atexit()
- attendant dds_init/dds_fini changes
- fix related crash in thread local storage cleanup

Signed-off-by: Erik Boasson <eb@ilities.com>
2018-07-18 17:44:41 +02:00
Erik Boasson
ed551eecc1 eliminate support for multiple serstatepools: never used and a source of race conditions during shutdown
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-07-17 21:38:53 +02:00
Erik Boasson
520ca47938 lock observer list to avoid a race condition between attach/detach and signalling by a RHC
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-07-17 21:36:26 +02:00
Erik Boasson
24f622b114 add guard conditions
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-07-13 08:47:29 +02:00
Erik Boasson
414be4a569 General/EnableLoopback is deprecated and has no effect other than an error, remove it from configs
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-07-11 13:18:52 +02:00
Erik Boasson
e912384500 allow dds_create_topic multiple times for the same topic
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-07-11 13:18:13 +02:00
Erik Boasson
455783eed9 must copy listener argument pointer into entity to pass it in listener invocations
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-07-09 13:16:56 +02:00
Erik Boasson
0014941fad allow a forward slash in topic names for ROS2 compatibility
Signed-off-by: Erik Boasson <eb@ilities.com>
2018-07-09 13:16:56 +02:00
Erik Boasson
b13bbcc358 Remove unused DDS Security-related files
The removed files are merely the machine-readable part of the DDS Security specification; the clutter they cause in the installation directory is unwarranted, especially when installing to the default /usr/local

Signed-off-by: Erik Boasson <eb@ilities.com>
2018-07-09 13:16:56 +02:00
Erik Boasson
6095b467d3 support non-default installation directories work
Make cmake add the installation include directory to the include path so that non-default installation locations work properly

Signed-off-by: Erik Boasson <eb@ilities.com>
2018-07-09 13:16:56 +02:00