crawler_go/grpc/grpc.proto
snoop 46529a530f changed
parameter
2017-04-27 19:42:46 +09:00

83 lines
1.4 KiB
Protocol Buffer

syntax = "proto3";
enum Crawlers {
HEALTH_ACTIVEDIRECTORY = 0;
HEALTH_DNS = 1;
HEALTH_FTP = 2;
HEALTH_FTPS = 3;
HEALTH_IMAP = 4;
HEALTH_LDAP = 5;
HEALTH_MONGODB = 6;
HEALTH_MSSQL = 7;
HEALTH_MYSQL = 8;
HEALTH_MARIADB = 9;
HEALTH_PGSQL = 10;
HEALTH_NETBIOS = 11;
HEALTH_ORACLE = 12;
HEALTH_POP3 = 13;
HEALTH_REDIS = 14;
HEALTH_RMI = 15;
HEALTH_SMB = 16;
HEALTH_SMTP = 17;
HEALTH_SNMPV2C = 18;
HEALTH_SNMPV3 = 19;
HEALTH_SSH = 20;
HEALTH_TELNET = 21;
HEALTH_WMI = 22;
HEALTH_CASSANDRA = 23;
HEALTH_HTTP = 24;
SQL = 25;
SNMP = 26;
WMI = 27;
JMX = 28;
REDIS = 29;
MONGODB = 30;
}
// services
service Config {
rpc Add (InputAdd) returns (Output) {}
rpc Remove (Input) returns (Output) {}
rpc Init (InputArray) returns (Output) {}
}
service Data {
rpc Get (Input) returns (Output) {}
}
service Status {
rpc Status(Empty) returns (Boolean) {}
}
message Empty {}
message Boolean {
bool check = 1;
}
message InputArray {
repeated Init in = 1;
}
message Init {
Crawlers name = 1;
bytes data = 2;
}
message Input {
Crawlers name = 1;
string id =2;
}
message InputAdd {
Crawlers name = 1;
bytes data =2;
}
// response models
message Output {
int64 startDate = 1;
int64 endDate = 2;
bytes data = 3;
}