68c87940 |
package daemon
|
6bb0d181 |
import (
"time"
"github.com/docker/docker/container"
) |
68c87940 |
// newStatsCollector returns a new statsCollector for collection stats
// for a registered container at the specified interval. The collector allows
// non-running containers to be added and will start processing stats when
// they are started. |
63efc120 |
func (daemon *Daemon) newStatsCollector(interval time.Duration) *statsCollector { |
68c87940 |
return &statsCollector{}
}
// statsCollector manages and provides container resource stats
type statsCollector struct {
}
// collect registers the container with the collector and adds it to
// the event loop for collection on the specified interval returning
// a channel for the subscriber to receive on. |
6bb0d181 |
func (s *statsCollector) collect(c *container.Container) chan interface{} { |
68c87940 |
return nil
}
// stopCollection closes the channels for all subscribers and removes
// the container from metrics collection. |
6bb0d181 |
func (s *statsCollector) stopCollection(c *container.Container) { |
68c87940 |
}
// unsubscribe removes a specific subscriber from receiving updates for a container's stats. |
6bb0d181 |
func (s *statsCollector) unsubscribe(c *container.Container, ch chan interface{}) { |
68c87940 |
} |