怎么在App Engine中使用JDBC?

jiql是一款用于Google App Engine (GAE) 的JDBC包装器,使Java应用能够通过标准JDBC接口访问GAE的数据存储。尽管GAE目前主要支持JDO和JPA,但jiql为习惯使用JDBC的开发者提供了便利。借助jiql,开发者可以利用Google BigTable进行数据持久化。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

jiql是一个在App Engine上使用的JDBC包装器,使用它可以让我们的Java程序在GAE上支持JDBC访问。

以下是管方教程,来自于http://www.jiql.org/xwiki/bin/view/Main/

jiql is a Java JDBC wrapper for Cloud computing databases. The database is accessed via the jiql jdbc client. The data is actually stored in a cloud-baseddata store, such as Google's BigTable .

http://www.jiql.org/xwiki/resources/diagram.png


The fact is Google App Engine for Java at present only supports JDO and JPA as standard protocols for data persistence. However many Java programmers are used to JDBC as the preferred protocol. Applications requiring JDBC support can now turn to jiql. jiql is a JDBC wrapper of the lower level Google DataStore APIs thus providing a familiar way to utilize Google's BigTable.

So a Java application, using standard JDBC calls to the jiql JDBC client, is able to store critical data in GBT. As the DataStore sits in the cloud, you essentially have a solution for distributed database access.

FEATURES HIGHLIGHTS : JDBC . SQL . REMOTE ACCESS
Run PHP with jiql on GAE new
Run JRuby-on-RAILS with jiql on GAE new

How to start

jiql is in its early stages of Development. (We put out a new build almost daily).The present release is 0.1.44 (08/14/2009 ) . Not all features have been implemented as yet. Below are the steps to try out jiql :

  • Download jiql.jar java database engine and driver library and place under WEB-INF/lib/
  • Download jiql.jsp JSP file and place under ./ of your java application.
  • NOTE : The appengine-api.jar must also be placed under WEB-INF/lib. This file comes with the GAE SDK.
  • Edit jiql.jsp accordingly.
  • Test jiql with the jiql.jsp

Or test with the jdbc-guestbook application. The jdbc-guestbook application is a

JDBC based version of the Google Guestbook application.
Download jdbc-guestbook.war here . When installed, you must first call
init.jsp. This will create the "Greeting" table. When this step is completed,
you may then browse guestbook.jsp.
For the jdbc-guestbook source code, you may download jdbc-guestbook.src.zip here .

(NOTE for those folks without a GAE-for-JAVA account, you can download the GAE JAVA SDK and use as a test environment)

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值