112 lines
3.6 KiB
Protocol Buffer
112 lines
3.6 KiB
Protocol Buffer
syntax = "proto3";
|
|
|
|
package quixos.orch;
|
|
|
|
import "camino/api.proto";
|
|
import "quixos/package.proto";
|
|
import "quixos/refs.proto";
|
|
import "quixos/runtime.proto";
|
|
|
|
service OrchestratorRuntime {
|
|
rpc InvokeCapability(InvokeCapabilityRequest) returns (InvokeCapabilityResponse);
|
|
rpc WatchCapability(WatchCapabilityRequest) returns (stream WatchCapabilityEvent);
|
|
rpc ConstructObject(ConstructObjectRequest) returns (ConstructObjectResponse);
|
|
rpc ResolveOrConstructRelatedObject(ResolveOrConstructRelatedObjectRequest) returns (ResolveOrConstructRelatedObjectResponse);
|
|
rpc GetWorkspace(GetWorkspaceRequest) returns (GetWorkspaceResponse);
|
|
rpc ListPackageDescriptors(ListPackageDescriptorsRequest) returns (ListPackageDescriptorsResponse);
|
|
rpc ListPackageRuntimes(ListPackageRuntimesRequest) returns (ListPackageRuntimesResponse);
|
|
rpc ListActivations(ListActivationsRequest) returns (ListActivationsResponse);
|
|
rpc CloseActivation(CloseActivationRequest) returns (CloseActivationResponse);
|
|
}
|
|
|
|
message ConstructObjectRequest {
|
|
string atom_id = 1;
|
|
map<string, camino.Value> input = 2;
|
|
}
|
|
message ConstructObjectResponse { camino.CaminoObject object = 1; }
|
|
|
|
message ResolveOrConstructRelatedObjectRequest {
|
|
string object_id = 1;
|
|
string interface_revision_id = 2;
|
|
string member_id = 3;
|
|
}
|
|
message ResolveOrConstructRelatedObjectResponse {
|
|
camino.CaminoObject object = 1;
|
|
bool constructed = 2;
|
|
}
|
|
|
|
message InvokeCapabilityRequest {
|
|
quixos.CapabilityRef capability = 1;
|
|
string object_id = 2;
|
|
map<string, camino.Value> input = 3;
|
|
// Identifies one logical client mutation across the capability and Camino
|
|
// layers so a live-value controller can recognize its own confirmation.
|
|
string client_mutation_id = 4;
|
|
}
|
|
message InvokeCapabilityResponse {
|
|
string invocation_id = 1;
|
|
Activation activation = 2;
|
|
bool ok = 3;
|
|
camino.Value result = 4;
|
|
string error = 5;
|
|
repeated quixos.runtime.DerivedDependency dependencies = 6;
|
|
}
|
|
|
|
message WatchCapabilityRequest {
|
|
quixos.CapabilityRef capability = 1;
|
|
string object_id = 2;
|
|
map<string, camino.Value> input = 3;
|
|
}
|
|
message WatchCapabilityEvent {
|
|
string invocation_id = 1;
|
|
Activation activation = 2;
|
|
string watch_id = 3;
|
|
camino.Value value = 4;
|
|
repeated quixos.runtime.DerivedDependency dependencies = 5;
|
|
string error = 6;
|
|
bool initial = 7;
|
|
}
|
|
|
|
message GetWorkspaceRequest {}
|
|
message GetWorkspaceResponse {
|
|
string workspace_id = 1;
|
|
string workspace_revision_id = 2;
|
|
string source_root_commit = 3;
|
|
}
|
|
message ListActivationsRequest {}
|
|
message ListPackageDescriptorsRequest {}
|
|
message ListPackageDescriptorsResponse { repeated quixos.PackageDescriptor descriptors = 1; }
|
|
message ListPackageRuntimesRequest {}
|
|
message ListPackageRuntimesResponse { repeated PackageRuntimeStatus runtimes = 1; }
|
|
message ListActivationsResponse { repeated Activation activations = 1; }
|
|
message CloseActivationRequest { string activation_id = 1; string reason = 2; }
|
|
message CloseActivationResponse { Activation activation = 1; }
|
|
|
|
message Activation {
|
|
string activation_id = 1;
|
|
quixos.PackageExportRef export = 2;
|
|
string object_id = 3;
|
|
string state = 4;
|
|
uint32 demand = 5;
|
|
string opened_at = 6;
|
|
string last_used_at = 7;
|
|
string idle_deadline_at = 8;
|
|
string closed_at = 9;
|
|
string close_reason = 10;
|
|
}
|
|
|
|
message PackageRuntimeStatus {
|
|
string runtime_key = 1;
|
|
string package_revision_id = 2;
|
|
string source_repository = 3;
|
|
string source_commit = 4;
|
|
string build_target = 5;
|
|
string server_path = 6;
|
|
uint32 pid = 7;
|
|
string state = 8;
|
|
string started_at = 9;
|
|
string last_handshake_at = 10;
|
|
string runtime_protocol_version = 11;
|
|
uint32 advertised_export_count = 12;
|
|
}
|