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

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

Issue 813443002: Overhaul database package (Closed) Base URL: https://skia.googlesource.com/buildbot@master
Patch Set: Comments/readme cleanup Created 6 years 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
Index: perf/go/perf_migratedb/main.go
diff --git a/perf/go/perf_migratedb/main.go b/perf/go/perf_migratedb/main.go
index 28021f775cded8709969db6f50607c7216bced02..09c5139f75e4eab1e2b3b6900062c409a7ed2981 100644
--- a/perf/go/perf_migratedb/main.go
+++ b/perf/go/perf_migratedb/main.go
@@ -18,14 +18,15 @@ import (
)
func main() {
- common.Init()
- defaultConnStr := strings.Replace(db.DB_CONN_TMPL, "%s", "root", 1)
+ defaultConnStr := fmt.Sprintf(database.DB_CONN_TMPL, database.USER_ROOT, "%s", db.PROD_DB_HOST, db.PROD_DB)
// flags
dbConnString := flag.String("db_conn_string", defaultConnStr, "\n\tDatabase string to open connect to the MySQL database. "+
"\n\tNeeds to follow the format of the golang-mysql driver (https://github.com/go-sql-driver/mysql."+
"\n\tIf the string contains %s the user will be prompted to enter a password which will then be used for subtitution.")
+ common.Init()
+
var connectionStr = *dbConnString
// if it contains formatting information read the password from stdin.
« go/buildbot/db.go ('K') | « perf/go/ingest/main.go ('k') | perf/go/skiaperf/main.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698