Упростить ошибки сессий, логировать миграции и тестировать с рабочим клиентом Valkey

This commit is contained in:
2026-10-06 15:46:01 +03:00
parent 405fb07608
commit f9850a36c4
7 changed files with 39 additions and 34 deletions
+3 -1
View File
@@ -42,9 +42,11 @@ func run(ctx context.Context, log *slog.Logger, cfg config.Config) error {
return err
}
defer pool.Close()
if err := postgres.Migrate(ctx, pool); err != nil {
applied, err := postgres.Migrate(ctx, pool)
if err != nil {
return err
}
log.Info("schema ready", "applied_migrations", applied)
sessions, err := valkey.NewClient(ctx, cfg.SessionStoreURL)
if err != nil {
return err