An example of the optimization abilities of the framework is available in
src/test/scala/ivm/tests/PaperTutorial.scala. When run as a test, it verifies
that the optimizer on the given query produces the same code as one gets by
To compile this project, you can use SBT.
The project uses SBT 0.12.0; later versions of SBT will download the right one.
To install SBT, follow instructions on this page:
Modify the SBT setup to use up to 2G of RAM by adding
javacommand line. Otherwise, compilation might be slower or run out of memory.
- After installing SBT, cd into this folder and launch
sbt. It will find the build instructions in
build.sbt. During the first execution SBT will auto-download various dependencies needed for itself (including the Scala compiler).
- Then, at the SBT prompt, give the
packagefollowed by newline) to compile and package the library as a JAR file under the
targetfolder. Compilation will require around 5-10 minutes on a recent machine.
- You can similarly run commands such as
test:compile(which also compiles tests) and
test(which additionally runs the tests - they include performance tests and take some time). I usually run tests using IntelliJ IDEA to specify which one I am interested in, even if I do not use it for compilation. In particular, tests in the
performancetestspackage take considerable time.
Note: this project incorporates
lib/bat-1.6.0.RC1.jar, a compiled snapshot of
BAT from https://github.com/Delors/BAT.
You can edit the project using IntelliJ IDEA 11 with the Scala and SBT plugins
installed, beyond SBT itself. We supply IDEA project files, but it is probably
best to regenerate them locally via SBT through the
Integrated compilation with IDEA is not supported; it is anyway too slow to be useful, therefore I would not recommend it.
There are also Eclipse project files (requiring the Scala plugin), but no active development uses Eclipse, therefore they are likely to be out-of-date.
We stopped using Eclipse because the Scala plugin was too buggy when we last tried (as I last tested it).
23 Apr 2012