Skip to content

Commit

Permalink
change the method to detect the truncate
Browse files Browse the repository at this point in the history
Signed-off-by: Thomas Labarussias <[email protected]>
  • Loading branch information
Issif authored and poiana committed Jan 16, 2024
1 parent 0fb4ee3 commit 612f126
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plugins/k8saudit-eks/pkg/k8sauditeks/k8sauditeks.go
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ func (p *Plugin) Open(clustername string) (source.Instance, error) {
select {
case i := <-eventsC:
message := *i.Message
if strings.Contains(message, "[Truncated...]") {
if strings.HasSuffix(message, "[Truncated...]") {
auditID := regExpCAuditID.FindStringSubmatch(message)
if len(auditID) > 0 {
p.Logger.Printf("truncated log line, can't be parsed (%v)\n", auditID[0])
Expand Down

0 comments on commit 612f126

Please sign in to comment.