gorm

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Mar 19, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GormStore

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

func New

func New(opts ...Option) (*GormStore, error)

New creates a new GormStore

func (*GormStore) Flush

func (s *GormStore) Flush() (int, error)

Flush flushes datas to storage

func (*GormStore) Save

func (s *GormStore) Save(datas ...collector.OutputData) error

Save saves datas to GormStore

type Option

type Option func(opts *options)

func WithBatchCount

func WithBatchCount(batchCount int) Option

func WithLogger

func WithLogger(logger *zap.Logger) Option

func WithSqlUrl

func WithSqlUrl(sqlUrl string) Option

Jump to

Keyboard shortcuts

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