mirror of
https://github.com/FairRootGroup/FairMQ.git
synced 2025-10-13 08:41:16 +00:00
Update DDS example to new DDS APIs
This commit is contained in:
parent
c6de904046
commit
ab985dedf8
|
@ -58,30 +58,23 @@ dds-submit --rms ssh --config ex3-dds-hosts.cfg
|
|||
```
|
||||
The `--rms` option defines a destination resource management system. The `--config` specifies an SSH plug-in resource definition file.
|
||||
|
||||
##### 6. Set the topology file.
|
||||
|
||||
Point DDS to the topology file:
|
||||
```bash
|
||||
dds-topology --set ex3-dds-topology.xml
|
||||
```
|
||||
|
||||
##### 7. Activate the topology.
|
||||
##### 6. Activate the topology.
|
||||
|
||||
```bash
|
||||
dds-topology --activate
|
||||
dds-topology --activate ex3-dds-topology.xml
|
||||
```
|
||||
|
||||
##### 8. Run
|
||||
##### 7. Run
|
||||
|
||||
After activation, agents will execute the defined tasks on the worker nodes. Output of the tasks will be stored in the directory that was specified in the hosts file.
|
||||
|
||||
##### 9. (optional) Use example command UI to check state of the devices
|
||||
##### 8. (optional) Use example command UI to check state of the devices
|
||||
|
||||
A simple utility (fairmq-dds-command-ui) is included with FairRoot to send commands to devices and receive replies from them. The utility uses the DDS intercom library to send "check-state" string to all devices, to which they reply with their ID and state they are in. The utility also allows requesting state changes from devices. To let the device listen to the commands from the utility, start the device with `--control <ddsControlPluginLibraryName>` cmd option (see example XML topology).
|
||||
|
||||
To see it in action, start the fairmq-dds-command-ui while the topology is running.
|
||||
|
||||
##### 10. Stop DDS server/topology.
|
||||
##### 9. Stop DDS server/topology.
|
||||
|
||||
The execution of tasks can be stopped with:
|
||||
```bash
|
||||
|
|
|
@ -3,21 +3,15 @@
|
|||
<property id="data1" />
|
||||
<property id="data2" />
|
||||
|
||||
<declrequirement id="SamplerWorker">
|
||||
<hostPattern type="wnname" value="sampler"/>
|
||||
</declrequirement>
|
||||
|
||||
<declrequirement id="ProcessorWorker">
|
||||
<hostPattern type="wnname" value="processor"/>
|
||||
</declrequirement>
|
||||
|
||||
<declrequirement id="SinkWorker">
|
||||
<hostPattern type="wnname" value="sink"/>
|
||||
</declrequirement>
|
||||
<declrequirement id="SamplerWorker" type="wnname" value="sampler"/>
|
||||
<declrequirement id="ProcessorWorker" type="wnname" value="processor"/>
|
||||
<declrequirement id="SinkWorker" type="wnname" value="sink"/>
|
||||
|
||||
<decltask id="Sampler">
|
||||
<exe reachable="true">@CMAKE_BINARY_DIR@/bin/examples/MQ/3-dds/ex3-sampler --id sampler --log-color false --control libFairMQDDSControlPlugin.so --config libFairMQDDSConfigPlugin.so --mq-config @CMAKE_BINARY_DIR@/bin/config/ex3-dds.json</exe>
|
||||
<requirement>SamplerWorker</requirement>
|
||||
<requirements>
|
||||
<id>SamplerWorker</id>
|
||||
</requirements>
|
||||
<properties>
|
||||
<id access="write">data1</id>
|
||||
</properties>
|
||||
|
@ -25,7 +19,9 @@
|
|||
|
||||
<decltask id="Processor">
|
||||
<exe reachable="true">@CMAKE_BINARY_DIR@/bin/examples/MQ/3-dds/ex3-processor --id processor_%taskIndex% --config-key processor --log-color false --control libFairMQDDSControlPlugin.so --config libFairMQDDSConfigPlugin.so --mq-config @CMAKE_BINARY_DIR@/bin/config/ex3-dds.json</exe>
|
||||
<requirement>ProcessorWorker</requirement>
|
||||
<requirements>
|
||||
<id>ProcessorWorker</id>
|
||||
</requirements>
|
||||
<properties>
|
||||
<id access="read">data1</id>
|
||||
<id access="read">data2</id>
|
||||
|
@ -34,7 +30,9 @@
|
|||
|
||||
<decltask id="Sink">
|
||||
<exe reachable="true">@CMAKE_BINARY_DIR@/bin/examples/MQ/3-dds/ex3-sink --id sink --log-color false --control libFairMQDDSControlPlugin.so --config libFairMQDDSConfigPlugin.so --mq-config @CMAKE_BINARY_DIR@/bin/config/ex3-dds.json</exe>
|
||||
<requirement>SinkWorker</requirement>
|
||||
<requirements>
|
||||
<id>SinkWorker</id>
|
||||
</requirements>
|
||||
<properties>
|
||||
<id access="write">data2</id>
|
||||
</properties>
|
||||
|
|
Loading…
Reference in New Issue
Block a user