Skip to content

EntropyEngine::Core::Concurrency::GraphExecutionCompletedEvent

EntropyEngine::Core::Concurrency::GraphExecutionCompletedEvent

Section titled “EntropyEngine::Core::Concurrency::GraphExecutionCompletedEvent”

The finish line - all nodes have reached terminal states. More…

#include <WorkGraphEvents.h>

Inherits from EntropyEngine::Core::Concurrency::WorkGraphEvent

Name
GraphExecutionCompletedEvent(const WorkGraph * g, const WorkGraphStats::Snapshot & s)
Name
WorkGraphStats::Snapshotstats
Final statistics for the run.

Public Functions inherited from EntropyEngine::Core::Concurrency::WorkGraphEvent

Name
WorkGraphEvent(const WorkGraph * g)

Public Attributes inherited from EntropyEngine::Core::Concurrency::WorkGraphEvent

Name
std::chrono::steady_clock::time_pointtimestamp
When this event was created.
const WorkGraph *graph
Which graph emitted this event.
struct EntropyEngine::Core::Concurrency::GraphExecutionCompletedEvent;

The finish line - all nodes have reached terminal states.

This fires when the entire graph is done, whether successfully or not. The stats snapshot gives you the complete picture: successes, failures, cancellations, and performance metrics. This is your post-mortem data.

eventBus->subscribe<GraphExecutionCompletedEvent>([](const auto& event) {
const auto& stats = event.stats;
LOG_INFO("Workflow complete: {} succeeded, {} failed, {} cancelled",
stats.completedNodes, stats.failedNodes, stats.cancelledNodes);
auto seconds = std::chrono::duration_cast<std::chrono::seconds>(
stats.totalExecutionTime).count();
LOG_INFO("Total execution time: {}s", seconds);
if (stats.failedNodes > 0) {
LOG_ERROR("Workflow had failures!");
}
});
inline GraphExecutionCompletedEvent(
const WorkGraph * g,
const WorkGraphStats::Snapshot & s
)
WorkGraphStats::Snapshot stats;

Final statistics for the run.


Updated on 2026-01-26 at 17:14:35 -0500