Example #1
0
func sqlplusMetricNameConv(name string) string {
	name = strings.Replace(name, "<", "below_", -1)
	name = strings.Replace(name, ">=", "above_", -1)
	name = strings.Replace(name, "(", "", -1)
	name = strings.Replace(name, ")", "", -1)
	name = strings.Replace(name, "%", "ratio", -1)

	// ignore this error
	name, _ = opentsdb.Replace(strings.ToLower(name), "_")
	return name
}
Example #2
0
func replace(name string) string {
	r, _ := opentsdb.Replace(name, "_")
	return r
}