etl

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: May 31, 2023 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ExecuteContext

type ExecuteContext struct {
	Kfk    *kafkaframe.Kafka
	Loader FullAndDeltaLoader
}

func (ExecuteContext) ExecuteSync

func (s ExecuteContext) ExecuteSync(ctx context.Context) error

type FullAndDeltaLoader

type FullAndDeltaLoader interface {
	fmt.Stringer
	FullSync(ctx context.Context, taskId xid.ID, chbun chan SyncObjer) time.Time
}

type FullSyncContext

type FullSyncContext[T HRGCliModel, R HRModel] struct {
	Fetcher   func(ctx context.Context, ch chan []T)
	Convertor func(hrel T) R
	Builder   func(taskId xid.ID, els []R) SyncObjer
}

func (FullSyncContext[T, R]) FullSync

func (s FullSyncContext[T, R]) FullSync(ctx context.Context, taskId xid.ID, chout chan SyncObjer) time.Time

type HRGCliModel

type HRGCliModel interface {
	GetId() string
}

type HRModel

type HRModel interface {
	IsZero() bool
	GetUpdatedAt() *timestamppb.Timestamp
}

type SyncObjer

type SyncObjer interface {
	HREvent() kafkaemployees.ProtoEvent
	Len() int
	TopicName() string
}

Jump to

Keyboard shortcuts

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