cassandra

package
v0.0.0-...-b673533 Latest Latest
Warning

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

Go to latest
Published: Jul 27, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CassandraQueryPool sync.Pool = sync.Pool{
	New: func() interface{} {
		return &CassandraQuery{
			HumanLabel:       []byte{},
			HumanDescription: []byte{},
			MeasurementName:  []byte{},
			FieldName:        []byte{},
			AggregationType:  []byte{},
			TagsCondition:    []byte{},
		}
	},
}

Functions

func NewCassandraDevops8Hosts

func NewCassandraDevops8Hosts(dbConfig bulkQuerygen.DatabaseConfig, queriesFullRange bulkQuerygen.TimeInterval, queryInterval time.Duration, scaleVar int) bulkQuerygen.QueryGenerator

func NewCassandraDevopsGroupBy

func NewCassandraDevopsGroupBy(dbConfig bulkQuerygen.DatabaseConfig, queriesFullRange bulkQuerygen.TimeInterval, queryInterval time.Duration, scaleVar int) bulkQuerygen.QueryGenerator

func NewCassandraDevopsSingleHost

func NewCassandraDevopsSingleHost(dbConfig bulkQuerygen.DatabaseConfig, queriesFullRange bulkQuerygen.TimeInterval, queryInterval time.Duration, scaleVar int) bulkQuerygen.QueryGenerator

func NewCassandraDevopsSingleHost12hr

func NewCassandraDevopsSingleHost12hr(dbConfig bulkQuerygen.DatabaseConfig, queriesFullRange bulkQuerygen.TimeInterval, queryInterval time.Duration, scaleVar int) bulkQuerygen.QueryGenerator

func NewCassandraIotSingleHost

func NewCassandraIotSingleHost(dbConfig bulkQuerygen.DatabaseConfig, queriesFullRange bulkQuerygen.TimeInterval, queryInterval time.Duration, scaleVar int) bulkQuerygen.QueryGenerator

Types

type CassandraDevops

type CassandraDevops struct {
	bulkQuerygen.CommonParams
	KeyspaceName string
}

CassandraDevops produces Cassandra-specific queries for all the devops query types.

func (*CassandraDevops) Dispatch

func (d *CassandraDevops) Dispatch(i int) bulkQuerygen.Query

Dispatch fulfills the QueryGenerator interface.

func (*CassandraDevops) MaxCPUUsage12HoursByMinuteOneHost

func (d *CassandraDevops) MaxCPUUsage12HoursByMinuteOneHost(q bulkQuerygen.Query)

func (*CassandraDevops) MaxCPUUsageHourByMinuteEightHosts

func (d *CassandraDevops) MaxCPUUsageHourByMinuteEightHosts(q bulkQuerygen.Query)

func (*CassandraDevops) MaxCPUUsageHourByMinuteFourHosts

func (d *CassandraDevops) MaxCPUUsageHourByMinuteFourHosts(q bulkQuerygen.Query)

func (*CassandraDevops) MaxCPUUsageHourByMinuteOneHost

func (d *CassandraDevops) MaxCPUUsageHourByMinuteOneHost(q bulkQuerygen.Query)

func (*CassandraDevops) MaxCPUUsageHourByMinuteSixteenHosts

func (d *CassandraDevops) MaxCPUUsageHourByMinuteSixteenHosts(q bulkQuerygen.Query)

func (*CassandraDevops) MaxCPUUsageHourByMinuteThirtyTwoHosts

func (d *CassandraDevops) MaxCPUUsageHourByMinuteThirtyTwoHosts(q bulkQuerygen.Query)

func (*CassandraDevops) MaxCPUUsageHourByMinuteTwoHosts

func (d *CassandraDevops) MaxCPUUsageHourByMinuteTwoHosts(q bulkQuerygen.Query)

func (*CassandraDevops) MeanCPUUsageDayByHourAllHostsGroupbyHost

func (d *CassandraDevops) MeanCPUUsageDayByHourAllHostsGroupbyHost(qi bulkQuerygen.Query)

MeanCPUUsageDayByHourAllHosts populates a Query with a query that looks like: SELECT mean(usage_user) from cpu where time >= '$DAY_START' and time < '$DAY_END' group by time(1h),hostname

type CassandraDevops8Hosts

type CassandraDevops8Hosts struct {
	CassandraDevops
}

CassandraDevops8Hosts produces Cassandra-specific queries for the devops groupby case.

func (*CassandraDevops8Hosts) Dispatch

type CassandraDevopsGroupby

type CassandraDevopsGroupby struct {
	CassandraDevops
}

CassandraDevopsGroupby produces Cassandra-specific queries for the devops groupby case.

func (*CassandraDevopsGroupby) Dispatch

type CassandraDevopsSingleHost

type CassandraDevopsSingleHost struct {
	CassandraDevops
}

CassandraDevopsSingleHost produces Cassandra-specific queries for the devops single-host case.

func (*CassandraDevopsSingleHost) Dispatch

type CassandraDevopsSingleHost12hr

type CassandraDevopsSingleHost12hr struct {
	CassandraDevops
}

CassandraDevopsSingleHost12hr produces Cassandra-specific queries for the devops single-host case.

func (*CassandraDevopsSingleHost12hr) Dispatch

type CassandraIot

type CassandraIot struct {
	bulkQuerygen.CommonParams
	KeyspaceName string
}

CassandraIot produces Cassandra-specific queries for all the devops query types.

func (*CassandraIot) AverageTemperatureDayByHourOneHome

func (d *CassandraIot) AverageTemperatureDayByHourOneHome(q bulkQuerygen.Query)

func (*CassandraIot) Dispatch

func (d *CassandraIot) Dispatch(i int) bulkQuerygen.Query

Dispatch fulfills the QueryGenerator interface.

type CassandraIotSingleHost

type CassandraIotSingleHost struct {
	CassandraIot
}

CassandraIotSingleHost produces Cassandra-specific queries for the devops single-host case.

func (*CassandraIotSingleHost) Dispatch

type CassandraQuery

type CassandraQuery struct {
	HumanLabel       []byte
	HumanDescription []byte

	MeasurementName []byte // e.g. "cpu"
	FieldName       []byte // e.g. "usage_user"
	AggregationType []byte // e.g. "avg" or "sum". used literally in the cassandra query.
	TimeStart       time.Time
	TimeEnd         time.Time
	GroupByDuration time.Duration
	TagsCondition   []byte
}

CassandraQuery encodes a Cassandra request. This will be serialized for use by the query_benchmarker program.

func NewCassandraQuery

func NewCassandraQuery() *CassandraQuery

func (*CassandraQuery) HumanDescriptionName

func (q *CassandraQuery) HumanDescriptionName() []byte

func (*CassandraQuery) HumanLabelName

func (q *CassandraQuery) HumanLabelName() []byte

func (*CassandraQuery) Release

func (q *CassandraQuery) Release()

func (*CassandraQuery) String

func (q *CassandraQuery) String() string

String produces a debug-ready description of a Query.

Jump to

Keyboard shortcuts

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