Class: Fluent::DockerMetricsInput::CGroupStatsParser
- Inherits:
-
Object
- Object
- Fluent::DockerMetricsInput::CGroupStatsParser
show all
- Defined in:
- lib/fluent/plugin/in_docker_metrics.rb
Instance Method Summary
collapse
Constructor Details
Returns a new instance of CGroupStatsParser.
96
97
98
99
100
|
# File 'lib/fluent/plugin/in_docker_metrics.rb', line 96
def initialize(path, metric_type)
raise ConfigError if not File.exists?(path)
@path = path
@metric_type = metric_type
end
|
Instance Method Details
#parse_each_line(&block) ⇒ Object
105
106
107
108
109
|
# File 'lib/fluent/plugin/in_docker_metrics.rb', line 105
def parse_each_line(&block)
File.new(@path).each_line do |line|
block.call(parse_line(line))
end
end
|
#parse_line(line) ⇒ Object
102
103
|
# File 'lib/fluent/plugin/in_docker_metrics.rb', line 102
def parse_line(line)
end
|