]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
mon: ConfigKeyService: stash config keys on the monitor 150/head
authorJoao Eduardo Luis <joao.luis@inktank.com>
Fri, 1 Mar 2013 22:34:16 +0000 (22:34 +0000)
committerJoao Eduardo Luis <joao.luis@inktank.com>
Thu, 28 Mar 2013 23:36:38 +0000 (23:36 +0000)
commita021ce624542be36cf3b3c0b8e64d752019e4bc7
tree96c3286e075ff0ecada96c3cf5e65484151f70f8
parent10626f7be08ef159e44c32a4d19494a83d67ac30
mon: ConfigKeyService: stash config keys on the monitor

Building up on the Single-Paxos and our existing k/v store that backs
the monitor, we now introduce a simple service so that the monitors
act as a generic k/v store available to the cluster, in which a user
can stash (and later obtain) configuration keys at his own discretion.

Users can put, get, delete, list and check for values using the
following commands:

 - ceph config-key put <key> [<value>]
  or
 - ceph config-key put <key> [-i <in-file>]
  with 'value' and 'in-file' being optional; if these are not specified,
  'put' will act as 'touch' if 'key' does not exist, or will overwrite
  the value of 'key' with a zero byte value (i.e., truncates the
  contents of the value to zero)

 - ceph config-key get <key>
  or
 - ceph config-key get <key> -o <out-file>

 - ceph config-key delete <key>

 - ceph config-key list [-o <out-file]

 - ceph config-key exists <key>

Fixes: #4313
Signed-off-by: Joao Eduardo Luis <joao.luis@inktank.com>
src/Makefile.am
src/common/config_opts.h
src/mon/ConfigKeyService.cc [new file with mode: 0644]
src/mon/ConfigKeyService.h [new file with mode: 0644]
src/mon/Monitor.cc
src/mon/Monitor.h
src/mon/QuorumService.h