func (serv *SocketServer) EnableSignalShutdown(complete chan<- bool) {
	c := make(chan os.Signal, 1)
	signal.Notify(c,
		syscall.SIGHUP,
		syscall.SIGINT,
		syscall.SIGTERM,
		syscall.SIGQUIT,
		syscall.SIGKILL)
	go func() {
		<-c
		complete <- serv.Shutdown()
	}()
}
EnableSignalShutdown listens for linux syscalls SIGHUP, SIGINT, SIGTERM, SIGQUIT, SIGKILL and
calls the SocketServer.Shutdown() to perform a clean shutdown. true will be passed into complete
after the Shutdown proccess is finished
package ss
import (
	"github.com/gorilla/websocket"
	"github.com/raz-varren/log"
	"io"
	"net/http"
	"os"
	"os/signal"
	"strings"
	"sync"
	"syscall"
)
const (  
	startOfHeaderByte uint8 = 1  
	startOfDataByte         = 2  
	SubProtocol string = "sac-sock"
)
type event struct {
	eventName    string
	eventHandler func(*Socket, []byte)
}
type SocketServer struct {
	hub              *socketHub
	events           map[string]*event
	onConnectFunc    func(*Socket)
	onDisconnectFunc func(*Socket)
	l                *sync.RWMutex
	upgrader         *websocket.Upgrader
}
func NewServer() *SocketServer {
	s := &SocketServer{
		hub:      newHub(),
		events:   make(map[string]*event),
		l:        &sync.RWMutex{},
		upgrader: DefaultUpgrader(),
	}
	return s
}