7 #include <condition_variable>
13 #include <ucxx/future.h>
14 #include <ucxx/notifier.h>
28 std::mutex _notifierThreadMutex{};
29 std::vector<std::pair<std::shared_ptr<::ucxx::Future>, ucs_status_t>>
30 _notifierThreadFutureStatus{};
31 bool _notifierThreadFutureStatusReady{
false};
33 RequestNotifierThreadState::NotRunning};
34 std::condition_variable
35 _notifierThreadConditionVariable{};
Notifier for status of futures.
Definition: notifier.h:38
Specialized Python implementation of a ucxx::Notifier.
Definition: notifier.h:26
bool isRunning() const override
Returns whether the thread is running.
RequestNotifierWaitState waitRequestNotifier(uint64_t period) override
Wait for a new event with a timeout in nanoseconds.
void stopRequestNotifierThread() override
Make known to the notifier thread that it should stop.
void runRequestNotifier() override
Notify event loop of all pending completed Python futures.
virtual ~Notifier()
Virtual destructor.
friend std::shared_ptr<::ucxx::Notifier > createNotifier()
Constructor of shared_ptr<ucxx::python::Notifier>.
void scheduleFutureNotify(std::shared_ptr<::ucxx::Future > future, ucs_status_t status) override
Schedule event loop notification of completed Python future.
RequestNotifierWaitState
The state with which a wait operation completed.
Definition: notifier.h:26
RequestNotifierThreadState
The state of the notifier thread.
Definition: notifier.h:19