package connrotation
import "k8s.io/client-go/util/connrotation"
Package connrotation implements a connection dialer that tracks and can close all created connections.
This is used for credential rotation of long-lived connections, when there's no way to re-authenticate on a live connection.
Index ¶
Types ¶
type DialFunc ¶
DialFunc is a shorthand for signature of net.DialContext.
type Dialer ¶
type Dialer struct {
// contains filtered or unexported fields
}
Dialer opens connections through Dial and tracks them.
func NewDialer ¶
NewDialer creates a new Dialer instance.
If dial is not nil, it will be used to create new underlying connections. Otherwise net.DialContext is used.
func (*Dialer) CloseAll ¶
func (d *Dialer) CloseAll()
CloseAll forcibly closes all tracked connections.
Note: new connections may get created before CloseAll returns.
func (*Dialer) Dial ¶
Dial creates a new tracked connection.
func (*Dialer) DialContext ¶
DialContext creates a new tracked connection.
Source Files ¶
connrotation.go
- Version
- v0.18.10-rc.0
- Published
- Sep 16, 2020
- Platform
- js/wasm
- Imports
- 3 packages
- Last checked
- 19 seconds ago –
Tools for package owners.