func Init(servers []string) (*WSUS, error) {
	var w WSUS
	var err error
	if len(servers) == 0 {
		w.ServerSelection = WindowsUpdate
		return &w, w.Clear()
	}
	wlog, err = eventlog.Open("Cabbie WSUS")
	if err != nil {
		return &w, err
	}
	w.order(servers)
	if len(w.Servers) == 0 {
		w.ServerSelection = WindowsUpdate
		return &w, w.Clear()
	}
	if err := w.Set(0); err != nil {
		w.ServerSelection = WindowsUpdate
		return &w, fmt.Errorf("error setting WSUS config:\n%v", err)
	}
	w.ServerSelection = ManagedServer
	return &w, nil
}
Init will initialize the local update client with the desired WSUS config.
package wsus
import (
	"fmt"
	"net/http"
	"sort"
	"time"
	"github.com/google/cabbie/cablib"
	"golang.org/x/sys/windows/registry"
	"golang.org/x/sys/windows/svc/eventlog"
)
var (
	wlog *eventlog.Log
)
const (
	Default = iota
	ManagedServer
	WindowsUpdate
	Others
)
type WSUS struct {
	CurrentServer   string
	ServerSelection int
	Servers         []string
}
func sortedKeys(s map[int]string) []int {
	var keys []int
	for k := range s {
		keys = append(keys, k)
	}
	sort.Ints(keys)
	return keys
}
func responseTime(name string) time.Duration {
	req, err := http.NewRequest("GET", fmt.Sprintf("https://%s", name), nil)
	if err != nil {
		wlog.Warning(3, fmt.Sprintf("Failed to create new http request: %v", err))
		return 0
	}
	start := time.Now()
	resp, err := http.DefaultTransport.RoundTrip(req)
	if err != nil {
		wlog.Warning(3, fmt.Sprintf("Failed to send GET request to: %v", err))
		return 0
	}
	if resp.StatusCode != http.StatusOK {
		wlog.Warning(3, fmt.Sprintf("Non-200 status code returned(%d)", resp.StatusCode))
		return 0
	}
	return time.Since(start)
}