Documentation ¶
Index ¶
Constants ¶
View Source
const ( POLICY_REPORT_IGNORE = "ignore" POLICY_REPORT_EVERY = "report" POLICY_REPORT_ONCE = "report-once" POLICY_METRIC_DROP = "drop" POLICY_METRIC_ZERO = "zero" POLICY_RETRY_YES = "retry" POLICY_RETRY_NO = "stop" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Policy ¶
type Policy struct { Report string Metric string Retry string // contains filtered or unexported fields }
func (*Policy) ReportError ¶
type TruncateErrorPolicy ¶ added in v1.0.2
type TruncateErrorPolicy struct { Policy Policy // contains filtered or unexported fields }
func NewTruncateErrorPolicy ¶ added in v1.0.2
func NewTruncateErrorPolicy(s string) *TruncateErrorPolicy
func (*TruncateErrorPolicy) TruncateError ¶ added in v1.0.2
func (p *TruncateErrorPolicy) TruncateError(err error, stop *bool, collectedMetrics []blip.MetricValue) ([]blip.MetricValue, error)
Handles errors related to truncating tables, specifically those in `performance_schema` where `TRUNCATE` is used to reset the collected performance metrics. This should be called to proces the result of a `TRUNCATE` query even if no error occurrred. It will handle adjusting the collected metric values as necessary based on the success or failure of `TRUNCATE` so that only metrics that were collected from a sample that had a valid collection interval are returned.
Click to show internal directories.
Click to hide internal directories.