载入中...
搜索中...
未找到
CrowdWorkScheduler.h
浏览该文件的文档.
1#pragma once
2#include <functional>
3#include "common/Result.h"
4
5namespace eve::crowd {
14public:
16 virtual ~CrowdWorkScheduler() = default;
25 [[nodiscard]] virtual Result<void> execute(int partitions, const std::function<void(int)>& body) = 0;
26};
27} // namespace eve::crowd
std::string body
Move-only, checked operation results for the common layer.
Move-only operation result carrying either a value or Status.
Definition Result.h:176
Synchronous scheduler for fixed logical partitions, independent of worker identity....
virtual ~CrowdWorkScheduler()=default
Release the adapter after every synchronous dispatch has joined.
virtual Result< void > execute(int partitions, const std::function< void(int)> &body)=0
Execute each partition exactly once, joining every dispatched body on success or failure.
CrowdExecution
Explicit execution selection; serial does not require a provider.