程序包 com.alibaba.csp.sentinel.node.metric


package com.alibaba.csp.sentinel.node.metric
  • 说明
    Metrics data for a specific resource at given timestamp.
    从指定目录下找出所有的metric文件,并按照指定时间戳进行检索,参考MetricSearcher.find(long, int)。 会借助索引以提高检索效率,参考MetricWriter;还会在内部缓存上一次检索的文件指针,以便下一次顺序检索时 减少读盘次数。
     
    This class is responsible for writing MetricNode to disk: metric with the same second should write to the same file; single file size must be controlled; file name is like: ${appName}-metrics.log.pid${pid}.yyyy-MM-dd.[number] metric of different day should in different file; every metric file is accompanied with an index file, which file name is ${metricFileName}.idx