Ejemplo n.º 1
0
func createCache(req *wcg.Request, kind *Kind, cache *memcache.Driver, ent interface{}, keys ...string) {
	if err := cache.SetMulti(keys, ent); err != nil {
		req.Logger.Warnf("[%s] Could not create into cache (keys=%v): %v", kind, err, keys)
	} else {
		req.Logger.Debugf("[%s] Entities created into cache (keys=%v)", kind, keys)
	}
}