Documentation ¶
Index ¶
- func ExpBackoff(last time.Duration, max time.Duration) (next time.Duration)
- func ListDirectory(dir string, filterFunc func(string) bool) ([]string, error)
- func NewThreadsafeSet(values ...string) *tsafeSet
- func NewUnsafeSet(values ...string) *unsafeSet
- func ParseFilepath(path string) string
- func ReadTLSConfigFiles(cafile, certfile, keyfile string) (cfg *tls.Config, err error)
- func TrimToDashes(args []string) []string
- type Event
- type EventStream
- type LoggingHTTPTransport
- type PeriodicReconciler
- type Set
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExpBackoff ¶ added in v0.5.3
func ListDirectory ¶ added in v0.9.0
ListDirectory generates a slice of all the file names that both exist in the provided directory and pass the filter. The returned file names are relative to the directory argument. filterFunc is called once for each file found in the directory. If filterFunc returns true, the given file will ignored.
func NewThreadsafeSet ¶ added in v0.6.0
func NewThreadsafeSet(values ...string) *tsafeSet
func NewUnsafeSet ¶ added in v0.6.0
func NewUnsafeSet(values ...string) *unsafeSet
func ParseFilepath ¶
ParseFilepath expands ~ and ~user constructions. If user or $HOME is unknown, do nothing.
func ReadTLSConfigFiles ¶ added in v0.9.0
func TrimToDashes ¶ added in v0.3.0
TrimToDashes takes a slice of strings (e.g. a command line) and returns everything after the first double dash (--), if any are present
Types ¶
type EventStream ¶ added in v0.8.0
type EventStream interface {
Next(stop chan struct{}) chan Event
}
EventStream generates a channel which will emit an event as soon as one of interest occurs. Any background operation associated with the channel should be terminated when stop is closed.
type LoggingHTTPTransport ¶ added in v0.7.0
type PeriodicReconciler ¶ added in v0.8.0
type PeriodicReconciler interface {
Run(stop chan bool)
}
func NewPeriodicReconciler ¶ added in v0.8.0
func NewPeriodicReconciler(interval time.Duration, recFunc func(), eStream EventStream) PeriodicReconciler
NewPeriodicReconciler creates a PeriodicReconciler that will run recFunc at least every ival, or in response to anything emitted from EventStream.Next()