Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConnectionPool ¶
type ConnectionPool struct {
// contains filtered or unexported fields
}
func NewConnectionPool ¶
func NewConnectionPool( count int, target string, opts ...grpc.DialOption, ) *ConnectionPool
Creates a new GRPC based connection pool for the given `target` and with the `opts` from GRPC.
The connections are safe to be used from multiple goroutines.
func (*ConnectionPool) Close ¶
func (pool *ConnectionPool) Close()
Closes all of the connections in the pool
func (*ConnectionPool) Connection ¶
func (pool *ConnectionPool) Connection() *grpc.ClientConn
Picks a random connection from the pool.
Click to show internal directories.
Click to hide internal directories.