From d268a3f143db9151d4c6f2a364e11f91bc7a7d6a Mon Sep 17 00:00:00 2001 From: Elliott Clark Date: Fri, 8 Apr 2016 13:44:45 -0700 Subject: [PATCH] HBASE-15604 Add a good readme on the build. --- hbase-native-client/BUILDING.md | 63 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 63 insertions(+) create mode 100644 hbase-native-client/BUILDING.md diff --git a/hbase-native-client/BUILDING.md b/hbase-native-client/BUILDING.md new file mode 100644 index 0000000..20ef2a0 --- /dev/null +++ b/hbase-native-client/BUILDING.md @@ -0,0 +1,63 @@ + + +#Building HBase native client + +The HBase native client build using buck and produces a linux library. + + +# Dependencies + +The easiest way to build hbase-native-client is to +use [Docker](https://www.docker.com/). This will mean that any platform +with docker can be used to build the hbase-native-client. It will also +mean that you're building with the same versions of all dependencies that +the client is tested with. + +On OSX the current boot2docker solution will work however it's pretty +slow. If things get too slow using [dinghy](https://github.com/codekitchen/dinghy) +can help speed things up by using nfs. + +If possible pairing virtual box with dinghy will result in the fastest, +most stable docker environment. However none of it is needed. + +# Building using docker + +To start with make sure that you have built the java project using +`mvn package -DskipTests`. That will allow all tests to spin up a standalone +hbase instance from the jar's created. + +Then go into the hbase-native-client directory and run `./bin/start-docker.sh` +that will build the docker development environment and when complete will +drop you into a shell on a linux vm with all the tools needed installed. + +# Buck + +From then on we can use [buck](https://buckbuild.com/) to build everything. +For example: +``` +buck build //core:core +buck test --all +buck build //core:simple-client +``` + +That will build the library, then build and test everything, then build +the simple-client binary. Buck will find all modules used, and compile +them in parallel, caching the results. Output from buck is in the buck-out +foulder. Generated binaries are in buck-out/gen logs are in buck-out/logs -- 2.8.0-rc2