main.go 377 B

123456789101112131415161718192021
  1. // package main -- пускач для сервиса
  2. package main
  3. import (
  4. "log"
  5. "os"
  6. "adt/intertnal/fabrics"
  7. )
  8. func main() {
  9. serv, err := fabrics.MakeService()
  10. if err != nil {
  11. log.Printf("main(): in create IService, err=\n\t%v\n", err)
  12. os.Exit(1)
  13. }
  14. if err := serv.Run(); err != nil {
  15. log.Printf("main(): in IService.Run, err=\n\t%v\n", err)
  16. os.Exit(2)
  17. }
  18. }