services

package
v0.2.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 27, 2026 License: AGPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MessagesService

type MessagesService struct {
	// contains filtered or unexported fields
}

func NewMessagesService

func NewMessagesService(metricsService metrics.Service, forqRepo *db.ForqRepo, appConfigs *configs.AppConfigs) *MessagesService

func (*MessagesService) AckMessage

func (ms *MessagesService) AckMessage(messageId string, queueName string, ctx context.Context) error

func (*MessagesService) DeleteAllDlqMessages

func (ms *MessagesService) DeleteAllDlqMessages(queueName string, ctx context.Context) error

func (*MessagesService) DeleteDlqMessage

func (ms *MessagesService) DeleteDlqMessage(messageId string, queueName string, ctx context.Context) error

func (*MessagesService) GetMessageDetails

func (ms *MessagesService) GetMessageDetails(messageId string, queueName string, ctx context.Context) (*common.MessageDetails, error)

func (*MessagesService) GetMessageForConsuming

func (ms *MessagesService) GetMessageForConsuming(queueName string, ctx context.Context) (*common.MessageResponse, error)

func (*MessagesService) GetMessagesForUI

func (ms *MessagesService) GetMessagesForUI(queueName string, cursor string, limit int, ctx context.Context) (*common.MessagesComponentData, error)

func (*MessagesService) NackMessage

func (ms *MessagesService) NackMessage(messageId string, queueName string, ctx context.Context) error

func (*MessagesService) ProcessNewMessage

func (ms *MessagesService) ProcessNewMessage(newMessage common.NewMessageRequest, queueName string, ctx context.Context) error

func (*MessagesService) RequeueAllDlqMessages

func (ms *MessagesService) RequeueAllDlqMessages(queueName string, ctx context.Context) error

func (*MessagesService) RequeueDlqMessage

func (ms *MessagesService) RequeueDlqMessage(messageId string, queueName string, ctx context.Context) error

type MonitoringService

type MonitoringService struct {
	// contains filtered or unexported fields
}

func NewMonitoringService

func NewMonitoringService(repo *db.ForqRepo) *MonitoringService

func (*MonitoringService) IsHealthy

func (ms *MonitoringService) IsHealthy(ctx context.Context) bool

type QueuesService

type QueuesService struct {
	// contains filtered or unexported fields
}

func NewQueuesService

func NewQueuesService(forqRepo *db.ForqRepo) *QueuesService

func (*QueuesService) GetQueueStats

func (qs *QueuesService) GetQueueStats(queueName string, ctx context.Context) (*common.QueueStats, error)

func (*QueuesService) GetQueuesStats

func (qs *QueuesService) GetQueuesStats(ctx context.Context) (*common.DashboardPageData, error)

type SessionsService

type SessionsService struct {
	// contains filtered or unexported fields
}

func NewSessionsService

func NewSessionsService() *SessionsService

func (*SessionsService) Close

func (ss *SessionsService) Close() error

func (*SessionsService) CreateSession

func (ss *SessionsService) CreateSession() (string, int64)

func (*SessionsService) InvalidateSession

func (ss *SessionsService) InvalidateSession(sessionId string)

func (*SessionsService) IsSessionValid

func (ss *SessionsService) IsSessionValid(sessionId string) bool

type ThrottlingService added in v0.2.0

type ThrottlingService struct {
	// contains filtered or unexported fields
}

ThrottlingService tracks failed-auth attempts per IP and locks out IPs that exceed the threshold within a sliding window. In-memory only: process restart wipes all state.

func NewThrottlingService added in v0.2.0

func NewThrottlingService() *ThrottlingService

func (*ThrottlingService) Close added in v0.2.0

func (ts *ThrottlingService) Close() error

func (*ThrottlingService) IsLocked added in v0.2.0

func (ts *ThrottlingService) IsLocked(ip string) bool

func (*ThrottlingService) RecordFailure added in v0.2.0

func (ts *ThrottlingService) RecordFailure(ip string)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL