Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrNilConfig = errors.New("cannot override nil config")
Functions ¶
This section is empty.
Types ¶
type TransactionSubscriber ¶
type TransactionSubscriber struct {
// contains filtered or unexported fields
}
TransactionSubscriber represents a service that subscribes to transaction-related messages and handles them based on their type (succeeded or failed).
func NewTransactionSubscriber ¶
func NewTransactionSubscriber( cfg *Config, log logger.Logger, sub message.Subscriber, router *message.Router, transactionRepo repository.TransactionRepo, ) (*TransactionSubscriber, error)
NewTransactionSubscriber creates a new TransactionSubscriber instance with the provided dependencies.
func (*TransactionSubscriber) RegisterFailedTransactionHandler ¶
func (s *TransactionSubscriber) RegisterFailedTransactionHandler()
RegisterFailedTransactionHandler registers a handler for failed transaction messages.
func (*TransactionSubscriber) RegisterSucceededTransactionHandler ¶
func (s *TransactionSubscriber) RegisterSucceededTransactionHandler()
RegisterSucceededTransactionHandler registers a handler for succeeded transaction messages.
type TransactionSubscriberError ¶
type TransactionSubscriberError struct {
// contains filtered or unexported fields
}
TransactionSubscriberError represents an error type specific to the creation of transaction subscribers.
func NewTransactionSubscriberError ¶
func NewTransactionSubscriberError(msg string, err error) *TransactionSubscriberError
NewTransactionSubscriberError creates a new TransactionSubscriberError instance.
func (TransactionSubscriberError) Error ¶
func (e TransactionSubscriberError) Error() string
Click to show internal directories.
Click to hide internal directories.