Commit Graph

31 Commits

Author SHA1 Message Date
Alexey Rybalchenko
31cba0515e try full output for tests 2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
2c2fc8e0a6 convert log severities use to lowercase and remove use of MQLOG 2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
500d509324 Single Logger implementation for FairLogger & FairMQLogger 2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
21fc10d3de Disable irrelevant output in tests to workaround output scrambling on MacOS 10.11 2018-05-02 16:12:57 +02:00
Mohammad Al-Turany
22e2e90de3 correct typo in copyright section 2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
661e469aa8 FairMQ: Add uuid generator to tools & let tests use it for session names. 2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
c9fc46e2c9 FairMQ: Add test for example/advanced/Region.
Also fix a regression in nanomsg transport.
2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
319bdc91a1 Tests for MQ examples 2018-05-02 16:12:57 +02:00
Dennis Klein
3e013f98b8 refactor and integrate with aliBuild/alienv
* accept ZEROMQ_ROOT as env or cmake variable to hint at install
    location (used by aliBuild/alienv)
  * added more docs
  * fixed mismatch between module name ZeroMQ and prefix of
    generated variables ZMQ -> ZeroMQ is now the preferred prefix
    (old variables are still available and marked deprecated)
  * the aliBuild zeromq recipe does not install zmq.hpp header,
    so the module searches now for the zmq.h header
    (which is anyways the only one we use)
  * some cosmetic changes
  * add option ZeroMQ_NO_DEPRECATION to suppress deprecation warning
2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
8defd77b63 Adding multiple transports support & other fixes:
- Avoid polling when only one input channel is used.
 - Send only handles for shared memory transport.
 - Avoid waiting in the rate logger thread when nothing to log.
 - Hide warnings from generated files
 - Fix #483
2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
e255372043 Convert factory methods to return smart ptrs
- Convert factory methods to return smart ptrs.
 - Refactor state machine to use same thread for user states.
 - Remove unused includes and dependencies, use std.
2018-05-02 16:12:57 +02:00
mkrzewic
c86bfd97a8 Update MQ example 8 to use multiple endpoints 2018-05-02 16:12:57 +02:00
Sebastien Binet
e241ea41bb all: apply fer-json-fmt 2018-05-02 16:12:57 +02:00
Sebastien Binet
6e8839e955 all: use strict(er) and more regular JSON schema 2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
72eb775983 Update JSON files & readme, use FairMQDevicePtr, cleanup. 2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
da10c64800 Enable new callback API
- OnData() channel data handler.
 - ConditionalRun() for devices without incoming data.
 - Header file with common main(), to be extended with getDevice/addCustomOptions.
 - Update examples (MQ/Tutorial3) to use the new API and config.
 - NewSimpleMessage() for simpler creation of small messages (additional copy).
 - Replace SetProperty/GetProperty with fConfig access.
 - Runtime configurable channel names for common devices.
 - Configurable logging interval per channel.
 - FairMQMultiplier for distributing same data to multiple outputs.
 - Cleanup state machine messages.
 - Cmd option to toggle signal handling.
 - Simpler API for send/receive timeouts.
 - Enable --log-to-file.
 - Fix coverity issues, warnings.
 - Various code cleanup and minor tweaks.
2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
d5b98567db Fix unused variables, init order and effc++ warnings. 2018-05-02 16:12:57 +02:00
Radoslaw Karabowicz
ac9475c591 Modified the ROOTMacros.cmake to allow GENERATE_EXECUTABLE()
to install executables in directory set by BIN_DESTINATION (or in bin/ if not set).

Changed the location of the executables:
- from build/bin/ to build/bin/examples/example-name/
- from install/bin/ to install/examples/example-name/bin/
2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
f7200cf4bd Let ParseAll exit if unsuccessfull 2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
622a11a32d Cleanup examples 2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
edcc7a4ee3 Cleanup example include directories 2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
13453354c8 Configuration and DDS example/tools updates
- Update DDS example command UI and extract it from example.
 - Unify address handling via DDS properties for dynamic deployment.
 - Update DDS docs with the new approach.
 - Allow `--config-key` to be used to access common config in JSON.
 - Allow common channel properties to be specified for all sockets.
 - Update MQ examples and Tuto3 with new config options.
 - Add start scripts to MQ examples for easier use.
2018-05-02 16:12:57 +02:00
winckler
07aed04b14 add deleter in FairMQ example 8 2018-05-02 16:12:57 +02:00
winckler
dcb791694a change serialization API so that it takes a FairMQMessage reference 2018-05-02 16:12:57 +02:00
winckler
5f365c84c7 add serialization API 2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
830ba948f0 Install config files for MQ examples 2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
6ab3b0ebc0 Update multi-part features (nanomsg) and various fixes
- Implement nanomsg multipart with MessagePack.
 - Use the MessagePack from FairSoft and handle not found case.
 - Update splitter, merger and proxy devices to handle multi-part.
 - Let FairMQParts.At() return pointer reference (can be used for moving).
 - Add missing const specifier in the message interface.
 - Add transmit kernel size setting to channels (ZMQ_SNDBUF).
 - Remove FairMQBuffer device.
 - Remove old multi-part methods from Tutorial3 example (to be replaced with Parts API).
 - Make callback mandatory for newMsg(data, size, callback).
 - Add missing <vector> include in FairMQSocket.
2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
bbadf09aad FairMQ: Extend Multipart and messaging API
- Extend the multipart API to allow sending vectors of messages or helper
   thin wrapper FairMQParts. See example in examples/MQ/8-multipart.
 - NewMessage() can be used in devices instead of
   fTransportFactory->CreateMessage().
   Possible arguments remain unchanged (no args, size or data+size).
 - Send()/Receive() methods can be used in devices instead of
   fChannels.at("chan").at(i).Send()/Receive():
   Send(msg, "chan", i = 0), Receive(msg, "chan", i = 0).
 - Use the new methods in MQ examples and tests.
 - No breaking changes, but FAIRMQ_INTERFACE_VERSION is incremented to 3
   to allow to check for new methods.
2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
1bb72fea38 Add FlatBuffers & MessagePack examples
- Add FlatBuffers serialization example to Tutorial 3
 - Add MessagePack serialization example to Tutorial 3
 - Performance improvements in Boost serialization example
 - Use `GetEntriesFast()` for FairTestDetectorRecoTask
 - Use `Clear()` instead of `Delete()` in MQ parts of Tutorial 3
 - Fix CMake variables from preventing compilation without nanomsg.
 - create macro/data directories in install directory
 - Get rid of data duplication in fill_parameters.C
 - Various cleanups and fixes
2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
7ab6afa28a Remove compile time transport interface switch
- Remove the compile time check of the transport implementation.
  The transport (zeromq/nanomsg) can be chosen at run time with:
  `device.SetTransport("zeromq"); // possible values are "zeromq" and "nanomsg"`.

  For devices that use FairMQProgOptions, the transport can be configured via cmd option:
  `--transport zeromq` or `--transport nanomsg`. Default values is "zeromq".
  The device receives the configured value with:
  `device.SetTransport(config.GetValue<std::string>("transport"));`

  Old method of setting transport still works. But the NANOMSG constant is not defined.

- Remove old `fairmq/prototest` directory. It was only used as a test for protobuf.
  The protobuf part of Tutorial3 does the same (with different values).

- Fix a bug in FairMQPollerNN, where the `revents` value was not initialized.
  This caused the `poller->CheckOutput()` to trigger when it should not.
2018-05-02 16:12:57 +02:00
Alexey Rybalchenko
f0a878a43a Rename /example to /examples and move MQ examples in it 2018-05-02 16:12:57 +02:00