Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Modes = [...]Mode{Memory, Kafka}
Modes contains all the possible modes
Functions ¶
Types ¶
type Repository ¶
type Repository interface { GetAll() []*Request Increment(path string, input map[string]interface{}) error io.Closer }
Repository to store stats
type Request ¶
type Request struct { Path string `json:"path"` NbHits int `json:"nbHits"` Parameters map[string]interface{} `json:"parameters,omitempty"` }
Request stats data structure
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service to store stats
func NewService ¶
func NewService(r Repository) *Service
NewService creates a service to handle request stats
Click to show internal directories.
Click to hide internal directories.