mirror of https://github.com/jackc/pgx.git
Add comments
Add Stat struct comment and correct Stat.MaxConns method commentpull/1086/head
parent
255276c390
commit
763050e10e
|
@ -6,6 +6,7 @@ import (
|
||||||
"github.com/jackc/puddle"
|
"github.com/jackc/puddle"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
// Stat is a snapshot of Pool statistics.
|
||||||
type Stat struct {
|
type Stat struct {
|
||||||
s *puddle.Stat
|
s *puddle.Stat
|
||||||
}
|
}
|
||||||
|
@ -50,7 +51,7 @@ func (s *Stat) IdleConns() int32 {
|
||||||
return s.s.IdleResources()
|
return s.s.IdleResources()
|
||||||
}
|
}
|
||||||
|
|
||||||
// MaxResources returns the maximum size of the pool.
|
// MaxConns returns the maximum size of the pool.
|
||||||
func (s *Stat) MaxConns() int32 {
|
func (s *Stat) MaxConns() int32 {
|
||||||
return s.s.MaxResources()
|
return s.s.MaxResources()
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue