...
 
Commits (3)
    https://gitcode.net/oceanbase/obagent/-/commit/addbe86a4b11b4d5500392f27c4d73c79347eb67 fix typo 2022-11-01T11:42:26+08:00 chris-sun-star hongxin.sun.vip@gmail.com https://gitcode.net/oceanbase/obagent/-/commit/d1f83aa115679b3e35367de3510ba86c462fc227 fix test 2022-11-01T15:27:19+08:00 chris-sun-star hongxin.sun.vip@gmail.com https://gitcode.net/oceanbase/obagent/-/commit/f45106ec8f694426af1aeed2eae595d149734ad5 Merge pull request #30 from chris-sun-star/master 2022-11-01T15:29:09+08:00 chris-sun-star 85611200+chris-sun-star@users.noreply.github.com fix error message
......@@ -13,6 +13,7 @@ require (
github.com/go-sql-driver/mysql v1.6.0
github.com/golang/protobuf v1.5.2 // indirect
github.com/gwatts/gin-adapter v0.0.0-20170508204228-c44433c485ad
github.com/hashicorp/golang-lru v0.5.3 // indirect
github.com/huandu/go-clone v1.3.0
github.com/kr/text v0.2.0 // indirect
github.com/mattn/go-isatty v0.0.12
......
......@@ -148,7 +148,7 @@ func (m *MysqldExporter) Collect() ([]metric.Metric, error) {
metricFamilies, err := m.registry.Gather()
if err != nil {
return nil, errors.Wrap(err, "node exporter registry gather")
return nil, errors.Wrap(err, "mysql exporter registry gather")
}
for _, metricFamily := range metricFamilies {
metricsFromMetricFamily := metric.ParseFromMetricFamily(metricFamily)
......
......@@ -130,7 +130,7 @@ func TestCollectConditionNotSatisfied(t *testing.T) {
k1: 1
collectConfig:
- sql: select t1, t2, m1, m2 from test_metric
condition: k0
conditions: [k0]
name: test
tags:
tag1: t1
......@@ -161,7 +161,7 @@ func TestCollectConditionNotFound(t *testing.T) {
k1: 1
collectConfig:
- sql: select t1, t2, m1, m2 from test_metric
condition: k2
conditions: [k2]
name: test
tags:
tag1: t1
......@@ -193,7 +193,7 @@ func TestCollectConditionNotBool(t *testing.T) {
k2: x
collectConfig:
- sql: select t1, t2, m1, m2 from test_metric
condition: k2
conditions: [k2]
name: test
tags:
tag1: t1
......