mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-11 18:16:24 +05:00
Updated config APIs and added integration tests
This commit is contained in:
committed by
Dan Christian Bogos
parent
b0208c29f0
commit
ffcb95e2ca
@@ -26,8 +26,8 @@ import (
|
||||
func init() {
|
||||
c := &CmdRelaodConfigSection{
|
||||
name: "reload_config",
|
||||
rpcMethod: utils.ConfigSv1ReloadConfigFromPath,
|
||||
rpcParams: &config.ConfigReloadWithOpts{},
|
||||
rpcMethod: utils.ConfigSv1ReloadConfig,
|
||||
rpcParams: &config.ConfigReloadArgs{},
|
||||
}
|
||||
commands[c.Name()] = c
|
||||
c.CommandExecuter = &CommandExecuter{c}
|
||||
@@ -37,7 +37,7 @@ func init() {
|
||||
type CmdRelaodConfigSection struct {
|
||||
name string
|
||||
rpcMethod string
|
||||
rpcParams *config.ConfigReloadWithOpts
|
||||
rpcParams *config.ConfigReloadArgs
|
||||
*CommandExecuter
|
||||
}
|
||||
|
||||
@@ -51,7 +51,7 @@ func (self *CmdRelaodConfigSection) RpcMethod() string {
|
||||
|
||||
func (self *CmdRelaodConfigSection) RpcParams(reset bool) interface{} {
|
||||
if reset || self.rpcParams == nil {
|
||||
self.rpcParams = &config.ConfigReloadWithOpts{Opts: make(map[string]interface{})}
|
||||
self.rpcParams = &config.ConfigReloadArgs{Opts: make(map[string]interface{})}
|
||||
}
|
||||
return self.rpcParams
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user