Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add nodes ips infos on register #57

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions proto/src/agent.proto
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,12 @@ message Port {
int32 destination = 2;
}

// Represents node network infos
message Ips {
string clusterIp = 1;
string publicIp = 2;
}

// Represent the resource usage of a node or a workload
message ResourceSummary {
uint64 cpu = 1;
Expand All @@ -71,6 +77,11 @@ message SignalInstruction {
Signal signal = 2;
}

service NodeService {
rpc join (Ips) returns (google.protobuf.Empty) {}
rpc leave (Ips) returns (google.protobuf.Empty) {}
}

service InstanceService {
rpc create (Instance) returns (stream InstanceStatus) {}
rpc signal (SignalInstruction) returns (google.protobuf.Empty) {}
Expand Down
7 changes: 7 additions & 0 deletions proto/src/scheduler.proto
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,11 @@ message Port {
int32 destination = 2;
}

message Ips {
string clusterIp = 1;
string publicIp = 2;
}

message ResourceSummary {
uint64 cpu = 1;
uint64 memory = 2;
Expand Down Expand Up @@ -69,6 +74,7 @@ message NodeRegisterResponse {
int32 code = 1;
string description = 2;
string subnet = 3;
repeated Ips nodesIps = 4;
}

message NodeUnregisterRequest {
Expand All @@ -78,6 +84,7 @@ message NodeUnregisterRequest {
message NodeUnregisterResponse {
int32 code = 1;
string description = 2;
repeated Ips nodesIps = 3;
}

message InstanceIdentifier {
Expand Down