mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-11 18:16:24 +05:00
Correct in/out arguments for cache commands from cgr-console
This commit is contained in:
committed by
Dan Christian Bogos
parent
12c62a3096
commit
e616690c8b
@@ -20,13 +20,13 @@ package console
|
||||
|
||||
import (
|
||||
"github.com/cgrates/cgrates/utils"
|
||||
"github.com/cgrates/ltcache"
|
||||
)
|
||||
|
||||
func init() {
|
||||
c := &CmdGetPrecacheStatus{
|
||||
name: "cache_precache_status",
|
||||
rpcMethod: utils.CacheSv1PrecacheStatus,
|
||||
rpcParams: &utils.AttrCacheIDsWithArgDispatcher{},
|
||||
}
|
||||
commands[c.Name()] = c
|
||||
c.CommandExecuter = &CommandExecuter{c}
|
||||
@@ -36,7 +36,7 @@ func init() {
|
||||
type CmdGetPrecacheStatus struct {
|
||||
name string
|
||||
rpcMethod string
|
||||
rpcParams *StringSliceWrapper
|
||||
rpcParams *utils.AttrCacheIDsWithArgDispatcher
|
||||
*CommandExecuter
|
||||
}
|
||||
|
||||
@@ -50,7 +50,7 @@ func (self *CmdGetPrecacheStatus) RpcMethod() string {
|
||||
|
||||
func (self *CmdGetPrecacheStatus) RpcParams(reset bool) interface{} {
|
||||
if reset || self.rpcParams == nil {
|
||||
self.rpcParams = new(StringSliceWrapper)
|
||||
self.rpcParams = new(utils.AttrCacheIDsWithArgDispatcher)
|
||||
}
|
||||
return self.rpcParams
|
||||
}
|
||||
@@ -60,6 +60,6 @@ func (self *CmdGetPrecacheStatus) PostprocessRpcParams() error {
|
||||
}
|
||||
|
||||
func (self *CmdGetPrecacheStatus) RpcResult() interface{} {
|
||||
reply := make(map[string]*ltcache.CacheStats)
|
||||
reply := make(map[string]string)
|
||||
return &reply
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user