more logging

This commit is contained in:
Radu Ioan Fericean
2016-03-16 12:03:37 +01:00
parent 758f7b4a4a
commit 260fde9932

View File

@@ -401,6 +401,7 @@ func (rs *Responder) GetSessionRuns(ev *CDR, sRuns *[]*SessionRun) error {
if ev.Subject == "" {
ev.Subject = ev.Account
}
utils.Logger.Info(fmt.Sprintf("DC before: %+v", ev))
// replace aliases
if err := LoadAlias(
&AttrMatchingAlias{
@@ -418,8 +419,10 @@ func (rs *Responder) GetSessionRuns(ev *CDR, sRuns *[]*SessionRun) error {
if err := LoadUserProfile(ev, utils.EXTRA_FIELDS); err != nil {
return err
}
utils.Logger.Info(fmt.Sprintf("DC after: %+v", ev))
attrsDC := &utils.AttrDerivedChargers{Tenant: ev.GetTenant(utils.META_DEFAULT), Category: ev.GetCategory(utils.META_DEFAULT), Direction: ev.GetDirection(utils.META_DEFAULT),
Account: ev.GetAccount(utils.META_DEFAULT), Subject: ev.GetSubject(utils.META_DEFAULT), Destination: ev.GetDestination(utils.META_DEFAULT)}
utils.Logger.Info(fmt.Sprintf("Derived chargers for: %+v", attrsDC))
dcs := &utils.DerivedChargers{}
if err := rs.GetDerivedChargers(attrsDC, dcs); err != nil {
rs.getCache().Cache(utils.GET_SESS_RUNS_CACHE_PREFIX+ev.CGRID, &cache2go.CacheItem{