Skip to content
Snippets Groups Projects
Commit 94fac4ca authored by Georgy Moshkin's avatar Georgy Moshkin :speech_balloon:
Browse files

feat: .proc_get_config

parent c84161df
No related branches found
No related tags found
1 merge request!913feat: pico.config() now shows sources for provided parameters
......@@ -36,6 +36,8 @@ with the `YY.MINOR.MICRO` scheme.
- `instance.memtx_memory` -> `instance.memtx.memory`
- New subcommand `picodata config default` for generating contents of the
config.yaml file with default parameter values.
- New rpc entrypoint: `.proc_get_config` which returns the effective
picodata configuration.
- Change _pico_index table structure.
- Support index creation with SQL.
......
use crate::config::PicodataConfig;
use crate::instance::Grade;
use crate::instance::InstanceId;
use crate::replicaset::ReplicasetId;
......@@ -265,3 +266,12 @@ pub fn proc_runtime_info() -> Result<RuntimeInfo<'static>, Error> {
RuntimeInfo::try_get(node)
}
////////////////////////////////////////////////////////////////////////////////
// .proc_get_config
////////////////////////////////////////////////////////////////////////////////
#[proc]
pub fn proc_get_config() -> Result<rmpv::Value, Error> {
Ok(PicodataConfig::get().parameters_with_sources_as_rmpv())
}
......@@ -71,7 +71,7 @@ instance:
instance.wait_online()
config = instance.call("pico.config")
config = instance.call(".proc_get_config")
assert config == dict(
cluster=dict(
tiers=dict(
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment