| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273 |
- syntax = "proto3";
- package cproto;
- option go_package = "./;cproto";
- // net address
- message Address {
- string ip = 1;
- int32 port = 2;
- }
- message Scope {
- int32 min = 1;
- int32 max = 2;
- }
- // support MySQL, Postgresql, redis etc.
- message StoreConf {
- string type = 1;
- string addr = 2; // host:port
- string username = 3;
- string password = 4;
- int32 timeout = 5;
- string db = 6; // to int32 if db refer a redis db.
- }
- message ClusterConf {
- repeated string addrs = 1;
- string username = 2;
- string password = 3;
- string cluster_id = 4;
- int32 timeout = 5;
- string db = 6;
- }
- message LogConf {
- string path = 1;
- string level = 2;
- int32 max_size = 3;
- int32 max_age = 4;
- int32 max_backups = 5;
- int32 compress = 6;
- }
- message MessageTemplate {
- string subject = 1;
- string body = 2;
- }
- message SmtpConf {
- int32 enabled = 1;
- string server = 2;
- int32 port = 3;
- string username = 4;
- string password = 5;
- string crypto = 6;
- repeated string to = 7;
- }
- message SmsTemplate {
- string code = 1;
- string params = 2;
- }
- message SmsConf {
- int32 enabled = 1;
- string provider = 2;
- string sign_name = 3;
- string region = 4; // needed sometimes
- string access_key = 5;
- string secret_key = 6;
- repeated string to = 7;
- }
|