如何在 Google App Engine (Java) 中启用会话支持?

发布于 2024-10-06 04:16:54 字数 131 浏览 0 评论 0原文

如何使用 Java 启用 GAE 会话支持?

另外,还有一个相关问题:我只想在会话中存储少量状态(基本上只是一个密钥)——GAE 是否会将这些信息存储在客户端 cookie 中,如果是,这种方法的安全性如何?

谢谢!

How do I enable GAE session support using Java?

Also, a related question: I only want to store a small amount of state in sessions (basically, just a key) -- will GAE store this information in a client-side cookie, and if so, how secure is that approach?

Thanks!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

荒岛晴空 2024-10-13 04:16:54

对于第一个问题。在您的 appengine-web.xml 中包含:

<?xml version="1.0" encoding="utf-8"?>
<appengine-web-app xmlns="http://appengine.google.com/ns/1.0">
  ...
  <sessions-enabled>true</sessions-enabled>
</appengine-web-app>

For the first question. In your appengine-web.xml have:

<?xml version="1.0" encoding="utf-8"?>
<appengine-web-app xmlns="http://appengine.google.com/ns/1.0">
  ...
  <sessions-enabled>true</sessions-enabled>
</appengine-web-app>
羁客 2024-10-13 04:16:54

请参阅 appengine-web.xml 中的注释中提供的此链接:

http://code.google.com/appengine/docs/java/config/appconfig.html#Enabling_Sessions

Please refer this Link provided by in comments in appengine-web.xml:

http://code.google.com/appengine/docs/java/config/appconfig.html#Enabling_Sessions

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文