Installing BigRecord Driver
Bigrecord drivers use JRuby DRb servers to connect with databases through their native Java APIs. Currently supported databases are HBase and Cassandra.
Requirements
- JRuby 1.3.0+
Installation
- Install the Java 1.6 runtime environment for your operating system. There are many resources online for this.
- Go to: jruby.org/getting-started and follow the instructions for installing the latest JRuby.
- Add the following to your shell rc file (~/.bashrc or ~/.zshrc)
export JRUBY_HOME=/path/to/jruby export PATH=$JRUBY_HOME/bin:$PATH
- Check that JRuby is installed correctly by typing in the following commands, and verifying you get similar output:
- Install the Bigrecord Driver gem from gemcutter.org
sudo gem install bigrecord-driver -s http://gemcutter.org/
> echo $JRUBY_HOME /path/to/jruby > jruby --version jruby 1.3.1 [...]
Usage
Once you have everything installed, you can start up a Bigrecord Driver DRb server with:
hbase-driver start -p [port]
Remember this port, because it will be used in the bigrecord.yml configuration file.
Debugging
If any errors are encountered during the usage of Bigrecord Driver, you can check the /tmp/hbase-driver/log/[port].log files for any errors that might have occurred.
{ 6 comments… read them below or add one }
Is Java 1.6 a must? Will Java 1.5 not work at all?
I’m not sure, but I believe HBase will only work with Java 1.6. Also, we haven’t tested this against 1.5, so we don’t know if it works or not.
Does the use of JRuby and DRb obviate using REST (”stargate”)? It looks like the bigrecord code depends on hbase-ruby and, AFAICT, that’s only used for REST client access.
Ian: Bigrecord Driver (JRuby+DRb) isn’t meant to replace or supersede the REST adapter (or vice-versa). It’s simply another option for choosing an adapter to connect to HBase with.
However, you’re correct. It shouldn’t be required for Bigrecord to run, and neither should bigrecord driver, for that matter. So, I’ve removed the dependency on either, and a message will prompt you to install the requirement when you initiate a connection and it can’t find it. Expect that change to be released soon.
Cool, thanks. Have you considered a google group (or an equivalent) for BigRecord questions/discussions?
@Ian Created a google group: http://groups.google.com/group/bigrecord