Skip to content

Commit

Permalink
Update logPluginOutputSize calls for consistency
Browse files Browse the repository at this point in the history
Replace indicators of writing to a buffer (something the logging
calls can't know) with writing to a given output sink (which
matches the language used nearby.
  • Loading branch information
atc0005 committed Nov 14, 2024
1 parent 7a1d053 commit 32031b2
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions sections.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ func (p Plugin) handleServiceOutputSection(w io.Writer) {
panic("Failed to write ServiceOutput to given output sink")
}

p.logPluginOutputSize(fmt.Sprintf("%d bytes plugin ServiceOutput content written to buffer", written))
p.logPluginOutputSize(fmt.Sprintf("%d bytes plugin ServiceOutput content written to given output sink", written))
}

// handleErrorsSection is a wrapper around the logic used to handle/process
Expand Down Expand Up @@ -89,7 +89,7 @@ func (p Plugin) handleErrorsSection(w io.Writer) {
}
}

p.logPluginOutputSize(fmt.Sprintf("%d bytes total plugin errors content written to buffer", totalWritten))
p.logPluginOutputSize(fmt.Sprintf("%d bytes total plugin errors content written to given output sink", totalWritten))
}

// handleThresholdsSection is a wrapper around the logic used to
Expand Down Expand Up @@ -153,7 +153,7 @@ func (p Plugin) handleThresholdsSection(w io.Writer) {
totalWritten += written
}

p.logPluginOutputSize(fmt.Sprintf("%d bytes plugin thresholds section content written to buffer", totalWritten))
p.logPluginOutputSize(fmt.Sprintf("%d bytes plugin thresholds section content written to given output sink", totalWritten))
}

// handleLongServiceOutput is a wrapper around the logic used to
Expand Down Expand Up @@ -218,7 +218,7 @@ func (p Plugin) handleLongServiceOutput(w io.Writer) {

totalWritten += written

p.logPluginOutputSize(fmt.Sprintf("%d bytes plugin LongServiceOutput content written to buffer", totalWritten))
p.logPluginOutputSize(fmt.Sprintf("%d bytes plugin LongServiceOutput content written to given output sink", totalWritten))
}

// handleEncodedPayload is a wrapper around the logic used to handle/process
Expand Down Expand Up @@ -287,7 +287,7 @@ func (p Plugin) handleEncodedPayload(w io.Writer) {
totalWritten += written
}

p.logPluginOutputSize(fmt.Sprintf("%d bytes plugin EncodedPayload content written to buffer", totalWritten))
p.logPluginOutputSize(fmt.Sprintf("%d bytes plugin EncodedPayload content written to given output sink", totalWritten))
}

// handlePerformanceData is a wrapper around the logic used to
Expand Down Expand Up @@ -346,7 +346,7 @@ func (p *Plugin) handlePerformanceData(w io.Writer) {

totalWritten += written

p.logPluginOutputSize(fmt.Sprintf("%d bytes plugin performance data content written to buffer", totalWritten))
p.logPluginOutputSize(fmt.Sprintf("%d bytes plugin performance data content written to given output sink", totalWritten))

}

Expand Down

0 comments on commit 32031b2

Please sign in to comment.