blobdb


JDBC/SQL database engine / database gateway for Google App Engine and other java J2SE and WEB applications.

BlobDB

|13.4.2011|BlobDB Installer and simple user interface for BlobDB implemented| |:--------|:----------------------------------------------------------------| |5.2.2011 |BlobDB "Big Picture" Wiki page added: BlobDB "Big Picture"| |5.2.2011 |BlobDBJ2MEDriver for mobile java applications available for download| |31.1.2011|Release Candidate BlobDB v1.0-RC available for download |

BlobDB is a JDBC/SQL database engine or a gateway to datasource (e.g. datastore, database, files etc.). BlobDB can be used in following modes:

  • As a database server. In this mode BlobDB must be embedded into an Web Application and BlobDB's build in Web Service must be enabled. Also an authentication class which implements WsAuthenticationInterface must be created.
  • As an embedded database in J2SE and Java WEB applications.

BlobDB can store and retrieve actual data from different datasources. These data sources are:

  • Google App Engine datastore
  • File system
  • Memory only (data can be accessed only in runtime and it will be note saved anywhere in this mode)
  • In Gateway mode any datasource you want to access (this one requires programming from you)

In every modes and in every back end types BlobDB will be accessed from user point of view via JDBC driver, WebService client classes or platform specific driver like BlobDBJ2MEDriver, .NET driver or QT cross-platform driver (QT drivers are currently under development).

For more information please visit Wiki pages.

Quick start

For quick start you can download BlobDBInstaller.zip from download section and install BlobDB on Google App Engine with it. After installation you can access BlobDB with simple user interface with your browser.

Below is a picture of BlobDB user interface

http://www.vnetcon.org/images/BlobDBConsoleSmall.png

For more information please visit wiki pages.

BlobDB JDBC driver

BlobDB has three JDBC drivers:

  • For embedded databases BlobDB database includes a build in driver within database jar itself.
  • For java clients BlobDB has a separated client driver. This driver will access BlobDB using BlobDB's Web Service. This driver can be used on Android phones too.
  • For .NET clients there is an ikvmc compiled version of java driver as a .NET library. This driver have been tested and it seems to work ok.

Please note that BlobDB JDBC driver does not support all JDBC features - only the basic features:

  • BlobDB driver can be loaded using DriverManager
  • Statement and PreparedStatement are partially supported
  • ResultSet is partially supported
  • Batch update, which will update multiple updates in one transaction

Features that are not supported will throw a SQLException with "Not implemented!" message.

BlobDB JDBC client driver is build on BlobDB Web Service. The communication is build on URLConnection (java.net) so this should be gae compatible too. Driver has own xml parser for this Web Service so it don't need jaxb libraries or other additional libraries.

BlobDB JDBC driver is very small - only 27 KB.

BlobDB J2ME driver for mobile java applications

BlobDB has a J2ME driver for mobile application. Driver emulates a lot of JDBC driver. To see how to use it please visit Wiki pages.

BlobDB J2ME driver is very small - only 11 KB.

BlobDB Web Service

If you don't want or can't use BlobDB JDBC driver you can also access BlobDB's WebService. You can create client classes against it using wsimport, axis or other "autogenerate webservice client classes" tools. Depending on selected tool these classes might look little bit different but they all should produce you "a statement" (WsStatement) client class which has executeUpdate and executeQuery methods. For these methods you simply give your bSQL statements.

BlobDB bSQL

BlobDB has own sql syntax called bSQL. This syntax emulates a lot of standard sql but it is not and it don't even try to be full implementation of standard sql. For more information of bSQL please look for Wiki pages.

Why not full JDBC/SQL standard?

This is because of the nature of Google App Engine datastore. It is really difficult to write a traditional database against it with database's own indexes, joins, functions and other features. These solutions are usually based on files and Google App Engine doesn't have filesystem - only entities and blobsotre. With blobstore virtual filesystems are quite slow from databases point of view and keeping the file content in sync with all instances of appengine applications is a big question to solve.

Other reason is that Google App Engine doesn't allow socket connections out or in so the only choice to give an interface to world outside of Google App Engine is a Web Service - native tcp/ip connections that jdbc drivers usually use is not possible. This has a big impact on designing database implementation. In BlobDB the implementation has be done so that it is possible to implement a WebService interface for clients running outside Google App Engine - with full jdbc/sql standard support this would be a really complex implementation. Maybe not impossible but at this point we have end up to "almost jdbc/sql standard" implementation. It is as much as possible JDBC/SQL like.

BlobDB status

Current version (BlobDB-v1.0-RC) is the first release candidate of BlobDB. It has been tested against real GAE environment and at least in my opinion it includes now at least the basic features needed to build application using it.

From development point of view all the future development will happen behind JDBC interface and developing bSQL so further changes don't have much impact on developers code using BlobDB.

Using BlobDB in commercial applications?

Please visit at http://www.vnetcon.org. With this we try to be as fair as possible. For us this mean that you give us your price and thats quite much about it :) We think our commercial license more like a donation. Please note that this will apply only if you don't want to deliver your own source code with your application that uses BlobDB.

Project Information

Labels:
JDBC SQL database datastore java symbian meego webservice entity jdo driver j2me android mobile