tasks

package
v0.0.0-...-d3e11eb Latest Latest
Warning

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

Go to latest
Published: Nov 21, 2019 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MaxUid = 3300000
)
View Source
const (
	TypePerson = iota
)

Variables

View Source
var (
	BenchTasks = map[string]BenchmarkCase{}
)

Functions

func ExecTask

func ExecTask(name string, bc BenchmarkCase, dgraphCli *dgo.Dgraph, concurrency int)

func GetFriendsOneHop

func GetFriendsOneHop(dgraphCli *dgo.Dgraph) error

func GetFriendsTwoHop

func GetFriendsTwoHop(dgraphCli *dgo.Dgraph) error

func InsertFriend

func InsertFriend(dgraphCli *dgo.Dgraph) error

func InsertPerson

func InsertPerson(dgraphCli *dgo.Dgraph) error

func RandString

func RandString(n int) string

func StartPrometheusServer

func StartPrometheusServer(port int)

Types

type BenchmarkCase

type BenchmarkCase func(dgraphCli *dgo.Dgraph) error

type Person

type Person struct {
	Uid       string  `json:"uid,omitempty"`
	Name      string  `json:"name,omitempty"`
	Xid       string  `json:"xid,omitempty"`
	Type      int     `json:"type,omitempty"`
	CreatedAt int64   `json:"created_at,omitempty"`
	UpdatedAt int64   `json:"updated_at,omitempty"`
	FriendOf  *Person `json:"friend_of,omitempty"`
}

Jump to

Keyboard shortcuts

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