| 25 | } |
| 26 | |
| 27 | type Controller struct { |
| 28 | backend backend.Backend |
| 29 | cfg *config.Config |
| 30 | apiPort int |
| 31 | metricPort int |
| 32 | clientIP string |
| 33 | lastRequest time.Time |
| 34 | stats *common.SystemStatsResponse |
| 35 | cancelFunc context.CancelFunc |
| 36 | mu sync.RWMutex |
| 37 | } |
| 38 | |
| 39 | func New(cfg *config.Config) *Controller { |
| 40 | _, cancel := context.WithCancel(context.Background()) |
nothing calls this directly
no outgoing calls
no test coverage detected