sentinel.go
func (s *Sentinel) Register(server, shutdown interface{}, ignore ...func(error) bool) error {
	// add server and shutdown funcs
	var err error
	s.serverFuncs, err = convertAndAppendContextFuncs(s.serverFuncs, server)
	if err != nil {
		return err
	}
	s.shutdownFuncs, err = convertAndAppendContextFuncs(s.shutdownFuncs, shutdown)
	if err != nil {
		return err

	}
	s.ignoreErrors = append(s.ignoreErrors, ignore...)
	return nil
}
func (s *Sentinel) Register(server, shutdown interface{}, ignore ...func(error) bool) error {
	// add server and shutdown funcs
	var err error
	s.serverFuncs, err = convertAndAppendContextFuncs(s.serverFuncs, server)
	if err != nil {
		return err
	}
	s.shutdownFuncs, err = convertAndAppendContextFuncs(s.shutdownFuncs, shutdown)
	if err != nil {
		return err

	}
	s.ignoreErrors = append(s.ignoreErrors, ignore...)
	return nil
}
// Register registers a server, its shutdown func, and ignore error funcs.