summaryrefslogtreecommitdiffstats
path: root/aclk/aclk-schemas/proto/agent/v1/connection.proto
diff options
context:
space:
mode:
Diffstat (limited to 'aclk/aclk-schemas/proto/agent/v1/connection.proto')
-rw-r--r--aclk/aclk-schemas/proto/agent/v1/connection.proto59
1 files changed, 59 insertions, 0 deletions
diff --git a/aclk/aclk-schemas/proto/agent/v1/connection.proto b/aclk/aclk-schemas/proto/agent/v1/connection.proto
new file mode 100644
index 00000000..4321b0b9
--- /dev/null
+++ b/aclk/aclk-schemas/proto/agent/v1/connection.proto
@@ -0,0 +1,59 @@
+syntax = "proto3";
+option go_package = "agent/v1;agent";
+
+package agent.v1;
+
+import "google/protobuf/timestamp.proto";
+import "google/protobuf/duration.proto";
+import "proto/aclk/v1/lib.proto";
+
+message UpdateAgentConnection {
+ string claim_id = 1;
+ bool reachable = 2;
+
+ int64 session_id = 3;
+
+ ConnectionUpdateSource update_source = 4;
+
+ // mqtt_broker_addr shard to use for reaching the agent
+ // cloud injects this information
+ string mqtt_broker_addr = 5;
+
+ google.protobuf.Timestamp updated_at = 6;
+
+ // vmq_instance_id broker shard to use for reaching the agent
+ // cloud injects this information
+ int32 vmq_instance_id = 7;
+
+ // > 15 optional fields:
+ // How long the system was running until connection (only applicable when reachable=true)
+ google.protobuf.Duration system_uptime = 15;
+
+ // How long the netdata agent was running until connection (only applicable when reachable=true)
+ google.protobuf.Duration agent_uptime = 16;
+
+ repeated aclk_lib.v1.Capability capabilities = 17;
+}
+
+message SendNodeInstances {
+ string claim_id = 1;
+ Config config = 2;
+}
+
+// ConnectionUpdateSource is to determine whether the connection update was issued
+enum ConnectionUpdateSource {
+ // CONNECTION_UPDATE_SOURCE_UNSPECIFIED acts as default value for protobuf and is never specified
+ CONNECTION_UPDATE_SOURCE_UNSPECIFIED = 0;
+ // CONNECTION_UPDATE_SOURCE_AGENT A direct message from an agent
+ CONNECTION_UPDATE_SOURCE_AGENT = 1;
+ // CONNECTION_UPDATE_SOURCE_LWT message delivered as the Last Will and Testiment from MQTT broker if an agent connection with the broker is lost
+ CONNECTION_UPDATE_SOURCE_LWT = 2;
+ // CONNECTION_UPDATE_SOURCE_HEURISTIC A cloud generated message to sanitize incorrect internal state
+ CONNECTION_UPDATE_SOURCE_HEURISTIC = 3;
+}
+
+message Config {
+ bool bearer_protection = 1;
+ bool cloud_only_notifications = 2;
+ bool universal_dashboards = 3;
+}