The JunoDB command line interface is used to query a JunoDB data storage service. It supports all JunoDB API operations that any JunoDB client library supports.
The command to run junocli is
./junocli [-version] [[options] <command> [<args>]]
junocli command run from within docker client
docker exec -it junoclient bash -c '/opt/juno/<junocli command>'
#Sample junocli command and full explanation of junocli given below
junocli command can be found under $BUILDTOP/release-binary/code-build
#Create junocli directory
mkdir junocli_tests
#Copy the junocli script
cp release-binary/code-build/junocli junocli_tests/junocli
#Copy the secrets folder
cp -r script/deploy/junoserv/secrets junocli_tests/
cd junocli_tests
#Write the config file (Sample config file and explanation of config parameters given in the link below)
vi config.toml
<Run the junocli command>
#Sample junocli command and full explanation of junocli given below
Sample config file and explanation found here
proxy_ip is the ip of the machine on which the server proxy is running. Can be found using hostname -i
command on the proxy machine.
proxy_port for manual build can be found under $BUILDTOP/package_config/package/junoserv/config/config.toml under listener ports (SSL Listener port if using SSL)
proxy_port for docker build can be found under $BUILDTOP/docker/manifest/config/proxy/config.toml under listener ports (SSL Listener port if using SSL)
- CREATE
./junocli create -s <proxy_ip>:<proxy_port> -c config.toml -ns test_ns test_key test_value
- GET
./junocli get -s <proxy_ip>:<proxy_port> -c config.toml -ns test_ns test_key
- UPDATE
./junocli update -s <proxy_ip>:<proxy_port> -c config.toml -ns test_ns test_key test_value_updated
#the value and version number will be updated. You can check this by using the GET command again.
- DESTROY
./junocli destroy -s <proxy_ip>:<proxy_port> -c config.toml -ns test_ns test_key
- proxy commands
- create
create a record - get
get the value of a given key - update
update a record - set
create or update a record if exists - destroy
destroy a record - udfget
udf get - udfset
udf set - populate
populate a set of records with set commands
- create
- storage commands
- pcreate
PrepareCreate to storage server - read
Read to storage server - pupdate
PrepareUpdate to storage server - pset
PrepareSet to storage server - delete
Delete to storage server - pdelete
PrepareDelete to storage server - commit
Commit the record having been prepared successfully - abort
Abort the record having been prepared successfully - repair
Repair record - mdelete
mark a record as deleted - populatess
populate storage with a set of repair commands
- pcreate
- others
- cfggen
generate default configuration file - config
unify the given toml configuration file(s) - inspect
check juno binary message, ... - ridinsp
check RequestID, ... - ssgrp
print the Shard ID and the SS group of a given key
- cfggen
For each command, the user can specify arguments. An explanation for these arguments can be found using
./junocli <command> --help