Skip to content

Instantly share code, notes, and snippets.

@iomonad
Created November 19, 2018 14:02
Show Gist options
  • Select an option

  • Save iomonad/2bbd3667e4048082be9cf3284e919adf to your computer and use it in GitHub Desktop.

Select an option

Save iomonad/2bbd3667e4048082be9cf3284e919adf to your computer and use it in GitHub Desktop.
Protobuff contract
syntax = "proto3";
option java_multiple_files = true;
option java_package = "fr.canal.rocket.configuration.grpc";
option java_outer_classname = "IngestRulesProto";
package ingestrule;
enum TransportType {
ASPERA = 0;
FTP = 1;
SMARTJOG = 2;
SAN = 3;
}
message Transport {
TransportType type = 1;
string endPoint = 2;
string sourceDirectory = 3;
}
message IngestConfig {
string source = 1;
string pattern = 2;
string tag = 3;
bool autoContrib = 4;
int32 priority = 5;
int32 id = 6;
string createdAt = 7;
string updatedAt = 8;
}
message IngestRequest {
int32 limit = 1;
}
message IngestRuleResponse {
string source = 1;
Transport transport = 2;
repeated IngestConfig configs = 3;
bool enable = 4;
int32 pollingInterval = 5;
}
service IngestRuleService {
rpc StreamIngestRules (IngestRequest) returns (stream IngestRuleResponse) {
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment