databases

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Jun 13, 2022 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 Mysql

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

Mysql implements the bencher interface.

func NewMySQL

func NewMySQL(host string, port int, user, password string, maxOpenConns int) *Mysql

NewMySQL returns a new mysql bencher.

func (*Mysql) Benchmarks

func (m *Mysql) Benchmarks() []benchmark.Benchmark

Benchmarks returns the individual benchmark functions for the mysql db.

func (*Mysql) Cleanup

func (m *Mysql) Cleanup(closeConnection bool)

Cleanup removes all remaining benchmarking data.

func (*Mysql) Exec

func (m *Mysql) Exec(stmt string)

Exec executes the given statement on the database.

func (*Mysql) ExecStatement

func (m *Mysql) ExecStatement(stmt string)

Exec executes the given statement on the database.

func (*Mysql) ExecTransaction

func (m *Mysql) ExecTransaction(singleStmts []string)

Exec executes the given statement on the database using transactions.

func (*Mysql) Setup

func (m *Mysql) Setup()

Setup initializes the database for the benchmark.

type Neo4j

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

neo4j implements the bencher interface.

func NewNeo4J

func NewNeo4J(host string, port int, user, password string) *Neo4j

NewNeo4J returns a new neo4j bencher.

func (*Neo4j) Benchmarks

func (c *Neo4j) Benchmarks() []benchmark.Benchmark

Benchmarks returns the individual benchmark functions for the cassandra db. TODO: update is not like other db statements balance = balance + balance!

func (*Neo4j) Cleanup

func (c *Neo4j) Cleanup(closeConnection bool)

Cleanup removes all remaining benchmarking data.

func (*Neo4j) Exec

func (n *Neo4j) Exec(stmt string)

Exec executes the given statement on the database.

func (*Neo4j) ExecStatement

func (n *Neo4j) ExecStatement(stmt string)

Exec executes the given statement on the database.

func (*Neo4j) ExecTransaction

func (n *Neo4j) ExecTransaction(singleStmts []string)

Exec executes the given statement on the database using transactions.

func (*Neo4j) Setup

func (c *Neo4j) Setup()

Setup initializes the database for the benchmark.

type Postgres

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

Postgres implements the bencher interface.

func NewPostgres

func NewPostgres(host string, port int, user, password string, maxOpenConns int) *Postgres

NewPostgres returns a new postgres bencher.

func (*Postgres) Benchmarks

func (p *Postgres) Benchmarks() []benchmark.Benchmark

Benchmarks returns the individual benchmark statements for the postgres db.

func (*Postgres) Cleanup

func (p *Postgres) Cleanup(closeConnection bool)

Cleanup removes all remaining benchmarking data.

func (*Postgres) Exec

func (p *Postgres) Exec(stmt string)

Exec executes the given statement on the database.

func (*Postgres) ExecStatement

func (p *Postgres) ExecStatement(stmt string)

Exec executes the given statement on the database.

func (*Postgres) ExecTransaction

func (p *Postgres) ExecTransaction(singleStmts []string)

Exec executes the given statement on the database using transactions.

func (*Postgres) Setup

func (p *Postgres) Setup()

Setup initializes the database for the benchmark.

Jump to

Keyboard shortcuts

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