“会议"使用 Google Cloud Endpoints [英] "Sessions" with Google Cloud Endpoints

查看:29
本文介绍了“会议"使用 Google Cloud Endpoints的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这个问题只是为了确认我对这个概念很清楚.

This question is only to confirm that I'm clear about this concept.

据我所知,Google Cloud Endpoints 是 Google 对 REST 服务的一种实现,因此它们无法在内存中保留任何会话"数据,因此:

As far as I understand, Google Cloud Endpoints are kind of Google's implementation of REST services, so that they can't keep any "session" data in memory, therefore:

  • 用户必须随每个请求发送身份验证数据.
  • 我想稍后使用的所有数据必须被持久化,也就是说,对于我收到的每个 API 请求,我必须访问数据存储区,做一些事情并再次存储数据.
  • Users must send authentication data with each request.
  • All the data I want to use later on must be persisted, namely, with each API request I receive, I have to access the Datastore, do something and store the data again.

这是正确的吗?如果是这样,这在性能方面真的好吗?

Is this correct? And if so, is this actually good in terms of performance?

推荐答案

数据存储非常快,尤其是在您进行键查找(与查询相称)时.如果您使用 NDB,那么您将获得自动 memache 查找的好处.

The datastore is pretty quick especially if you do a key lookup (as apposed to query). if you use NDB then you will have the benefit of auto memache your lookups.

这篇关于“会议"使用 Google Cloud Endpoints的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆