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

Unified Diff: common/prpc/talk/buildbot/frontend/prpc.go

Issue 2043423004: Make HTTP middleware easier to use (Closed) Base URL: https://github.com/luci/luci-go@master
Patch Set: gaemiddleware: add middleware func for WithProd Created 4 years, 6 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 | « common/prpc/talk/buildbot/frontend/handler.go ('k') | common/prpc/talk/helloworld/frontend/handler.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: common/prpc/talk/buildbot/frontend/prpc.go
diff --git a/common/prpc/talk/buildbot/frontend/prpc.go b/common/prpc/talk/buildbot/frontend/prpc.go
index a3c6f5b1963ddbfd47252d34feb2c793c127c283..c7ee910e68d8a5e4df93d556214bd4a494473d61 100644
--- a/common/prpc/talk/buildbot/frontend/prpc.go
+++ b/common/prpc/talk/buildbot/frontend/prpc.go
@@ -1,22 +1,20 @@
// Copyright 2016 The LUCI Authors. All rights reserved.
// Use of this source code is governed under the Apache License, Version 2.0
// that can be found in the LICENSE file.
package buildbot
import (
- "github.com/julienschmidt/httprouter"
-
"github.com/luci/luci-go/server/discovery"
- "github.com/luci/luci-go/server/middleware"
"github.com/luci/luci-go/server/prpc"
+ "github.com/luci/luci-go/server/router"
"github.com/luci/luci-go/common/prpc/talk/buildbot/proto"
)
-func InstallAPIRoutes(router *httprouter.Router, base middleware.Base) {
+func InstallAPIRoutes(r *router.Router, base router.MiddlewareChain) {
server := &prpc.Server{}
buildbot.RegisterBuildbotServer(server, &buildbotService{})
discovery.Enable(server)
- server.InstallHandlers(router, base)
+ server.InstallHandlers(r, base)
}
« no previous file with comments | « common/prpc/talk/buildbot/frontend/handler.go ('k') | common/prpc/talk/helloworld/frontend/handler.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698