Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 9 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,8 @@ scripts). The easiest way to get and install the Go programs is to use
`go get` and then `make all` to install all binaries:
```bash
# Fetch TSBS and its dependencies
$ go get github.com/timescale/tsbs
$ cd $GOPATH/src/github.com/timescale/tsbs
$ go get github.com/questdb/tsbs
$ cd $GOPATH/src/github.com/questdb/tsbs
$ make
```

Expand Down Expand Up @@ -413,12 +413,12 @@ the results.
### Devops / cpu-only
|Query type|Description|
|:---|:---|
|single-groupby-1-1-1| Simple aggregrate (MAX) on one metric for 1 host, every 5 mins for 1 hour
|single-groupby-1-1-12| Simple aggregrate (MAX) on one metric for 1 host, every 5 mins for 12 hours
|single-groupby-1-8-1| Simple aggregrate (MAX) on one metric for 8 hosts, every 5 mins for 1 hour
|single-groupby-5-1-1| Simple aggregrate (MAX) on 5 metrics for 1 host, every 5 mins for 1 hour
|single-groupby-5-1-12| Simple aggregrate (MAX) on 5 metrics for 1 host, every 5 mins for 12 hours
|single-groupby-5-8-1| Simple aggregrate (MAX) on 5 metrics for 8 hosts, every 5 mins for 1 hour
|single-groupby-1-1-1| Simple aggregate (MAX) on one metric for 1 host, every 5 mins for 1 hour
|single-groupby-1-1-12| Simple aggregate (MAX) on one metric for 1 host, every 5 mins for 12 hours
|single-groupby-1-8-1| Simple aggregate (MAX) on one metric for 8 hosts, every 5 mins for 1 hour
|single-groupby-5-1-1| Simple aggregate (MAX) on 5 metrics for 1 host, every 5 mins for 1 hour
|single-groupby-5-1-12| Simple aggregate (MAX) on 5 metrics for 1 host, every 5 mins for 12 hours
|single-groupby-5-8-1| Simple aggregate (MAX) on 5 metrics for 8 hosts, every 5 mins for 1 hour
|cpu-max-all-1| Aggregate across all CPU metrics per hour over 1 hour for a single host
|cpu-max-all-8| Aggregate across all CPU metrics per hour over 1 hour for eight hosts
|double-groupby-1| Aggregate on across both time and host, giving the average of 1 CPU metric per host per hour for 24 hours
Expand Down Expand Up @@ -450,11 +450,6 @@ the results.
We welcome contributions from the community to make TSBS better!

You can help either by opening an
[issue](https://github.com/timescale/tsbs/issues) with
[issue](https://github.com/questdb/tsbs/issues) with
any suggestions or bug reports, or by forking this repository,
making your own contribution, and submitting a pull request.

Before we accept any contributions, Timescale contributors need to
sign the [Contributor License Agreement](https://cla-assistant.io/timescale/tsbs) (CLA).
By signing a CLA, we can ensure that the community is free and confident in its
ability to use your contributions.
12 changes: 7 additions & 5 deletions cmd/tsbs_generate_data/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@

// Supported use cases:
// devops: scale is the number of hosts to simulate, with log messages
// every log-interval seconds.
//
// every log-interval seconds.
//
// cpu-only: same as `devops` but only generate metrics for CPU
package main

Expand All @@ -22,11 +24,11 @@ import (
"runtime/pprof"

"github.com/blagojts/viper"
"github.com/questdb/tsbs/internal/inputs"
"github.com/questdb/tsbs/internal/utils"
"github.com/questdb/tsbs/pkg/data/usecases/common"
"github.com/questdb/tsbs/pkg/targets/initializers"
"github.com/spf13/pflag"
"github.com/timescale/tsbs/internal/inputs"
"github.com/timescale/tsbs/internal/utils"
"github.com/timescale/tsbs/pkg/data/usecases/common"
"github.com/timescale/tsbs/pkg/targets/initializers"
)

var (
Expand Down
6 changes: 3 additions & 3 deletions cmd/tsbs_generate_queries/databases/akumuli/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ package akumuli
import (
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/cmd/tsbs_generate_queries/utils"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/utils"
"github.com/questdb/tsbs/pkg/query"
)

// BaseGenerator contains settings specific for Akumuli database.
Expand Down
4 changes: 2 additions & 2 deletions cmd/tsbs_generate_queries/databases/akumuli/devops.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import (
"fmt"
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/pkg/query"
)

// Devops produces Influx-specific queries for all the devops query types.
Expand Down
8 changes: 4 additions & 4 deletions cmd/tsbs_generate_queries/databases/cassandra/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ import (
"strings"
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/cmd/tsbs_generate_queries/utils"
internalutils "github.com/timescale/tsbs/internal/utils"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/utils"
internalutils "github.com/questdb/tsbs/internal/utils"
"github.com/questdb/tsbs/pkg/query"
)

// BaseGenerator contains settings specific for Cassandra database.
Expand Down
6 changes: 3 additions & 3 deletions cmd/tsbs_generate_queries/databases/cassandra/devops.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@ import (
"fmt"
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/internal/utils"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/internal/utils"
"github.com/questdb/tsbs/pkg/query"
)

// TODO: Remove the need for this by continuing to bubble up errors
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"testing"
"time"

"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/pkg/query"
)

func TestDevopsGetHostWhereWithHostnames(t *testing.T) {
Expand Down
6 changes: 3 additions & 3 deletions cmd/tsbs_generate_queries/databases/clickhouse/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ package clickhouse
import (
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/cmd/tsbs_generate_queries/utils"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/utils"
"github.com/questdb/tsbs/pkg/query"
)

// BaseGenerator contains settings specific for ClickHouse.
Expand Down
20 changes: 12 additions & 8 deletions cmd/tsbs_generate_queries/databases/clickhouse/devops.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"strings"
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/pkg/query"
)

// TODO: Remove the need for this by continuing to bubble up errors
Expand Down Expand Up @@ -76,9 +76,11 @@ const clickhouseTimeStringFormat = "2006-01-02 15:04:05"
// SELECT MAX(metric1), ..., MAX(metricN)
// FROM cpu
// WHERE
// (hostname = '$HOSTNAME_1' OR ... OR hostname = '$HOSTNAME_N')
// AND time >= '$HOUR_START'
// AND time < '$HOUR_END'
//
// (hostname = '$HOSTNAME_1' OR ... OR hostname = '$HOSTNAME_N')
// AND time >= '$HOUR_START'
// AND time < '$HOUR_END'
//
// GROUP BY hour
// ORDER BY hour
//
Expand Down Expand Up @@ -290,9 +292,11 @@ func (d *Devops) LastPointPerHost(qi query.Query) {
// SELECT minute, max(metric1), ..., max(metricN)
// FROM cpu
// WHERE
// (hostname = '$HOSTNAME_1' OR ... OR hostname = '$HOSTNAME_N')
// AND time >= '$HOUR_START'
// AND time < '$HOUR_END'
//
// (hostname = '$HOSTNAME_1' OR ... OR hostname = '$HOSTNAME_N')
// AND time >= '$HOUR_START'
// AND time < '$HOUR_END'
//
// GROUP BY minute
// ORDER BY minute ASC
//
Expand Down
4 changes: 2 additions & 2 deletions cmd/tsbs_generate_queries/databases/clickhouse/devops_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import (
"testing"
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/pkg/query"
)

func TestDevopsGetHostWhereWithHostnames(t *testing.T) {
Expand Down
6 changes: 3 additions & 3 deletions cmd/tsbs_generate_queries/databases/cratedb/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ package cratedb
import (
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/cmd/tsbs_generate_queries/utils"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/utils"
"github.com/questdb/tsbs/pkg/query"
)

// BaseGenerator contains settings specific for CrateDB
Expand Down
4 changes: 2 additions & 2 deletions cmd/tsbs_generate_queries/databases/cratedb/devops.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"strings"
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/pkg/query"
)

// TODO: Remove the need for this by continuing to bubble up errors
Expand Down
4 changes: 2 additions & 2 deletions cmd/tsbs_generate_queries/databases/cratedb/devops_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import (
"testing"
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/pkg/query"
)

const testScale = 10
Expand Down
8 changes: 4 additions & 4 deletions cmd/tsbs_generate_queries/databases/influx/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ import (
"net/url"
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/iot"
"github.com/timescale/tsbs/cmd/tsbs_generate_queries/utils"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/iot"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/utils"
"github.com/questdb/tsbs/pkg/query"
)

// BaseGenerator contains settings specific for Influx database.
Expand Down
6 changes: 3 additions & 3 deletions cmd/tsbs_generate_queries/databases/influx/devops.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ import (
"strings"
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/databases"
"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/databases"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/pkg/query"
)

// Devops produces Influx-specific queries for all the devops query types.
Expand Down
4 changes: 2 additions & 2 deletions cmd/tsbs_generate_queries/databases/influx/devops_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ import (
"testing"
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/pkg/query"
)

func TestDevopsGetHostWhereWithHostnames(t *testing.T) {
Expand Down
6 changes: 3 additions & 3 deletions cmd/tsbs_generate_queries/databases/influx/iot.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ import (
"strings"
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/databases"
"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/iot"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/databases"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/iot"
"github.com/questdb/tsbs/pkg/query"
)

// IoT produces Influx-specific queries for all the iot query types.
Expand Down
2 changes: 1 addition & 1 deletion cmd/tsbs_generate_queries/databases/influx/iot_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"testing"
"time"

"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/pkg/query"
)

const (
Expand Down
6 changes: 3 additions & 3 deletions cmd/tsbs_generate_queries/databases/mongo/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ package mongo
import (
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/cmd/tsbs_generate_queries/utils"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/utils"
"github.com/questdb/tsbs/pkg/query"
)

// BaseGenerator contains settings specific for Mongo database.
Expand Down
4 changes: 2 additions & 2 deletions cmd/tsbs_generate_queries/databases/mongo/devops-naive.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import (
"time"

"github.com/globalsign/mgo/bson"
"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/pkg/query"
)

func init() {
Expand Down
6 changes: 3 additions & 3 deletions cmd/tsbs_generate_queries/databases/mongo/devops.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ import (
"time"

"github.com/globalsign/mgo/bson"
"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/internal/utils"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/internal/utils"
"github.com/questdb/tsbs/pkg/query"
)

// TODO: Remove the need for this by continuing to bubble up errors
Expand Down
6 changes: 3 additions & 3 deletions cmd/tsbs_generate_queries/databases/questdb/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ import (
"net/url"
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/cmd/tsbs_generate_queries/utils"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/utils"
"github.com/questdb/tsbs/pkg/query"
)

// BaseGenerator contains settings specific for QuestDB
Expand Down
4 changes: 2 additions & 2 deletions cmd/tsbs_generate_queries/databases/questdb/devops.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"strings"
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/pkg/query"
)

// TODO: Remove the need for this by continuing to bubble up errors
Expand Down
4 changes: 2 additions & 2 deletions cmd/tsbs_generate_queries/databases/questdb/devops_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import (
"testing"
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/pkg/query"
)

func TestDevopsGroupByTime(t *testing.T) {
Expand Down
6 changes: 3 additions & 3 deletions cmd/tsbs_generate_queries/databases/siridb/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ package siridb
import (
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/cmd/tsbs_generate_queries/utils"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/utils"
"github.com/questdb/tsbs/pkg/query"
)

// BaseGenerator contains settings specific for SiriDB
Expand Down
4 changes: 2 additions & 2 deletions cmd/tsbs_generate_queries/databases/siridb/devops.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"strings"
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/pkg/query"
)

// TODO: Remove the need for this by continuing to bubble up errors
Expand Down
4 changes: 2 additions & 2 deletions cmd/tsbs_generate_queries/databases/siridb/devops_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"testing"
"time"

"github.com/timescale/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/timescale/tsbs/pkg/query"
"github.com/questdb/tsbs/cmd/tsbs_generate_queries/uses/devops"
"github.com/questdb/tsbs/pkg/query"
)

func TestDevopsGetHostWhereWithHostnames(t *testing.T) {
Expand Down
Loading