Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

1.9.3 stops reading config (without error) when there is a broken @INCLUDE #5454

Open
PettitWesley opened this issue May 14, 2022 · 1 comment
Labels
long-term Long term issues (exempted by stale bots) status: waiting-for-triage

Comments

@PettitWesley
Copy link
Contributor

Consider the following config:

[INPUT]
    Name tcp
    Listen 127.0.0.1
    Port 8877
    Tag firelens-healthcheck

[INPUT]
    Name forward
    unix_path /var/run/fluent.sock

[INPUT]
    Name forward
    Listen 127.0.0.1
    Port 24224

@INCLUDE

[OUTPUT]
    Name null
    Match firelens-healthcheck

[OUTPUT]
    Name cloudwatch
    Match web-firelens*
    auto_create_group true
    log_group_name group
    log_stream_name stream
    region us-west-2

Notice the @INCLUDE which is invalid and has no path. In previous versions this doens't cause any issue. In 1.9.3 it does.

1.9.3:

[2022/05/14 00:06:03] [ info] Configuration:
[2022/05/14 00:06:03] [ info]  flush time     | 1.000000 seconds
[2022/05/14 00:06:03] [ info]  grace          | 5 seconds
[2022/05/14 00:06:03] [ info]  daemon         | 0
[2022/05/14 00:06:03] [ info] ___________
[2022/05/14 00:06:03] [ info]  inputs:
[2022/05/14 00:06:03] [ info]      tcp
[2022/05/14 00:06:03] [ info]      forward
[2022/05/14 00:06:03] [ info]      forward
[2022/05/14 00:06:03] [ info] ___________
[2022/05/14 00:06:03] [ info]  filters:
[2022/05/14 00:06:03] [ info] ___________
[2022/05/14 00:06:03] [ info]  outputs:
[2022/05/14 00:06:03] [ info] ___________
[2022/05/14 00:06:03] [ info]  collectors:
[2022/05/14 00:06:03] [ info] [fluent bit] version=1.9.3, commit=a313296229, pid=1

Notice it thinks there are no outputs. Notice there is no error reading the config.

Whereas, in 1.8 series it happily ignores the invalid @include and then continues on and reads the outputs:

Fluent Bit v1.8.15
* Copyright (C) 2015-2021 The Fluent Bit Authors
* Fluent Bit is a CNCF sub-project under the umbrella of Fluentd
* https://fluentbit.io

[2022/05/14 00:07:03] [ info] Configuration:
[2022/05/14 00:07:03] [ info]  flush time     | 5.000000 seconds
[2022/05/14 00:07:03] [ info]  grace          | 5 seconds
[2022/05/14 00:07:03] [ info]  daemon         | 0
[2022/05/14 00:07:03] [ info] ___________
[2022/05/14 00:07:03] [ info]  inputs:
[2022/05/14 00:07:03] [ info]      tcp
[2022/05/14 00:07:03] [ info]      forward
[2022/05/14 00:07:03] [ info]      forward
[2022/05/14 00:07:03] [ info] ___________
[2022/05/14 00:07:03] [ info]  filters:
[2022/05/14 00:07:03] [ info] ___________
[2022/05/14 00:07:03] [ info]  outputs:
[2022/05/14 00:07:03] [ info]      null.0
[2022/05/14 00:07:03] [ info]      cloudwatch.1
[2022/05/14 00:07:03] [ info] ___________
[2022/05/14 00:07:03] [ info]  collectors:

**This is a bug. It should error if the @include is invalid or the old behavior should remain. **

@patrick-stephens
Copy link
Contributor

There's a couple of other issues with absolute includes as well: https://github.com/calyptia/fluent-bit-example/blob/main/examples/missing-include/README.md

They seem to mess up error handling so the actual missing one is not reported.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
long-term Long term issues (exempted by stale bots) status: waiting-for-triage
Projects
None yet
Development

No branches or pull requests

2 participants