Compare commits

...

2 Commits

Author SHA1 Message Date
3eac30a1e3
v2: events (WIP)
Signed-off-by: nfel <nfilsaraee@gmail.com>
2025-07-14 15:21:03 +03:30
7f8b4a2c5f
v2: priv -> internal healthcheck
Signed-off-by: nfel <nfilsaraee@gmail.com>
2025-07-14 15:20:51 +03:30
3 changed files with 39 additions and 17 deletions

View File

@ -2,8 +2,8 @@ syntax = "proto3";
package alert.v1;
import "base/v1/msg.proto";
import "auth/v1/msg.proto";
import "base/v1/msg.proto";
message AlertFilter {
base.v1.BaseQueryParam base_filter = 1;
@ -19,13 +19,29 @@ enum Importance {
CRITICAL = 3; // CRITICAL Severity ( can cause panics and data lost )
}
enum LogSource {
UNKNOWN = 0;
USER = 1;
SYSTEM = 2;
WALLET = 3;
enum LogType {
TYPE_UNKNOWN = 0;
TYPE_SMS = 1;
TYPE_EMAIL = 2;
TYPE_PUSH = 3;
}
enum LogLevel {
LVL_UNKNOWN = 0;
LVL_INFO = 1;
LVL_SUCCESS = 2;
LVL_WARN = 3;
LVL_ERROR = 4;
}
enum LogSource {
SRC_UNKNOWN = 0;
SRC_USER = 1;
SRC_SYSTEM = 2;
SRC_WALLET = 3;
}
message Meta {
uint32 created_at_ts = 1;
uint32 updated_at_ts = 2;
@ -35,13 +51,16 @@ message Meta {
message LogEvent {
auth.v1.InternalIAM iam = 1;
optional uint64 id = 2; // Record Id of Log stored in db
string content = 3;
optional LogSource source = 4;
Importance importance = 5;
Meta meta = 6;
LogSource source = 3;
Importance importance = 4;
LogLevel level = 5;
string content = 6;
Meta meta = 7;
}
message LogEventList { repeated LogEvent events = 1; }
message LogEventList {
repeated LogEvent events = 1;
}
/*
Internal Msg
*/
@ -59,4 +78,6 @@ message SMS {
repeated SMSChangeLog change_log = 5;
}
message SMSList { repeated SMS sms = 1; }
message SMSList {
repeated SMS sms = 1;
}

View File

@ -11,3 +11,4 @@ service AlertSrv {
// rpc Update(LogEvent) returns (base.v1.StatusRes) {}
// rpc Get(AlertFilter) returns (base.v1.StatusRes) {}
}

View File

@ -6,7 +6,7 @@ import "base/v1/msg.proto";
import "wallet/v1/msg.proto";
service InternalWalletSrv {
rpc PrivWalletSrvHealth(base.v1.Empty) returns (base.v1.StatusRes);
rpc InternalWalletSrvHealth(base.v1.Empty) returns (base.v1.StatusRes);
// Lock And Release Assets
rpc LockAsset(LockAssetReq) returns (base.v1.StatusRes);
rpc ReleaseAsset(LockAssetReq) returns (base.v1.StatusRes);