1 #ifndef ARTDAQ_TRANSFERPLUGINS_MPITRANSFER_HH
2 #define ARTDAQ_TRANSFERPLUGINS_MPITRANSFER_HH
7 #include "artdaq-core/Data/Fragment.hh"
8 #include "artdaq/TransferPlugins/TransferInterface.hh"
62 CopyStatus copyFragment(Fragment& frag,
size_t timeout_usec = std::numeric_limits<size_t>::max())
override;
70 CopyStatus moveFragment(Fragment&& frag,
size_t timeout_usec = std::numeric_limits<size_t>::max())
override;
90 void cancelReq_(MPI_Request req)
const;
95 static std::mutex mpi_mutex_;
97 std::vector<MPI_Request> reqs_;
103 #endif //define ARTDAQ_TRANSFERPLUGINS_MPITRANSFER_HH
Role role() const
Get the TransferInterface::Role of this TransferInterface.
virtual ~MPITransfer()
MPITransfer Destructor.
CopyStatus moveFragment(Fragment &&frag, size_t timeout_usec=std::numeric_limits< size_t >::max()) override
Move a Fragment to the destination.
int receiveFragmentHeader(detail::RawFragmentHeader &header, size_t receiveTimeout) override
Receive a Fragment Header from the transport mechanism.
MPITransfer(fhicl::ParameterSet pset, Role role)
MPITransfer Constructor.
Role
Used to determine if a TransferInterface is a Sender or Receiver.
MPITransfer & operator=(const MPITransfer &)=delete
Copy Assignment operator is deleted.
CopyStatus copyFragment(Fragment &frag, size_t timeout_usec=std::numeric_limits< size_t >::max()) override
Copy a Fragment to the destination. Forces asynchronous send.
This interface defines the functions used to transfer data between artdaq applications.
MPITransfer is a TransferInterface implementation plugin that transfers data using MPI...
CopyStatus
Returned from the send functions, this enumeration describes the possible return codes. If an exception occurs, it will be thrown and should be handled normally.
int receiveFragmentData(RawDataType *destination, size_t wordCount) override
Receive the body of a Fragment to the given destination pointer.