send agent events to stats/thresholds w/ ProcessTime

applies only to template-based agents
This commit is contained in:
ionutboangiu
2025-06-04 19:55:50 +03:00
committed by Dan Christian Bogos
parent 9b706f57ac
commit 671c7474b8
10 changed files with 180 additions and 26 deletions

View File

@@ -558,6 +558,7 @@ const (
TrendUpdate = "TrendUpdate"
RankingUpdate = "RankingUpdate"
ResourceUpdate = "ResourceUpdate"
ProcessTime = "ProcessTime"
CDR = "CDR"
CDRs = "CDRs"
ExpiryTime = "ExpiryTime"
@@ -604,6 +605,7 @@ const (
RatingPlanID = "RatingPlanID"
StartTime = "StartTime"
EndTime = "EndTime"
ProcessingTime = "ProcessingTime"
AccountSummary = "AccountSummary"
RatingFilters = "RatingFilters"
RatingFilter = "RatingFilter"
@@ -721,6 +723,14 @@ const (
MetaTerminate = "*terminate"
MetaEvent = "*event"
MetaMessage = "*message"
MetaDAStats = "*daStats"
MetaDAThresholds = "*daThresholds"
MetaRAStats = "*raStats"
MetaRAThresholds = "*raThresholds"
MetaDNSStats = "*dnsStats"
MetaDNSThresholds = "*dnsThresholds"
MetaHAStats = "*haStats"
MetaHAThresholds = "*haThresholds"
MetaDryRun = "*dryrun"
MetaRALsDryRun = "*ralsDryRun"
Event = "Event"

View File

@@ -192,7 +192,6 @@ func TestNewDecimalFromFloat64(t *testing.T) {
x := 21.5
xExp, _ := new(decimal.Big).SetString(strconv.FormatFloat(x, 'f', -1, 64))
expected := &Decimal{xExp}
// fmt.Printf("%v of type %T", expected, expected)
rcv := NewDecimalFromFloat64(x)
if !reflect.DeepEqual(rcv, expected) {
t.Errorf("Expected <+%v> but received <+%v>", xExp, rcv)