topic

package
v0.0.0-...-590dc54 Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Interface

type Interface interface {
	Get(ctx context.Context, project, service, topic string) (*aiven.KafkaTopic, error)
	List(ctx context.Context, project, service string) ([]*aiven.KafkaListTopic, error)
	Create(ctx context.Context, project, service string, req aiven.CreateKafkaTopicRequest) error
	Update(ctx context.Context, project, service, topic string, req aiven.UpdateKafkaTopicRequest) error
	Delete(ctx context.Context, project, service, topic string) error
}

type Manager

type Manager struct {
	AivenTopics Interface
	Project     string
	Service     string
	Topic       kafka_nais_io_v1.Topic
	Logger      *log.Entry
	DryRun      bool
}

func (*Manager) List

func (r *Manager) List(ctx context.Context) ([]*aiven.KafkaListTopic, error)

func (*Manager) Synchronize

func (r *Manager) Synchronize(ctx context.Context) error

type MockInterface

type MockInterface struct {
	mock.Mock
}

MockInterface is an autogenerated mock type for the Interface type

func NewMockInterface

func NewMockInterface(t interface {
	mock.TestingT
	Cleanup(func())
}) *MockInterface

NewMockInterface creates a new instance of MockInterface. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.

func (*MockInterface) Create

func (_m *MockInterface) Create(ctx context.Context, project string, service string, req aiven.CreateKafkaTopicRequest) error

Create provides a mock function with given fields: ctx, project, service, req

func (*MockInterface) Delete

func (_m *MockInterface) Delete(ctx context.Context, project string, service string, topic string) error

Delete provides a mock function with given fields: ctx, project, service, topic

func (*MockInterface) Get

func (_m *MockInterface) Get(ctx context.Context, project string, service string, topic string) (*aiven.KafkaTopic, error)

Get provides a mock function with given fields: ctx, project, service, topic

func (*MockInterface) List

func (_m *MockInterface) List(ctx context.Context, project string, service string) ([]*aiven.KafkaListTopic, error)

List provides a mock function with given fields: ctx, project, service

func (*MockInterface) Update

func (_m *MockInterface) Update(ctx context.Context, project string, service string, topic string, req aiven.UpdateKafkaTopicRequest) error

Update provides a mock function with given fields: ctx, project, service, topic, req

Jump to

Keyboard shortcuts

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