Skip to content

启动配置项

qingyun-wyx edited this page Jul 24, 2018 · 25 revisions

Sentinel启动配置项允许在启动程序的时候设置相关参数,参数列表如下:

sentinel-core的配置项

名称 含义 类型 默认值 是否必需
project.name 指定程序的名称 String null
csp.sentinel.metric.file.single.size 单个监控文件的大小 long 52428800
csp.sentinel.metric.file.total.count 监控文件的总数上限 int 6

sentinel-transport-common的配置项

名称 含义 类型 默认值 是否必需
csp.sentinel.dashboard.server 控制台的地址,指定控制台后客户端会自动向改地址发送心跳包。地址格式为:hostIp:port String null
csp.sentinel.heartbeat.interval.ms 心跳包发送周期,单位毫秒 long null
csp.sentinel.api.port 本地启动HTTP API Server的端口号 int null

配置方式

上述参数所有均可通过JVM -D参数指定。除project.name之外,其余参数还可通过properties文件指定,路径为${home}/logs/csp/${project.name}.properties

Clone this wiki locally