mirror of
https://github.com/cirruslabs/tart.git
synced 2026-09-30 03:01:12 +02:00
Introduce Golang-based benchmarking utility (#769)
* Introduce Golang-based benchmarking utility * benchmark fio: properly configure logger level * benchmark: properly terminate on Ctrl+C when initializing/running Tart * benchmark(fio): increase runtime to 30 seconds * benchmark(fio): IOPS are already per second * benchmark(fio): --numjobs 1 --iodepth 1 --end_fsync 1 * benchmark(README.md): add results
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"context"
|
||||
"github.com/cirruslabs/tart/benchmark/internal/command"
|
||||
"log"
|
||||
"os"
|
||||
"os/signal"
|
||||
)
|
||||
|
||||
func main() {
|
||||
// Set up a signal-interruptible context
|
||||
ctx, cancel := signal.NotifyContext(context.Background(), os.Interrupt)
|
||||
|
||||
// Run the root command
|
||||
if err := command.NewCommand().ExecuteContext(ctx); err != nil {
|
||||
cancel()
|
||||
|
||||
log.Fatal(err)
|
||||
}
|
||||
|
||||
cancel()
|
||||
}
|
||||
Reference in New Issue
Block a user