func WithLogger(logger *zerolog.Logger) Option {
	return func(opts *Options) {
		opts.Logger = logger
	}
}
WithLogger sets the logger for the frisbee client or server
package frisbee
import (
	"crypto/tls"
	"github.com/rs/zerolog"
	"os"
	"time"
)
type Option func(opts *Options)
var DefaultLogger = zerolog.New(os.Stdout)
type Options struct {
	KeepAlive time.Duration
	Heartbeat time.Duration
	Logger    *zerolog.Logger
	TLSConfig *tls.Config
}
func loadOptions(options ...Option) *Options {
	opts := new(Options)
	for _, option := range options {
		option(opts)
	}
	if opts.Logger == nil {
		opts.Logger = &DefaultLogger
	}
	if opts.KeepAlive == 0 {
		opts.KeepAlive = time.Minute * 3
	}
	if opts.Heartbeat == 0 {
		opts.Heartbeat = time.Second * 5
	}
	return opts
}
func WithOptions(options Options) Option {
	return func(opts *Options) {
		*opts = options
	}
}
func WithKeepAlive(keepAlive time.Duration) Option {
	return func(opts *Options) {
		opts.KeepAlive = keepAlive
	}
}