Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(53)

Unified Diff: perf/go/ingest/main.go

Issue 608273002: Add versioning to perf SQL database (Closed) Base URL: https://skia.googlesource.com/buildbot@master
Patch Set: Incorporating feedback 4 Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « perf/go/db/db_test.go ('k') | perf/go/migratedb/main.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: perf/go/ingest/main.go
diff --git a/perf/go/ingest/main.go b/perf/go/ingest/main.go
index 926ef4851b91c2509c21bd482b80110cea06f4e9..5029bf721de6ad5312aba3cfb42ec02271cadc3d 100644
--- a/perf/go/ingest/main.go
+++ b/perf/go/ingest/main.go
@@ -18,6 +18,7 @@ import (
"github.com/rcrowley/go-metrics"
"skia.googlesource.com/buildbot.git/perf/go/auth"
"skia.googlesource.com/buildbot.git/perf/go/config"
+ "skia.googlesource.com/buildbot.git/perf/go/db"
"skia.googlesource.com/buildbot.git/perf/go/flags"
"skia.googlesource.com/buildbot.git/perf/go/gitinfo"
"skia.googlesource.com/buildbot.git/perf/go/goldingester"
@@ -35,6 +36,7 @@ var (
run = flag.String("run", "nano,nano-trybot,golden", "A comma separated list of ingesters to run.")
graphiteServer = flag.String("graphite_server", "skia-monitoring-b:2003", "Where is Graphite metrics ingestion server running.")
doOauth = flag.Bool("oauth", true, "Run through the OAuth 2.0 flow on startup, otherwise use a GCE service account.")
+ local = flag.Bool("local", false, "Running locally if true. As opposed to in production.")
)
func Init() {
@@ -143,6 +145,9 @@ func main() {
flags.Log()
Init()
+ // Initialize the database. We might not need the oauth dialog if it fails.
+ db.Init(db.ProdConnectionString(*local))
+
var client *http.Client
var err error
if *doOauth {
@@ -156,7 +161,6 @@ func main() {
}
ingester.Init(client)
- trybot.Init()
goldingester.Init()
ts := NewTimestamps(*timestampFile)
ts.Read()
« no previous file with comments | « perf/go/db/db_test.go ('k') | perf/go/migratedb/main.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698