From 3e5f9de632c169e77ec42755a320243eda2337f1 Mon Sep 17 00:00:00 2001 From: Nick Cao Date: Tue, 18 Mar 2025 13:33:45 -0400 Subject: [PATCH] Init ExporterService --- proto/jumpstarter/exporter/v1/exporter.proto | 58 ++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 proto/jumpstarter/exporter/v1/exporter.proto diff --git a/proto/jumpstarter/exporter/v1/exporter.proto b/proto/jumpstarter/exporter/v1/exporter.proto new file mode 100644 index 0000000..152c38b --- /dev/null +++ b/proto/jumpstarter/exporter/v1/exporter.proto @@ -0,0 +1,58 @@ +// Copyright 2024 The Jumpstarter Authors + +syntax = "proto3"; + +package jumpstarter.exporter.v1; + +service ExporterService { + rpc Register(RegisterRequest) returns (RegisterResponse); + rpc Unregister(UnregisterRequest) returns (UnregisterResponse); + rpc Listen(ListenRequest) returns (ListenResponse); + rpc Status(StatusRequest) returns (StatusResponse); + rpc AuditEvent(AuditEventRequest) returns (AuditEventResponse); +} + +message RegisterRequest { + map labels = 1; + repeated DriverInstanceReport reports = 2; +} + +message DriverInstanceReport { + string uuid = 1; // a unique id within the expoter + optional string parent_uuid = 2; // optional, if device has a parent device + map labels = 3; +} + +message RegisterResponse {} + +message UnregisterRequest { + string reason = 1; +} + +message UnregisterResponse {} + +message ListenRequest { + string lease_name = 1; +} + +message ListenResponse { + bool pending = 1; + optional string router_endpoint = 2; + optional string router_token = 3; +} + +message StatusRequest {} + +message StatusResponse { + bool leased = 1; + optional string lease_name = 2; + optional string client_name = 3; +} + +message AuditEventRequest { + string driver_instance_uuid = 1; + string severity = 2; + string message = 3; +} + +message AuditEventResponse {}