-
Notifications
You must be signed in to change notification settings - Fork 1
/
Component.proto
49 lines (36 loc) · 1.14 KB
/
Component.proto
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
syntax = "proto3";
import "Shared.proto";
package Scynet;
option csharp_namespace = "Scynet";
/**
* The Api which is implemented by the different components.
* It is caled by the hatchery to instantiate the agents.
*/
service Component {
// Register a new input to the component
rpc RegisterInput (RegisterInputRequest) returns (Void) {};
// Start running a particular agent
rpc AgentStart (AgentStartRequest) returns (Void) {};
// Stop that agent
rpc AgentStop (AgentRequest) returns (Void) {};
// Check the status of an agent.
rpc AgentStatus (AgentRequest) returns (AgentStatusResponse) {}; // Can raise an Agent Not Found Exception
// Retrieve a list of running agents.
rpc AgentList (AgentQuery) returns (ListOfAgents) {};
}
message RegisterInputRequest {
Agent input = 2;
}
message AgentStartRequest {
Agent egg = 2; // The egg that will be used only when creating the agent. It contains the uuid of the agent
}
// Used for different filters that can be applied to the query.
message AgentQuery {
}
// The list of avalable agents.
message ListOfAgents {
repeated Agent agents = 1;
}
message AgentStatusResponse {
bool running = 1;
}