fluent/fluentd · error · Fluent::ConfigError
Missing worker id on <worker> directive
Error message
Missing worker id on <worker> directive
What it means
Error "Missing worker id on <worker> directive" thrown in fluent/fluentd.
Source
Thrown at lib/fluent/static_config_analysis.rb:107
end
end
nodes = [
static_label_analyse(config),
static_filter_and_output_analyse(config),
static_input_analyse(config),
].flatten
ret << Elem::Worker.new(ids, config, nodes)
end
ret
end
def parse_worker_id(conf)
worker_id_str = conf.arg
if worker_id_str.empty?
raise Fluent::ConfigError, 'Missing worker id on <worker> directive'
end
l, r =
begin
worker_id_str.split('-', 2).map { |v| Integer(v) }
rescue TypeError, ArgumentError
raise Fluent::ConfigError, "worker id should be integer: #{worker_id_str}"
end
if l < 0 || l >= @workers
raise Fluent::ConfigError, "worker id #{l} specified by <worker> directive is not allowed. Available worker id is between 0 and #{@workers-1}"
end
# e.g. specified one worker id like `<worker 0>`
if r.nil?
return [l]
end
View on GitHub (pinned to dd45c6e18d)
When it happens
Trigger: Thrown at lib/fluent/static_config_analysis.rb:107 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of fluent/fluentd@dd45c6e18d (2026-08-21).
Data as JSON: /api/errors/247dd66a0ee80a47.
Report an issue: GitHub.