movie

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2022 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	DBName           string
	DropTables       bool
	UserCount        uint
	PersonCount      uint
	MovieCount       uint
	RatingCount      uint
	MaxStarsPerMovie uint
}

Config is the configuration for movie demo workload.

type Workloader

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

Workloader is movie demo workload.

func NewWorkloader

func NewWorkloader(db *sql.DB, cfg Config) (*Workloader, error)

func (*Workloader) Cleanup

func (w *Workloader) Cleanup(ctx context.Context) error

func (*Workloader) CleanupThread

func (w *Workloader) CleanupThread(ctx context.Context)

CleanupThread implements Workloader interface.

func (*Workloader) DBName

func (w *Workloader) DBName() string

func (*Workloader) InitThread

func (w *Workloader) InitThread(ctx context.Context) context.Context

InitThread inits thread.

func (*Workloader) Name

func (w *Workloader) Name() string

func (*Workloader) Prepare

func (w *Workloader) Prepare(ctx context.Context) error

Prepare implements Workloader interface.

func (*Workloader) Run

func (w *Workloader) Run(ctx context.Context) error

Jump to

Keyboard shortcuts

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