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

Unified Diff: milo/buildsource/console.go

Issue 2982183002: Milo: Store console defs as their own entities (Closed)
Patch Set: Rebase fixes and Working Created 3 years, 5 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 | « milo/buildsource/buildbot/pubsub_test.go ('k') | milo/common/acl_test.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: milo/buildsource/console.go
diff --git a/milo/buildsource/console.go b/milo/buildsource/console.go
index e8840c3c0f780bc24e7985bb05f30b1f5cada6aa..f38abdb78a0b567ec55a35fa7247554eb9b6ee39 100644
--- a/milo/buildsource/console.go
+++ b/milo/buildsource/console.go
@@ -25,7 +25,7 @@ import (
"github.com/luci/luci-go/common/errors"
"github.com/luci/luci-go/common/sync/parallel"
- "github.com/luci/luci-go/milo/api/config"
+ "github.com/luci/luci-go/milo/common"
"github.com/luci/luci-go/milo/common/model"
)
@@ -41,7 +41,7 @@ type ConsoleRow struct {
// GetConsoleRows returns a row-oriented collection of BuildSummary
// objects. Each row corresponds to the similarly-indexed commit in the
// `commits` slice.
-func GetConsoleRows(c context.Context, project string, console *config.Console, commits, builders []string) ([]*ConsoleRow, error) {
+func GetConsoleRows(c context.Context, project string, console *common.Console, commits, builders []string) ([]*ConsoleRow, error) {
rawCommits := make([][]byte, len(commits))
for i, c := range commits {
var err error
@@ -60,7 +60,7 @@ func GetConsoleRows(c context.Context, project string, console *config.Console,
if console.ManifestName == "REVISION" {
url = ""
}
- partialKey := model.NewPartialManifestKey(project, console.Name, console.ManifestName, url)
+ partialKey := model.NewPartialManifestKey(project, console.ID, console.ManifestName, url)
q := datastore.NewQuery("BuildSummary").KeysOnly(true)
err := parallel.WorkPool(4, func(ch chan<- func() error) {
for i := range rawCommits {
« no previous file with comments | « milo/buildsource/buildbot/pubsub_test.go ('k') | milo/common/acl_test.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698