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

Fix pod oom events cannot be emitted #15

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

Conversation

fighterhit
Copy link

Fix pod oom events cannot be emitted due to regular expression error and lack of kernel-monitor rule whose reason is PodOOMKilling.

matched := l.buffer.Match(rule.Pattern)
if len(matched) == 0 {
continue
}
status := l.generateStatus(matched, rule)

message := generateMessage(logs)
if rule.Reason == OOMREASON && k8sClient != nil {
uuid := string(uuidRegx.Find([]byte(message)))

Because this is based on whether the reason is PodOOMKilling, so there has to be such a rule that can both be matched by the uuidRegx regular expression in the code.

…and lack of kernel-monitor rule whose reason is PodOOMKilling
@KeyOfSpectator KeyOfSpectator requested review from ringtail and KeyOfSpectator and removed request for ringtail November 28, 2024 03:21
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.

1 participant