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

Unified Diff: go/src/infra/gae/libs/gae/prod/context.go

Issue 1240573002: Reland: Refactor current GAE abstraction library to be free of the SDK* (Closed) Base URL: https://chromium.googlesource.com/infra/infra.git@master
Patch Set: expand coverage range to fit 32bit test expectations Created 5 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
Index: go/src/infra/gae/libs/gae/prod/context.go
diff --git a/go/src/infra/gae/libs/gae/prod/context.go b/go/src/infra/gae/libs/gae/prod/context.go
new file mode 100644
index 0000000000000000000000000000000000000000..337fce0759f0e41474c56166221a0bbead2aa91c
--- /dev/null
+++ b/go/src/infra/gae/libs/gae/prod/context.go
@@ -0,0 +1,23 @@
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package prod
+
+import (
+ "golang.org/x/net/context"
+)
+
+// Use adds implementations for the following gae interfaces to the
+// context:
+// * gae.RawDatastore
+// * gae.TaskQueue
+// * gae.Memcache
+// * gae.GlobalInfo
+//
+// These can be retrieved with the gae.Get functions.
+//
+// The implementations are all backed by the real appengine SDK functionality,
+func Use(c context.Context) context.Context {
+ return useRDS(useMC(useTQ(useGI(c))))
+}
« no previous file with comments | « go/src/infra/gae/libs/gae/memory/testing_utils_test.go ('k') | go/src/infra/gae/libs/gae/prod/datastore_key.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698