• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

kuoss / lethe / 11218761882

07 Oct 2024 03:23PM UTC coverage: 69.747%. First build
11218761882

Pull #122

github

jmnote
main
Pull Request #122: main

5 of 6 new or added lines in 1 file covered. (83.33%)

2181 of 3127 relevant lines covered (69.75%)

0.77 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

91.3
/app/app.go
1
package app
2

3
import (
4
        "fmt"
5

6
        "github.com/kuoss/common/logger"
7
        "github.com/kuoss/lethe/config"
8
        "github.com/kuoss/lethe/rotator"
9
        "github.com/kuoss/lethe/router"
10
        "github.com/kuoss/lethe/storage/fileservice"
11
        "github.com/kuoss/lethe/storage/logservice"
12
        "github.com/kuoss/lethe/storage/queryservice"
13
)
14

15
func Run(version string) error {
1✔
16
        // Load configuration
1✔
17
        cfg, err := config.New(version)
1✔
18
        if err != nil {
2✔
19
                return fmt.Errorf("failed to load configuration: %w", err)
1✔
20
        }
1✔
21
        logger.Infof("Loaded configuration: %v", cfg)
1✔
22

1✔
23
        // Initialize services
1✔
24
        fileService, err := fileservice.New(cfg)
1✔
25
        if err != nil {
1✔
NEW
26
                return fmt.Errorf("new fileservice err: %w", err)
×
27
        }
×
28
        logService := logservice.New(cfg, fileService)
1✔
29
        queryService := queryservice.New(cfg, logService)
1✔
30

1✔
31
        // Create rotator & router
1✔
32
        myRotator := rotator.New(cfg, fileService)
1✔
33
        myRouter := router.New(cfg, fileService, queryService)
1✔
34

1✔
35
        // Run
1✔
36
        myRotator.Start()
1✔
37
        return myRouter.Run()
1✔
38
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc