mirror of
https://github.com/crawlab-team/crawlab.git
synced 2026-01-25 17:42:25 +01:00
46 lines
958 B
Protocol Buffer
46 lines
958 B
Protocol Buffer
syntax = "proto3";
|
|
|
|
import "entity/response.proto";
|
|
|
|
package grpc;
|
|
option go_package = ".;grpc";
|
|
|
|
message Dependency {
|
|
string name = 1;
|
|
string version = 2;
|
|
}
|
|
|
|
message DependencyServiceConnectRequest {
|
|
string node_key = 1;
|
|
}
|
|
|
|
enum DependencyServiceCode {
|
|
SYNC = 0;
|
|
INSTALL = 1;
|
|
UNINSTALL = 2;
|
|
}
|
|
|
|
message DependencyServiceConnectResponse {
|
|
DependencyServiceCode code = 1;
|
|
string lang = 2;
|
|
string proxy = 3;
|
|
Dependency dependency = 4;
|
|
}
|
|
|
|
message DependencyServiceSyncRequest {
|
|
string node_key = 1;
|
|
string lang = 2;
|
|
repeated Dependency dependencies = 3;
|
|
}
|
|
|
|
message DependencyServiceUpdateLogsRequest {
|
|
string dependency_id = 1;
|
|
repeated string logs = 2;
|
|
}
|
|
|
|
service DependencyService {
|
|
rpc Connect(DependencyServiceConnectRequest) returns (stream DependencyServiceConnectResponse){};
|
|
rpc Sync(DependencyServiceSyncRequest) returns (Response){};
|
|
rpc UpdateLogs(stream DependencyServiceUpdateLogsRequest) returns (Response){};
|
|
}
|