Clone proto and substreams from tycho-indexer
This commit is contained in:
142
proto/sf/substreams/sink/service/v1/service.proto
Normal file
142
proto/sf/substreams/sink/service/v1/service.proto
Normal file
@@ -0,0 +1,142 @@
|
||||
syntax = "proto3";
|
||||
|
||||
package sf.substreams.sink.service.v1;
|
||||
|
||||
import "sf/substreams/v1/package.proto";
|
||||
|
||||
option go_package = "github.com/streamingfast/substreams/pb/sf/substreams/sink/service/v1;pbsinksvc";
|
||||
|
||||
service Provider {
|
||||
rpc Deploy(DeployRequest) returns (DeployResponse);
|
||||
rpc Update(UpdateRequest) returns (UpdateResponse);
|
||||
rpc Info(InfoRequest) returns (InfoResponse);
|
||||
rpc List(ListRequest) returns (ListResponse);
|
||||
rpc Pause(PauseRequest) returns (PauseResponse);
|
||||
rpc Stop(StopRequest) returns (StopResponse);
|
||||
rpc Resume(ResumeRequest) returns (ResumeResponse);
|
||||
rpc Remove(RemoveRequest) returns (RemoveResponse);
|
||||
}
|
||||
|
||||
message DeployRequest {
|
||||
sf.substreams.v1.Package substreams_package = 1;
|
||||
|
||||
bool development_mode = 2;
|
||||
repeated Parameter parameters = 3;
|
||||
}
|
||||
|
||||
message Parameter {
|
||||
string key = 1;
|
||||
string value = 2;
|
||||
}
|
||||
|
||||
message DeployResponse {
|
||||
DeploymentStatus status = 1;
|
||||
|
||||
// deployment_id is a short name (max 8 characters) that uniquely identifies your deployment
|
||||
string deployment_id = 2;
|
||||
|
||||
map<string, string> services = 3;
|
||||
string reason = 4;
|
||||
string motd = 5;
|
||||
}
|
||||
|
||||
message UpdateRequest {
|
||||
sf.substreams.v1.Package substreams_package = 1;
|
||||
string deployment_id = 2;
|
||||
bool reset = 3;
|
||||
}
|
||||
|
||||
message UpdateResponse {
|
||||
DeploymentStatus status = 1;
|
||||
map<string, string> services = 2;
|
||||
string reason = 3;
|
||||
string motd = 4;
|
||||
}
|
||||
|
||||
message InfoRequest {
|
||||
string deployment_id = 1;
|
||||
}
|
||||
|
||||
message InfoResponse {
|
||||
DeploymentStatus status = 1;
|
||||
map<string, string> services = 2;
|
||||
string reason = 3;
|
||||
PackageInfo package_info = 4;
|
||||
SinkProgress progress = 5;
|
||||
string motd = 6;
|
||||
}
|
||||
|
||||
message SinkProgress {
|
||||
uint64 last_processed_block = 1;
|
||||
}
|
||||
|
||||
message PackageInfo {
|
||||
string name = 1;
|
||||
string version = 2;
|
||||
string output_module_name = 3;
|
||||
string output_module_hash = 4;
|
||||
}
|
||||
|
||||
message ListRequest {}
|
||||
|
||||
message ListResponse {
|
||||
repeated DeploymentWithStatus deployments = 1;
|
||||
}
|
||||
|
||||
message DeploymentWithStatus {
|
||||
string id = 1;
|
||||
DeploymentStatus status = 2;
|
||||
string reason = 3;
|
||||
PackageInfo package_info = 4;
|
||||
SinkProgress progress = 5;
|
||||
string motd = 6;
|
||||
}
|
||||
|
||||
enum DeploymentStatus {
|
||||
UNKNOWN = 0;
|
||||
RUNNING = 1;
|
||||
FAILING = 2;
|
||||
PAUSED = 3;
|
||||
STOPPED = 4;
|
||||
|
||||
STARTING = 5;
|
||||
PAUSING = 6;
|
||||
STOPPING = 7;
|
||||
REMOVING = 8;
|
||||
RESUMING = 9;
|
||||
}
|
||||
|
||||
message RemoveRequest {
|
||||
string deployment_id = 1;
|
||||
}
|
||||
|
||||
message RemoveResponse {
|
||||
DeploymentStatus previous_status = 1;
|
||||
}
|
||||
|
||||
message PauseRequest {
|
||||
string deployment_id = 1;
|
||||
}
|
||||
|
||||
message PauseResponse {
|
||||
DeploymentStatus previous_status = 1;
|
||||
DeploymentStatus new_status = 2;
|
||||
}
|
||||
|
||||
message StopRequest {
|
||||
string deployment_id = 1;
|
||||
}
|
||||
|
||||
message StopResponse {
|
||||
DeploymentStatus previous_status = 1;
|
||||
DeploymentStatus new_status = 2;
|
||||
}
|
||||
|
||||
message ResumeRequest {
|
||||
string deployment_id = 1;
|
||||
}
|
||||
|
||||
message ResumeResponse {
|
||||
DeploymentStatus previous_status = 1;
|
||||
DeploymentStatus new_status = 2;
|
||||
}
|
||||
Reference in New Issue
Block a user