/**
* @file cmmstruct.proto
* @brief  TDSCmd define
* @author Fan Chuanlin, fanchuanlin@aliyun.com
* @version 1.0
* @date 2022-09-06
*/

syntax = "proto3";

import "google/protobuf/any.proto";
import "google/protobuf/timestamp.proto";

enum IID
{
	IID_Base = 0;
	IID_Server_Base = 10000;
	IID_Server_xxx = 10001;
	IID_Server_xxx_respond = 10002;
	IID_UI_Base = 20000;
	IID_UI_xxx = 20001;
	IID_UI_xxx_respond = 20002;
	IID_Device_Base = 30000;
	IID_Device_xxx = 30001;
	IID_Device_xxx_respond = 30002;
	IID_AGI_Base = 40000;
	IID_AGI_xxx = 40001;
	IID_AGI_xxx_respond = 40002;
	IID_OAM_Base = 50000;
	IID_OAM_xxx = 50001;
	IID_OAM_xxx_respond = 50002;

	/*
	......
	xxxx  id%2 == 1
	xxxx_respond = id+1
	*/
}

/// sub system define
enum BROKERAREA
{
    BROKERAREA_LOCAL = 0;
    BROKERAREA_CLOUD_LEVEL2 = 1;
    BROKERAREA_CLOUD_LEVEL1 = 2;
}

enum SUBSYSTEM
{
    SUBSYSTEM_base = 0;
    SUBSYSTEM_UI = 1;
    SUBSYSTEM_Server =2;
    SUBSYSTEM_Device = 3;
    SUBSYSTEM_AGI = 4;
    SUBSYSTEM_OAM =5;
    SUBSYSTEM_default = 6;
}

message TestParams
{
	string key = 1;
	string value = 2;
}

message Heartbeat
{
	uint32 suid = 1;
	repeated IID iid_list = 2;
}

message TDSCmd
{
	IID interface_id = 1;
	uint32 dst_suid = 2;
	uint32 src_suid = 3;
	uint32 forward_flag = 4;
	uint32 priority = 5;
	google.protobuf.Timestamp ts = 6;
    repeated google.protobuf.Any parameters = 7;
}
