consumer

package
v0.0.0-...-d2182b9 Latest Latest
Warning

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

Go to latest
Published: May 12, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package consumer is a generated GoMock package.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Consumer

type Consumer interface {
	Run(ctx context.Context, chResponse chan Response)
	DeleteMessage(messageReceipt *string) error
}

func New

func New(opts Options) Consumer

type Message

type Message sqs.Message

type MessageBody

type MessageBody struct {
	Type           string `json:"Type"`
	TopicARN       string `json:"TopicArn"`
	Message        string `json:"Message"`
	MessageID      string `json:"MessageId"`
	Timestamp      string `json:"Timestamp"`
	UnsubscribeURL string `json:"UnsubscribeURL"`
}

type MockConsumer

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

MockConsumer is a mock of Consumer interface.

func NewMockConsumer

func NewMockConsumer(ctrl *gomock.Controller) *MockConsumer

NewMockConsumer creates a new mock instance.

func (*MockConsumer) DeleteMessage

func (m *MockConsumer) DeleteMessage(messageReceipt *string) error

DeleteMessage mocks base method.

func (*MockConsumer) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockConsumer) Run

func (m *MockConsumer) Run(ctx context.Context, chResponse chan Response)

Run mocks base method.

type MockConsumerMockRecorder

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

MockConsumerMockRecorder is the mock recorder for MockConsumer.

func (*MockConsumerMockRecorder) DeleteMessage

func (mr *MockConsumerMockRecorder) DeleteMessage(messageReceipt interface{}) *gomock.Call

DeleteMessage indicates an expected call of DeleteMessage.

func (*MockConsumerMockRecorder) Run

func (mr *MockConsumerMockRecorder) Run(ctx, chResponse interface{}) *gomock.Call

Run indicates an expected call of Run.

type Options

type Options struct {
	QueueURL            *string
	MaxNumberOfMessages *int64
	Session             session.Session
	ReadMessageDelay    time.Duration
}

type Response

type Response struct {
	Error       error
	Message     *Message
	MessageBody *MessageBody
}

Jump to

Keyboard shortcuts

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