Console callbacks for TicTac AAE CLI commands#31
Conversation
|
After converting it to use clique, this PR is great again and ready for review. Note that OpenRiak/poolboy#1 and OpenRiak/kv_index_tictactree#4 as well as OpenRiak/riak_core#20 need to be dealt with first. |
* Tictac runtime management and reporting: riak admin tictacaae rebuild_schedule [-n NODE] [-p PARTITION] [RW RD] riak admin tictacaae storeheads [-n NODE] [-p PARTITION] [VALUE] riak admin tictacaae tokenbucket [-n NODE] [-p PARTITION] [VALUE] riak admin tictacaae rebuildtick|exchangetick|maxresults|rangeboost [-n NODE] [VAL] riak admin tictacaae rebuild-soon [-n NODE] [-p PARTITION] DELAY riak admin tictacaae rebuild-now [-n NODE] [-p PARTITION] DELAY riak admin tictacaae rebuildtreeworkers|rebuildstoreworkers|aaefoldworkers [-n NODE] POOLSIZE riak admin tictacaae treestatus [--format table|json] [--show STATES] * AAE fold operations, dumping results in JSON format: riak tictacaae fold list-buckets NVAL riak tictacaae fold find-keys BUCKET KEY_RANGE MODIFIED_RANGE sibling_count=COUNT|object_size=BYTES riak tictacaae fold find-keys BUCKET KEY_RANGE MODIFIED_RANGE sibling_count=COUNT|object_size=BYTES riak tictacaae fold find|count-tombstones KEY_RANGE SEGMENTS MODIFIED_RANGE riak tictacaae fold reap-tombstones KEY_RANGE SEGMENTS MODIFIED_RANGE CHANGE_METHOD riak tictacaae fold object-stats BUCKET KEY_RANGE MODIFIED_RANGE riak tictacaae fold erase-keys BUCKET KEY_RANGE SEGMENTS MODIFIED_RANGE CHANGE_METHOD riak tictacaae fold repair-keys BUCKET KEY_RANGE MODIFIED_RANGE
84f6aca to
45aa9b8
Compare
|
Marking it WIP pending review of OpenRiak/poolboy#1 and OpenRiak/riak_core#20. |
|
This PR in clique is to address this dialyzer issue https://github.com/OpenRiak/riak_kv/pull/31/checks. |
…genrepl-cli-commands
|
@hmmr when using the fold from the command line, and not specifying a file, in which directory is the file stored? The code uses |
Results will be written into the CWD of the riak VM, as user I was thinking of passing the user CWD to the callback code, for it to save the results into it, but since the VM will be writing that file as |
|
For the documentation it might be best then that a |
This PR implements "Tictac runtime management and reporting" section of the TicTac AAE and NextGenRepl CLI commands proposal.
The
riak_kv_console:titacaae_cmd/1functions will be exposed as the following riak admin commands:Tictac AAE runtime management and reporting
Notes:
Commands
rebuildtick,exchangetick,maxresults,rangeboostare simple set/show commands, reading and setting the corresponding app env vars in the riak_kv app, on local node by default or on other node if specified with option-n.rebuild-soonwill schedule a tree rebuild, andrebuild-nowwill additionally send a poke to controller(s) associated with partitions or nodes as specified with options-nand-p.Commands
storeheads,tokenbucket,rebuild_schedulewill extract or inject the actual relevant values from/to the state of the running AAE controller processes.Commands
rebuildtreeworkers,rebuildstoreworkers,aaefoldworkerswill read/set the size of worker poolsaf1,af4andbe, correspondingly.The
treestatuscommand will collect various items from running AAE contollers and produce a report like this:AAE fold operations
These will call the corresponding aae_fold operation and dump results in JSON format in a file named
"aaefold-%o-results-%t.json", where "%o" will be substituted with the operation being performed, and "%t", with the current datetime string, or to a file explicitly specified with option-o.Depends on these PRs: OpenRiak/kv_index_tictactree#4, OpenRiak/riak_core#20 and OpenRiak/poolboy#1.
Required by OpenRiak/riak#13.
Integration tests in https://github.com/OpenRiak/riak_test/pull/38.