Пример #1
0
// NewService returns a new instance of Service.
func NewService() *Service {
	s := &Service{
		Service: copier.NewService(),
	}
	s.Service.TSDBStore = &s.TSDBStore

	if !testing.Verbose() {
		s.SetLogger(log.New(ioutil.Discard, "", 0))
	}
	return s
}
Пример #2
0
// NewService returns a new instance of Service.
func NewService() *Service {
	s := &Service{
		Service: copier.NewService(),
	}
	s.Service.TSDBStore = &s.TSDBStore

	if !testing.Verbose() {
		s.SetLogOutput(ioutil.Discard)
	}
	return s
}
Пример #3
0
func (s *Server) appendCopierService() {
	srv := copier.NewService()
	srv.TSDBStore = s.TSDBStore
	s.Services = append(s.Services, srv)
	s.CopierService = srv
}