feat: add bounded observability and verified SLO incident alerts

This commit is contained in:
Vladislav Agapov
2026-10-29 18:01:11 +03:00
parent 470d9d6f1e
commit 6c7601802d
325 changed files with 24988 additions and 44 deletions
+27
View File
@@ -0,0 +1,27 @@
package service
import (
"errors"
"gitea.privcloud.tech/vlad_marlo/mtusi2026lab6/internal/store"
)
var (
// ErrTooLarge rejects encoded or decoded images beyond policy.
ErrTooLarge = errors.New("image exceeds limit")
// ErrMedia rejects unsupported or corrupted image bytes.
ErrMedia = errors.New("invalid image")
// ErrUnavailable preserves the dependency failure category across service boundaries.
ErrUnavailable = store.ErrUnavailable
// ErrInvalid indicates invalid operation input.
ErrInvalid = errors.New("invalid request")
// ErrUnauthorized indicates an unresolved current user.
ErrUnauthorized = errors.New("unknown user identity")
// ErrNotFound hides both absent and inaccessible resources.
ErrNotFound = errors.New("resource not found")
// ErrConflict indicates a duplicate username.
ErrConflict = errors.New("username already exists")
// ErrCapacity indicates exhausted storage capacity without eviction.
ErrCapacity = errors.New("in-memory storage capacity reached")
)