ЛР 2: закрыть уровень 4
Завершить PostgreSQL, Redis-сессии, миграции, таймауты и диагностику. Зафиксировать собственные тесты и доказательства финального прогона: 43 PASS, 0 FAIL, 0 SKIP; 768 HTTP-запросов без ошибок. Добавить официальный отчёт с запуском, архитектурой, SQL-планами и ограничениями. PR отложен до завершения уровня 5.
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
package repository
|
||||
|
||||
import (
|
||||
"context"
|
||||
"highload/internal/model"
|
||||
"time"
|
||||
)
|
||||
|
||||
type MessageRepository interface {
|
||||
CreateMessage(ctx context.Context, chatID, senderID, text string) (*model.Message, error)
|
||||
GetMessagesByChatID(ctx context.Context, chatID string, limit int, after *MessagePosition) ([]*model.Message, error)
|
||||
}
|
||||
|
||||
type MessagePosition struct {
|
||||
CreatedAt time.Time
|
||||
ID string
|
||||
}
|
||||
Reference in New Issue
Block a user