Skip to content

Commit

Permalink
fix: applicaition log decode failed causes subsequent data anomalies
Browse files Browse the repository at this point in the history
  • Loading branch information
lzf575 committed Sep 20, 2024
1 parent 417f578 commit d10b0ef
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions server/ingester/app_log/decoder/decoder.go
Original file line number Diff line number Diff line change
Expand Up @@ -483,10 +483,9 @@ func (d *Decoder) handleAppLog(agentId uint16, decoder *codec.SimpleDecoder) {
err := json.UnmarshalString(utils.String(bytes), &d.appLogEntrysCache)
if err != nil {
if d.counter.ErrorCount == 0 {
log.Errorf("application log json decode failed: %s", err)
log.Errorf("application log (%s) json decode (%d) failed: %s", utils.String(bytes), len(d.appLogEntrysCache), err)
}
d.counter.ErrorCount++
return
}
for i, appLogEntry := range d.appLogEntrysCache {
if err := d.WriteAppLog(agentId, &appLogEntry); err != nil {
Expand Down

0 comments on commit d10b0ef

Please sign in to comment.