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

Workaround to get Merge_Log working with native cri parser #5

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

aolmosj
Copy link

@aolmosj aolmosj commented Mar 2, 2023

The current custom cri parser stores app logs with some log info (timestamp, log type...) plus the json log. This is a problem for Merge_Log, which only works when the "log" field contains only json format log. The native cri parser stores the json log in a valid way, the problem is that it's stored in the "message" field, and now the problem is that is that Merge_Log only parses the log field.

References: #4

@rdbisme
Copy link

rdbisme commented Aug 9, 2023

Yeah, this works for me too (I didn't understand I was using the default cri parser tho)

@henrysachs
Copy link

I think youre missing the section under INPUT don't you?

@aolmosj
Copy link
Author

aolmosj commented Sep 1, 2023

What do you mean?

There is no need to change the INPUT section, since this setting in the current INPUT:

Parser cri

is using the fluent-bit native cri parser.

@henrysachs
Copy link

but then you dont use the cri-log parser because its never referenced?

@aolmosj
Copy link
Author

aolmosj commented Sep 1, 2023

Yes, you are right. I left that unused custom parser there for future reference, since this PR is a workaround for a fluent-bit bad implementation of Merge_log. But It could be perfectly removed from the configuration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants