Linting and comments.

This commit is contained in:
2020-12-23 20:55:50 +05:00
parent 08d5f36c36
commit 115e5d5051
5 changed files with 17 additions and 8 deletions

View File

@@ -9,16 +9,16 @@ import (
"go.dev.pztrn.name/metricator/internal/models"
)
// ErrMetricNotFound appears if requested metric wasn't found in storage.
var ErrMetricNotFound = errors.New("metric not found")
// Storage is an in-memory storage.
type Storage struct {
ctx context.Context
doneChan chan struct{}
logger *logger.Logger
name string
ctx context.Context
doneChan chan struct{}
logger *logger.Logger
data map[string]models.Metric
name string
dataMutex sync.RWMutex
}