Skip to content

Commit

Permalink
tapdb: universe db query re-write and index performance tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jbrill committed Nov 20, 2024
1 parent 5c0db9d commit 2d408d9
Show file tree
Hide file tree
Showing 4 changed files with 494 additions and 0 deletions.
5 changes: 5 additions & 0 deletions make/testing_flags.mk
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,11 @@ ifeq ($(dbbackend),postgres)
DEV_TAGS += test_db_postgres
endif

# Run universe tests with increased scale for performance testing.
ifneq ($(long-tests),)
DEV_TAGS += longtests
endif

ifneq ($(tags),)
DEV_TAGS += ${tags}
endif
Expand Down
13 changes: 13 additions & 0 deletions tapdb/universe_perf_long_test.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
//go:build longtests

package tapdb

// longTestScale is the scale factor for long tests.
const longTestScale = 5

var (
numAssets = 100 * longTestScale
numLeavesPerTree = 300 * longTestScale
numEventsPerAsset = 100 * longTestScale
numQueries = 100 * longTestScale
)
10 changes: 10 additions & 0 deletions tapdb/universe_perf_short_test.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
//go:build !longtests

package tapdb

var (
numAssets = 100
numLeavesPerTree = 300
numEventsPerAsset = 100
numQueries = 100
)
Loading

0 comments on commit 2d408d9

Please sign in to comment.