Skip to content

Distinguish between Local and Remote Execution#140

Merged
raphael-goetz merged 26 commits intomainfrom
#96-distinguish-local-remote-execution
Apr 5, 2026
Merged

Distinguish between Local and Remote Execution#140
raphael-goetz merged 26 commits intomainfrom
#96-distinguish-local-remote-execution

Conversation

@raphael-goetz
Copy link
Copy Markdown
Member

Resolves: #96

Copilot AI review requested due to automatic review settings April 5, 2026 14:59
raphael-goetz and others added 2 commits April 5, 2026 17:02
Signed-off-by: Raphael Götz <52959657+raphael-goetz@users.noreply.github.com>
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR introduces a mechanism for distinguishing locally executed runtime functions from remotely executed “action” definitions, enabling Taurus to dispatch certain nodes via a remote runtime (NATS) instead of the in-process function registry.

Changes:

  • Add definition_source to flow node definitions and treat non-"taurus" nodes as remote-executed.
  • Extend Executor with optional RemoteRuntime support and implement NATS-based remote execution in Taurus (plus a manual CLI for running a single flow via NATS).
  • Extract shared test-case structures/loading into a new tests-core crate and update the tests runner accordingly.

Reviewed changes

Copilot reviewed 17 out of 19 changed files in this pull request and generated 11 comments.

Show a summary per file
File Description
flows/01_return_object.json Adds definition_source to mark nodes as Taurus-local.
flows/02_return_flow_input.json Adds definition_source to mark nodes as Taurus-local.
flows/03_for_each.json Adds definition_source to mark nodes as Taurus-local.
flows/04_example_action.json Adds a new example flow intended to exercise remote/action execution.
crates/core/src/context/executor.rs Adds remote dispatch path (RemoteRuntime) and remote request building/arg resolution.
crates/core/src/runtime/mod.rs Exposes new runtime::remote module.
crates/core/src/runtime/remote/mod.rs Introduces RemoteRuntime trait for remote execution backends.
crates/core/Cargo.toml Adds async/uuid dependencies needed by remote execution path.
crates/taurus/src/remote/mod.rs Implements a NATS-backed RemoteRuntime client for Taurus.
crates/taurus/src/main.rs Wires remote runtime into Executor when handling flows.
crates/manual/src/main.rs Adds a CLI for manually executing a single flow with optional remote runtime.
crates/manual/Cargo.toml Adds dependencies for the manual CLI crate.
crates/tests-core/src/lib.rs New shared crate for loading/printing test cases.
crates/tests-core/Cargo.toml Declares dependencies for the new tests-core crate.
crates/tests/src/main.rs Uses tests-core for case loading/printing; keeps execution logic in runner.
crates/tests/Cargo.toml Adds tests-core dependency.
Cargo.toml Adds new workspace members and updates shared dependency set.
Cargo.lock Updates lockfile for new crates/dependencies.
.gitignore Ignores generated/checked-out definitions directories.
Comments suppressed due to low confidence (1)

crates/core/src/context/executor.rs:245

  • FunctionNotFound returns (Signal::Failure(..), 0) without creating a trace frame. If this happens in a thunked/eager child call, the parent will link child_root = 0 and render_trace() will panic (it expects every linked child id to exist). Consider entering a frame before the registry lookup and exiting it with a failure outcome so callers always get a valid frame id.
        let entry = match self.functions.get(node.runtime_function_id.as_str()) {
            Some(e) => e,
            None => {
                let err = RuntimeError::simple(
                    "FunctionNotFound",
                    format!("Function {} not found", node.runtime_function_id),
                );
                return (Signal::Failure(err), 0);
            }

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

raphael-goetz and others added 6 commits April 5, 2026 17:06
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Raphael Götz <52959657+raphael-goetz@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Raphael Götz <52959657+raphael-goetz@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Raphael Götz <52959657+raphael-goetz@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Raphael Götz <52959657+raphael-goetz@users.noreply.github.com>
@raphael-goetz raphael-goetz merged commit 48b54a2 into main Apr 5, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Distinguish between Local and Action Definitions

2 participants