build: golang.org/x/build/app/cache Index | Files

package cache

import "golang.org/x/build/app/cache"

Index

Package Files

cache.go

Variables

var TimeKey = "cachetime"

TimeKey specifies the memcache entity that keeps the logical datastore time.

func Get Uses

func Get(c context.Context, r *http.Request, now uint64, name string, value interface{}) bool

Get fetches data for name at time now from memcache and unmarshals it into value. It reports whether it found the cache record and logs any errors to the admin console.

func Now Uses

func Now(c context.Context) uint64

Now returns the current logical datastore time to use for cache lookups.

func Set Uses

func Set(c context.Context, r *http.Request, now uint64, name string, value interface{})

Set puts value into memcache under name at time now. It logs any errors to the admin console.

func Tick Uses

func Tick(c context.Context) uint64

Tick sets the current logical datastore time to a never-before-used time and returns that time. It should be called to invalidate the cache.

Package cache imports 9 packages (graph) and is imported by 1 packages. Updated 2019-11-15. Refresh now. Tools for package owners.