Skip to content
This repository has been archived by the owner on Nov 28, 2022. It is now read-only.

Commit

Permalink
Changing Method name
Browse files Browse the repository at this point in the history
  • Loading branch information
cleberwarmling committed Nov 27, 2019
1 parent 157ebd7 commit 045e950
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions gauges/backends.go
Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ func (g *Gauges) MaxBackends() prometheus.Gauge {
)
}

// CurrentBackends returns the number of backends currently connected to all databases
func (g *Gauges) CurrentBackends() prometheus.Gauge {
// InstanceConnectedBackends returns the number of backends currently connected to all databases
func (g *Gauges) InstanceConnectedBackends() prometheus.Gauge {
return g.new(
prometheus.GaugeOpts{
Name: "postgresql_instance_connected_backends",
Expand Down
2 changes: 1 addition & 1 deletion gauges/backends_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ func TestMaxBackends(t *testing.T) {
assertNoErrs(t, gauges)
}

func TestCurrentBackends(t *testing.T) {
func TestInstanceConnectedBackends(t *testing.T) {
var assert = assert.New(t)
_, gauges, close := prepare(t)
defer close()
Expand Down
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ func watch(db *sql.DB, reg prometheus.Registerer, name string) {

reg.MustRegister(gauges.ConnectedBackends())
reg.MustRegister(gauges.MaxBackends())
reg.MustRegister(gauges.CurrentBackends())
reg.MustRegister(gauges.InstanceConnectedBackends())
reg.MustRegister(gauges.BackendsByState())
reg.MustRegister(gauges.BackendsByUserAndClientAddress())
reg.MustRegister(gauges.BackendsByWaitEventType())
Expand Down

0 comments on commit 045e950

Please sign in to comment.