Project
Loading...
Searching...
No Matches
DataSender.h
Go to the documentation of this file.
1
// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2
// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3
// All rights not expressly granted are reserved.
4
//
5
// This software is distributed under the terms of the GNU General Public
6
// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7
//
8
// In applying this license CERN does not waive the privileges and immunities
9
// granted to it by virtue of its status as an Intergovernmental Organization
10
// or submit itself to any jurisdiction.
11
#ifndef O2_FRAMEWORK_DATASENDER_H_
12
#define O2_FRAMEWORK_DATASENDER_H_
13
14
#include "
Framework/RoutingIndices.h
"
15
#include "
Framework/FairMQDeviceProxy.h
"
16
#include "
Framework/ServiceRegistryRef.h
"
17
#include "
Framework/Tracing.h
"
18
#include "
Framework/OutputSpec.h
"
19
#include <fairmq/Message.h>
20
#include <fairmq/Parts.h>
21
#include <string>
22
23
#include <cstddef>
24
#include <mutex>
25
26
namespace
o2::framework
27
{
28
29
struct
ServiceRegistry;
30
struct
DeviceSpec;
31
33
class
DataSender
34
{
35
public
:
36
DataSender
(
ServiceRegistryRef
registry);
37
void
send
(fair::mq::Parts&,
ChannelIndex
index
);
38
std::unique_ptr<fair::mq::Message>
create
(
RouteIndex
index
);
43
void
reset
();
48
void
verifyMissingSporadic
()
const
;
49
50
private
:
51
FairMQDeviceProxy
& mProxy;
52
// We need the ServiceRegistry and not a ref, to be able
53
// to call the callbacks after sending.
54
ServiceRegistryRef
mRegistry;
55
DeviceSpec
const
& mSpec;
56
std::vector<OutputSpec> mOutputs;
57
std::vector<size_t> mDistinctRoutesIndex;
58
59
std::vector<std::string> mMetricsNames;
60
std::vector<std::string> mVariablesMetricsNames;
61
std::vector<bool> mPresent;
62
std::vector<bool> mPresentDefaults;
63
64
O2_LOCKABLE_NAMED
(std::recursive_mutex, mMutex,
"data relayer mutex"
);
65
};
66
67
}
// namespace o2::framework
68
69
#endif
// O2_FRAMEWORK_DATASENDER_H_
FairMQDeviceProxy.h
OutputSpec.h
RoutingIndices.h
ServiceRegistryRef.h
Tracing.h
O2_LOCKABLE_NAMED
#define O2_LOCKABLE_NAMED(T, V, N)
Definition
Tracing.h:19
o2::framework::DataSender
Allow injecting policies on send.
Definition
DataSender.h:34
o2::framework::DataSender::create
std::unique_ptr< fair::mq::Message > create(RouteIndex index)
Definition
DataSender.cxx:95
o2::framework::DataSender::verifyMissingSporadic
void verifyMissingSporadic() const
Definition
DataSender.cxx:118
o2::framework::DataSender::send
void send(fair::mq::Parts &, ChannelIndex index)
Definition
DataSender.cxx:101
o2::framework::DataSender::reset
void reset()
Definition
DataSender.cxx:113
o2::framework::FairMQDeviceProxy
Definition
FairMQDeviceProxy.h:36
o2::framework::ServiceRegistryRef
Definition
ServiceRegistryRef.h:21
index
GLuint index
Definition
glcorearb.h:781
o2::framework
Defining PrimaryVertex explicitly as messageable.
Definition
TFIDInfo.h:20
o2::framework::ChannelIndex
Definition
RoutingIndices.h:30
o2::framework::DeviceSpec
Definition
DeviceSpec.h:48
o2::framework::RouteIndex
Definition
RoutingIndices.h:22
Framework
Core
include
Framework
DataSender.h
Generated on Tue Feb 25 2025 23:16:38 for Project by
1.9.8