阅读851 返回首页    go 微软 go windows


Logtail机器组__公共资源说明_API-Reference_日志服务-阿里云

机器:当机器安装Logtail并正常启动后,会根据Logtail配置中用户信息自动关联到当前用户。目前Machine有三种标示的方式,分别为:

  • IP: hostname对应IP地址,最容易理解,但在VPC等环境下可能有重复
  • UUID (machine-uniqueid):DMI设备中UUID,参见RFC4122
  • Userdefined-id: 用户在Logtail目录下自定义该机器标示

每台机器属性如下:

{
    "ip" : "testip1",
    "machine-uniqueid" : "testuuid1",
    "userdefined-id" : "testuserdefinedid1",
    "lastHeartbeatTime”:1397781420
 }
参数名称 类型 描述
ip string 机器hostname对应IP地址
uuid string 机器标示的唯一主键,由Logtail上传
userdefined-id string 用户自定义机器标示,由Logtail上传
lastHeartbeatTime(output-only) integer 机器的最后心跳时间(从epoch时间开始的秒数)

MachineGroup

Project下当前用户拥有的机器分组。机器分组可以通过两种方式来标示("ip"与“userdefined”),ip较为容易辨识,userdefined可以解决VPC下ip相同的问题,用户可以选任意一种方式进行机器标示。

MachineGroup命名规范

  • 只能包括小写字母,数字,短横线(-)和下划线(_)
  • 必须以小写字母或者数字开头和结尾
  • 长度必须在2-128字节以内

完整资源示例

{
    "groupName" : "testgroup",
    "groupType" : "",
    "groupAttribute" : {
        "externalName" : "testgroup",
        “groupTopic”: “testgrouptopic”
    },
    “machineIdentifyType”: "ip",
    "machineList" : [
        "ip1",
        "ip2"
        …
    ],
    “createTime”: 1431705075,
    "lastModifyTime" : 1431705075
}
属性名称 类型 必须 描述
groupName string 机器分组名称,Project下唯一
groupType string 机器分组类型,默认为空
machineIdentifyType string 机器标识类型,分为ip和userdefined两种
groupAttribute object 机器分组的属性,默认为空
machineList array 具体的机器标识,可以是ip或userdefined-id
createTime(output-only) int 该资源创建时间
lastModifyTime(output-only) int 该资源服务端更新时间

groupAttribute说明如下:

属性名称 类型 是否必须 描述
groupTopic string 机器分组的topic,默认为空
externalName string 机器分组所依赖的外部管理标识,默认为空

最后更新:2016-11-24 11:23:47

  上一篇:go Logtail配置__公共资源说明_API-Reference_日志服务-阿里云
  下一篇:go 查询语法__API-Reference_日志服务-阿里云