1

对于我的网站,我想存储每个访问者的 IP 地址。我一直在使用 derby+Tomcat 执行此操作,但我不知道如何使用 google appengine 执行此操作。如何将数据插入 appengine 的数据库?我的意思是我如何连接到它的数据库。

我不知道该怎么做。

注意:如果有人用一些代码回答我,那就太好了,告诉我如何连接到数据库以开始发送查询。

4

3 回答 3

1

下面的链接真的是一个很好的介绍指南。您完全不必了解 Google App Engine 数据存储是如何工作的就能够存储/检索数据 + 有一个非常活跃的社区可以为您提供支持。

http://code.google.com/p/objectify-appengine/wiki/IntroductionToObjectify

于 2012-08-02T06:08:56.353 回答
0

与其他 sql 数据库相比,Google 应用引擎的数据存储有点奇怪。它需要相当多的学习。

但是如果你对它不是很感兴趣,那么你可以试试 google 的 fusion tables。它是免费的,并且具有类似 SQL 的查询机制。

它需要对您现有的应用程序稍作修改。注册融合表,然后通过 App Engine 中的融合表 API 存储和访问您的数据。

于 2012-08-03T04:58:47.890 回答
0

First of all, you need to select your interface for connecting to the GAE datastore. Your choices include:

  • the GAE low-level datastore API
  • JPA
  • JDO
  • Objectify
  • Twig

(apologies to any I have missed). Then you need to study the relevant documentation to find out how to use your selected interface.

于 2012-08-01T14:39:13.207 回答