commit | db3a4b2958d36e738dcdee00ca9e9441a31695b0 | [log] [tgz] |
---|---|---|
author | Mike Walch <mwalch@apache.org> | Thu Jan 09 23:32:52 2020 -0500 |
committer | Christopher Tubbs <ctubbsii@apache.org> | Thu Jan 09 23:32:52 2020 -0500 |
tree | f49bef0f56fdabd455aeb3d16975fd316b2ffcc1 | |
parent | 32e2c09a3c00442c6ea9afd181d36934bc308e2c [diff] |
Documentation and code updates (#17) * Moved namespace code from the Accumulo website to namespace_client.py * Renamed existing python client to basic_client.py * Moved Java client code/docs from website to docs/java_client.md * Updated README.md
Apache Accumulo Proxy
This application acts as an Apache Accumulo Java client, and exposes its API as an Apache Thrift service so that users can use their preferred programming language to communicate with Accumulo (provided that language has a supported Thrift language binding).
Build the proxy tarball and install it.
cd /path/to/accumulo-proxy mvn clean package -Ptarball tar xzvf ./target/accumulo-proxy-2.0.0-SNAPSHOT-bin.tar.gz -C /path/to/install
Edit proxy.properties
and run the proxy.
cd /path/to/install/accumulo-proxy-2.0.0-SNAPSHOT ./bin/accumulo-proxy -p conf/proxy.properties
Bindings have been built in src/main/
for Java, Python, and Ruby.
Bindings for other languages can be built using the Thrift compiler. Follow the Thrift tutorial to install a Thrift compiler and use the following command to generate language bindings.
thrift -r --gen <language> <Thrift filename>
Run the commands below to install the Python bindings and create an example Python client:
mkdir accumulo-client/ cd accumulo-client/ pipenv --python 2.7 pipenv install thrift pipenv install -e /path/to/accumulo-proxy/src/main/python cp /path/to/accumulo-proxy/src/main/python/basic_client.py . # Edit credentials if needed vim basic_client.py pipenv run python2 basic_client.py
Run the command below to create an example Ruby client:
mkdir accumulo-client/ cd accumulo-client/ cp /path/to/accumulo-proxy/src/main/ruby/Gemfile . vim Gemfile # Set correct path cp /path/to/accumulo-proxy/src/main/ruby/client.rb . gem install bundler bundle install bundle exec client.rb
Java clients to the Proxy can be written to limit access to the cluster. The proxy can be placed on a server in the cluster and clients can communicate with proxy from outside of the cluster.