IMPORTANT: This project is undergoing significant changes and is not ready for use.
The SQL Layer is being currently in development for use with FoundationDB. A local B-Tree is currently the default storage and is only for experimental purposes.
Please watch this repo or sign up at https://foundationdb.com/layers/sql to be informed when the SQL Layer is ready for general use.
The FoundationDB SQL layer is a full SQL implementation that builds on FoundationDB’s core features. It gets the same high performance, multi-node scalability, fault-tolerance, and true multi-key ACID transactions while also providing new capabilities, including a sophisticated SQL environment and direct object access.
It was written from the ground up in Java and utilizes the FoundationDB SQL Parser.
The FoundationDB SQL Layer requires Java 7 Runtime Environment and FoundationDB.
The FoundationDB SQL Layer requires the Java 7 Runtime Environment (JRE). Both OpenJDK JRE and the official Oracle JRE are supported. For production deployments, we recommend the Oracle JRE.
See the Oracle Java SE Downloads page for installation details.
To install FoundationDB, follow the official Getting Started guides, being sure to check that the cluster is up and running (covered in Testing your FoundationDB installation).
The SQL Layer can be installed from system packages (appropriate for most people) or directly from source (intended for developers).
Official packages for Windows, OS X, Ubuntu and CentOS/RedHat are available. See Getting Started - Installing the SQL Layer for more details.
A single instance of the SQL Layer is installed by default and is appropriate for local development. Consult the documentation for recommended multi-node configurations.
Note: This section is intended only for developers.
Use Maven to build the project:
$ mvn package
All unit and integration tests will be run by default, which could be lengthy.
Test execution can be avoided with the skipTests
option:
$ mvn package -DskipTests=true
An executable jar, and required dependencies, will be the target/
directory
once packaging is complete.
The server can then be started with the fdbsqllayer
script. The -f
flag
will run it in the foreground:
$ ./bin/fdbsqllayer -f
A handful of informational messages will print and then the server will state it is ready:
2013-03-22 15:36:29,561 [main] INFO ServiceManager - FoundationDB SQL Layer ready.
When installing from source, you'll also want the SQL Layer Client Tools.
The SQL Layer can then be accessed through a RESTful API on port 8091
:
$ curl http://localhost:8091/v1/version
[
{"server_name":"FoundationDB SQL Layer","server_version":"x.y.z+hash"}
]
And the SQL client on port 15432
:
$ fsql -c 'SELECT VERSION();'
_SQL_COL_1
--------------------------
FoundationDB x.y.z +hash
(1 row)
- GitHub: http://github.com/FoundationDB/sql-layer
- Community: https://foundationdb.com/community
- IRC: #FoundationDB on irc.freenode.net