Add source *sessions in case that isn't present when SessionS send the CDR to CDRServer to be processed

This commit is contained in:
TeoV
2019-07-10 16:15:13 +03:00
committed by Dan Christian Bogos
parent 8b08199b74
commit 0ed30ff0ea

View File

@@ -2550,6 +2550,9 @@ func (sS *SessionS) BiRPCv1ProcessCDR(clnt rpcclient.RpcClientConnection,
if cgrEvWithArgDisp.ID == "" {
cgrEvWithArgDisp.ID = utils.GenUUID()
}
if _, has := cgrEvWithArgDisp.Event[utils.Source]; !has {
cgrEvWithArgDisp.Event[utils.Source] = utils.MetaSessionS
}
// RPC caching
if sS.cgrCfg.CacheCfg()[utils.CacheRPCResponses].Limit != 0 {