mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-11 18:16:24 +05:00
Start updating integration test for ~*req filter
This commit is contained in:
@@ -140,7 +140,7 @@ func testDspDspv1GetProfileForEvent(t *testing.T) {
|
||||
Tenant: "cgrates.org",
|
||||
ID: "EVENT1",
|
||||
Subsystems: []string{utils.META_ANY},
|
||||
FilterIDs: []string{"*string:~EventName:Event1"},
|
||||
FilterIDs: []string{"*string:~*req.EventName:Event1"},
|
||||
StrategyParams: make(map[string]interface{}),
|
||||
Strategy: utils.MetaWeight,
|
||||
Weight: 30,
|
||||
@@ -169,7 +169,7 @@ func testDspDspv1GetProfileForEvent(t *testing.T) {
|
||||
}
|
||||
reply.Hosts.Sort()
|
||||
if !reflect.DeepEqual(expected, reply) {
|
||||
t.Errorf("expected: %s , received: %s", utils.ToJSON(expected), utils.ToJSON(reply))
|
||||
t.Errorf("expected: %s ,\n received: %s", utils.ToJSON(expected), utils.ToJSON(reply))
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -466,7 +466,7 @@ func testInternalRemoteITGetFilter(t *testing.T) {
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
Type: "*string",
|
||||
FieldName: "~Account",
|
||||
FieldName: "~*req.Account",
|
||||
Values: []string{"1001"},
|
||||
},
|
||||
},
|
||||
@@ -609,8 +609,8 @@ func testInternalReplicationSetThreshold(t *testing.T) {
|
||||
}
|
||||
//verify indexes on engine2 before adding new threshold profile
|
||||
var indexes []string
|
||||
expectedIDX := []string{"*string:~Account:1001:THD_ACNT_1001",
|
||||
"*string:~Account:1002:THD_ACNT_1002"}
|
||||
expectedIDX := []string{"*string:~*req.Account:1001:THD_ACNT_1001",
|
||||
"*string:~*req.Account:1002:THD_ACNT_1002"}
|
||||
if err := engineTwoRPC.Call(utils.ApierV1GetFilterIndexes, &AttrGetFilterIndexes{
|
||||
ItemType: utils.MetaThresholds, Tenant: "cgrates.org", FilterType: utils.MetaString},
|
||||
&indexes); err != nil {
|
||||
@@ -637,7 +637,7 @@ func testInternalReplicationSetThreshold(t *testing.T) {
|
||||
ThresholdProfile: &engine.ThresholdProfile{
|
||||
Tenant: "cgrates.org",
|
||||
ID: "THD_Replication",
|
||||
FilterIDs: []string{"*string:~*req.Account:1001", "*string:~CustomField:CustomValue"},
|
||||
FilterIDs: []string{"*string:~*req.Account:1001", "*string:~*req.CustomField:CustomValue"},
|
||||
ActivationInterval: &utils.ActivationInterval{
|
||||
ActivationTime: time.Date(2014, 7, 14, 14, 35, 0, 0, time.UTC),
|
||||
},
|
||||
@@ -662,10 +662,10 @@ func testInternalReplicationSetThreshold(t *testing.T) {
|
||||
t.Errorf("Expecting: %+v, received: %+v", tPrfl.ThresholdProfile, reply)
|
||||
}
|
||||
expectedIDX = []string{
|
||||
"*string:~Account:1001:THD_ACNT_1001",
|
||||
"*string:~Account:1001:THD_Replication",
|
||||
"*string:~Account:1002:THD_ACNT_1002",
|
||||
"*string:~CustomField:CustomValue:THD_Replication",
|
||||
"*string:~*req.Account:1001:THD_ACNT_1001",
|
||||
"*string:~*req.Account:1001:THD_Replication",
|
||||
"*string:~*req.Account:1002:THD_ACNT_1002",
|
||||
"*string:~*req.CustomField:CustomValue:THD_Replication",
|
||||
}
|
||||
// verify index on internal
|
||||
sort.Strings(expectedIDX)
|
||||
@@ -687,9 +687,9 @@ func testInternalReplicationSetThreshold(t *testing.T) {
|
||||
t.Errorf("Expecting: %+v, received: %+v", tPrfl.ThresholdProfile, reply)
|
||||
}
|
||||
expectedIDX2 := []string{
|
||||
"*string:~Account:1001:THD_ACNT_1001",
|
||||
"*string:~Account:1001:THD_Replication",
|
||||
"*string:~CustomField:CustomValue:THD_Replication",
|
||||
"*string:~*req.Account:1001:THD_ACNT_1001",
|
||||
"*string:~*req.Account:1001:THD_Replication",
|
||||
"*string:~*req.CustomField:CustomValue:THD_Replication",
|
||||
}
|
||||
// verify indexes on engine1 (should be the same as internal)
|
||||
if err := engineOneRPC.Call(utils.ApierV1GetFilterIndexes, &AttrGetFilterIndexes{
|
||||
@@ -709,10 +709,10 @@ func testInternalReplicationSetThreshold(t *testing.T) {
|
||||
} else if !reflect.DeepEqual(tPrfl.ThresholdProfile, reply) {
|
||||
t.Errorf("Expecting: %+v, received: %+v", tPrfl.ThresholdProfile, reply)
|
||||
}
|
||||
expectedIDX = []string{"*string:~Account:1001:THD_ACNT_1001",
|
||||
"*string:~Account:1001:THD_Replication",
|
||||
"*string:~Account:1002:THD_ACNT_1002",
|
||||
"*string:~CustomField:CustomValue:THD_Replication",
|
||||
expectedIDX = []string{"*string:~*req.Account:1001:THD_ACNT_1001",
|
||||
"*string:~*req.Account:1001:THD_Replication",
|
||||
"*string:~*req.Account:1002:THD_ACNT_1002",
|
||||
"*string:~*req.CustomField:CustomValue:THD_Replication",
|
||||
}
|
||||
// check if indexes was created correctly on engine2
|
||||
if err := engineTwoRPC.Call(utils.ApierV1GetFilterIndexes, &AttrGetFilterIndexes{
|
||||
|
||||
@@ -161,7 +161,7 @@ func testV1FIdxSetThresholdProfile(t *testing.T) {
|
||||
Tenant: tenant,
|
||||
ID: "TestFilter",
|
||||
Rules: []*engine.FilterRule{{
|
||||
FieldName: "~Account",
|
||||
FieldName: "~*req.Account",
|
||||
Type: utils.MetaString,
|
||||
Values: []string{"1001"},
|
||||
}},
|
||||
@@ -242,7 +242,7 @@ func testV1FIdxComputeThresholdsIndexes(t *testing.T) {
|
||||
if reply2 != utils.OK {
|
||||
t.Errorf("Error: %+v", reply2)
|
||||
}
|
||||
expectedIDX := []string{"*string:~Account:1001:TEST_PROFILE1"}
|
||||
expectedIDX := []string{"*string:~*req.Account:1001:TEST_PROFILE1"}
|
||||
var indexes []string
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, &AttrGetFilterIndexes{
|
||||
ItemType: utils.MetaThresholds, Tenant: tenant, FilterType: utils.MetaString},
|
||||
@@ -261,7 +261,7 @@ func testV1FIdxSetSecondThresholdProfile(t *testing.T) {
|
||||
Tenant: tenant,
|
||||
ID: "TestFilter2",
|
||||
Rules: []*engine.FilterRule{{
|
||||
FieldName: "~Account",
|
||||
FieldName: "~*req.Account",
|
||||
Type: utils.MetaString,
|
||||
Values: []string{"1002"},
|
||||
}},
|
||||
@@ -344,7 +344,7 @@ func testV1FIdxSecondComputeThresholdsIndexes(t *testing.T) {
|
||||
if result != utils.OK {
|
||||
t.Errorf("Error: %+v", result)
|
||||
}
|
||||
expectedIDX := []string{"*string:~Account:1002:TEST_PROFILE2"}
|
||||
expectedIDX := []string{"*string:~*req.Account:1002:TEST_PROFILE2"}
|
||||
var indexes []string
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, &AttrGetFilterIndexes{
|
||||
ItemType: utils.MetaThresholds, Tenant: tenant, FilterType: utils.MetaString},
|
||||
@@ -373,7 +373,7 @@ func testV1FIdxThirdComputeThresholdsIndexes(t *testing.T) {
|
||||
if result != utils.OK {
|
||||
t.Errorf("Error: %+v", result)
|
||||
}
|
||||
expectedIDX := []string{"*string:~Account:1001:TEST_PROFILE1", "*string:~Account:1002:TEST_PROFILE2"}
|
||||
expectedIDX := []string{"*string:~*req.Account:1001:TEST_PROFILE1", "*string:~*req.Account:1002:TEST_PROFILE2"}
|
||||
sort.Strings(expectedIDX)
|
||||
var indexes []string
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, &AttrGetFilterIndexes{
|
||||
@@ -444,7 +444,7 @@ func testV1FIdxSetStatQueueProfileIndexes(t *testing.T) {
|
||||
Tenant: tenant,
|
||||
ID: "FLTR_1",
|
||||
Rules: []*engine.FilterRule{{
|
||||
FieldName: "~Account",
|
||||
FieldName: "~*req.Account",
|
||||
Type: utils.MetaString,
|
||||
Values: []string{"1001"},
|
||||
}},
|
||||
@@ -533,7 +533,7 @@ func testV1FIdxComputeStatQueueProfileIndexes(t *testing.T) {
|
||||
if result != utils.OK {
|
||||
t.Errorf("Error: %+v", result)
|
||||
}
|
||||
expectedIDX := []string{"*string:~Account:1001:TEST_PROFILE1"}
|
||||
expectedIDX := []string{"*string:~*req.Account:1001:TEST_PROFILE1"}
|
||||
var indexes []string
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, &AttrGetFilterIndexes{
|
||||
ItemType: utils.MetaStats, Tenant: tenant, FilterType: utils.MetaString},
|
||||
@@ -553,7 +553,7 @@ func testV1FIdxSetSecondStatQueueProfileIndexes(t *testing.T) {
|
||||
Tenant: tenant,
|
||||
ID: "FLTR_2",
|
||||
Rules: []*engine.FilterRule{{
|
||||
FieldName: "~Account",
|
||||
FieldName: "~*req.Account",
|
||||
Type: utils.MetaString,
|
||||
Values: []string{"1001"},
|
||||
}},
|
||||
@@ -643,7 +643,7 @@ func testV1FIdxSecondComputeStatQueueProfileIndexes(t *testing.T) {
|
||||
if result != utils.OK {
|
||||
t.Errorf("Error: %+v", result)
|
||||
}
|
||||
expectedIDX := []string{"*string:~Account:1001:TEST_PROFILE2"}
|
||||
expectedIDX := []string{"*string:~*req.Account:1001:TEST_PROFILE2"}
|
||||
var indexes []string
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, &AttrGetFilterIndexes{
|
||||
ItemType: utils.MetaStats, Tenant: tenant, FilterType: utils.MetaString},
|
||||
@@ -711,7 +711,7 @@ func testV1FIdxSetResourceProfileIndexes(t *testing.T) {
|
||||
Tenant: tenant,
|
||||
ID: "FLTR_RES_RCFG1",
|
||||
Rules: []*engine.FilterRule{{
|
||||
FieldName: "~Account",
|
||||
FieldName: "~*req.Account",
|
||||
Type: utils.MetaString,
|
||||
Values: []string{"1001"},
|
||||
}},
|
||||
@@ -790,7 +790,7 @@ func testV1FIdxComputeResourceProfileIndexes(t *testing.T) {
|
||||
if reply2 != utils.OK {
|
||||
t.Errorf("Error: %+v", reply2)
|
||||
}
|
||||
expectedIDX := []string{"*string:~Account:1001:RCFG1"}
|
||||
expectedIDX := []string{"*string:~*req.Account:1001:RCFG1"}
|
||||
var indexes []string
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, &AttrGetFilterIndexes{
|
||||
ItemType: utils.MetaResources, Tenant: tenant, FilterType: utils.MetaString},
|
||||
@@ -810,7 +810,7 @@ func testV1FIdxSetSecondResourceProfileIndexes(t *testing.T) {
|
||||
Tenant: tenant,
|
||||
ID: "FLTR_2",
|
||||
Rules: []*engine.FilterRule{{
|
||||
FieldName: "~Account",
|
||||
FieldName: "~*req.Account",
|
||||
Type: utils.MetaString,
|
||||
Values: []string{"1001"},
|
||||
}},
|
||||
@@ -891,7 +891,7 @@ func testV1FIdxSecondComputeResourceProfileIndexes(t *testing.T) {
|
||||
if reply2 != utils.OK {
|
||||
t.Errorf("Error: %+v", reply2)
|
||||
}
|
||||
expectedIDX := []string{"*string:~Account:1001:RCFG2"}
|
||||
expectedIDX := []string{"*string:~*req.Account:1001:RCFG2"}
|
||||
var indexes []string
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, &AttrGetFilterIndexes{
|
||||
ItemType: utils.MetaResources, Tenant: tenant, FilterType: utils.MetaString},
|
||||
@@ -958,7 +958,7 @@ func testV1FIdxSetSupplierProfileIndexes(t *testing.T) {
|
||||
ID: "FLTR_1",
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
FieldName: "~Account",
|
||||
FieldName: "~*req.Account",
|
||||
Type: utils.MetaString,
|
||||
Values: []string{"1001"},
|
||||
},
|
||||
@@ -1043,7 +1043,7 @@ func testV1FIdxComputeSupplierProfileIndexes(t *testing.T) {
|
||||
if reply2 != utils.OK {
|
||||
t.Errorf("Error: %+v", reply2)
|
||||
}
|
||||
expectedIDX := []string{"*string:~Account:1001:TEST_PROFILE1"}
|
||||
expectedIDX := []string{"*string:~*req.Account:1001:TEST_PROFILE1"}
|
||||
var indexes []string
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, &AttrGetFilterIndexes{
|
||||
ItemType: utils.MetaSuppliers, Tenant: tenant, FilterType: utils.MetaString},
|
||||
@@ -1063,7 +1063,7 @@ func testV1FIdxSetSecondSupplierProfileIndexes(t *testing.T) {
|
||||
Tenant: tenant,
|
||||
ID: "FLTR_2",
|
||||
Rules: []*engine.FilterRule{{
|
||||
FieldName: "~Account",
|
||||
FieldName: "~*req.Account",
|
||||
Type: utils.MetaString,
|
||||
Values: []string{"1001"},
|
||||
}},
|
||||
@@ -1148,7 +1148,7 @@ func testV1FIdxSecondComputeSupplierProfileIndexes(t *testing.T) {
|
||||
if reply2 != utils.OK {
|
||||
t.Errorf("Error: %+v", reply2)
|
||||
}
|
||||
expectedIDX := []string{"*string:~Account:1001:TEST_PROFILE2"}
|
||||
expectedIDX := []string{"*string:~*req.Account:1001:TEST_PROFILE2"}
|
||||
var indexes []string
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, &AttrGetFilterIndexes{
|
||||
ItemType: utils.MetaSuppliers, Tenant: tenant, FilterType: utils.MetaString},
|
||||
@@ -1218,7 +1218,7 @@ func testV1FIdxSetAttributeProfileIndexes(t *testing.T) {
|
||||
Tenant: tenant,
|
||||
ID: "FLTR_1",
|
||||
Rules: []*engine.FilterRule{{
|
||||
FieldName: "~Account",
|
||||
FieldName: "~*req.Account",
|
||||
Type: utils.MetaString,
|
||||
Values: []string{"1001"},
|
||||
}},
|
||||
@@ -1251,7 +1251,7 @@ func testV1FIdxSetAttributeProfileIndexes(t *testing.T) {
|
||||
},
|
||||
Attributes: []*engine.Attribute{
|
||||
{
|
||||
FilterIDs: []string{"*string:FL1:In1"},
|
||||
FilterIDs: []string{"*string:~*req.FL1:In1"},
|
||||
FieldName: "FL1",
|
||||
Value: config.NewRSRParsersMustCompile("Al1", true, utils.INFIELD_SEP),
|
||||
},
|
||||
@@ -1311,7 +1311,7 @@ func testV1FIdxComputeAttributeProfileIndexes(t *testing.T) {
|
||||
} else if result != utils.OK {
|
||||
t.Errorf("Error: %+v", result)
|
||||
}
|
||||
expectedIDX := []string{"*string:~Account:1001:ApierTest"}
|
||||
expectedIDX := []string{"*string:~*req.Account:1001:ApierTest"}
|
||||
var indexes []string
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, &AttrGetFilterIndexes{
|
||||
ItemType: utils.MetaAttributes,
|
||||
@@ -1332,7 +1332,7 @@ func testV1FIdxSetSecondAttributeProfileIndexes(t *testing.T) {
|
||||
Tenant: tenant,
|
||||
ID: "FLTR_2",
|
||||
Rules: []*engine.FilterRule{{
|
||||
FieldName: "~Account",
|
||||
FieldName: "~*req.Account",
|
||||
Type: utils.MetaString,
|
||||
Values: []string{"1001"},
|
||||
}},
|
||||
@@ -1365,7 +1365,7 @@ func testV1FIdxSetSecondAttributeProfileIndexes(t *testing.T) {
|
||||
ExpiryTime: time.Date(2014, 7, 14, 14, 35, 0, 0, time.UTC),
|
||||
},
|
||||
Attributes: []*engine.Attribute{{
|
||||
FilterIDs: []string{"*string:FL1:In1"},
|
||||
FilterIDs: []string{"*string:~*req.FL1:In1"},
|
||||
FieldName: "FL1",
|
||||
Value: config.NewRSRParsersMustCompile("Al1", true, utils.INFIELD_SEP),
|
||||
}},
|
||||
@@ -1427,7 +1427,7 @@ func testV1FIdxSecondComputeAttributeProfileIndexes(t *testing.T) {
|
||||
} else if result != utils.OK {
|
||||
t.Errorf("Error: %+v", result)
|
||||
}
|
||||
expectedIDX := []string{"*string:~Account:1001:ApierTest2"}
|
||||
expectedIDX := []string{"*string:~*req.Account:1001:ApierTest2"}
|
||||
var indexes []string
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, &AttrGetFilterIndexes{
|
||||
ItemType: utils.MetaAttributes,
|
||||
@@ -1460,8 +1460,8 @@ func testV1FIdxComputeWithAnotherContext(t *testing.T) {
|
||||
} else if result != utils.OK {
|
||||
t.Errorf("Error: %+v", result)
|
||||
}
|
||||
expectedIDX := []string{"*string:~Account:1001:ApierTest", "*string:~Account:1001:ApierTest2"}
|
||||
revExpectedIDX := []string{"*string:~Account:1001:ApierTest2", "*string:~Account:1001:ApierTest"}
|
||||
expectedIDX := []string{"*string:~*req.Account:1001:ApierTest", "*string:~*req.Account:1001:ApierTest2"}
|
||||
revExpectedIDX := []string{"*string:~*req.Account:1001:ApierTest2", "*string:~*req.Account:1001:ApierTest"}
|
||||
var indexes []string
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, &AttrGetFilterIndexes{
|
||||
ItemType: utils.MetaAttributes,
|
||||
@@ -1540,13 +1540,13 @@ func testV1FIdxPopulateDatabase(t *testing.T) {
|
||||
Tenant: tenant,
|
||||
ID: "ResProfile1",
|
||||
FilterIDs: []string{"*string:~*req.Account:1001",
|
||||
"*string:~Destination:1001",
|
||||
"*string:~Destination:2001",
|
||||
"*string:~Account:1002",
|
||||
"*prefix:~Account:10",
|
||||
"*string:~Destination:1001",
|
||||
"*prefix:~Destination:20",
|
||||
"*string:~Account:1002"},
|
||||
"*string:~*req.Destination:1001",
|
||||
"*string:~*req.Destination:2001",
|
||||
"*string:~*req.Account:1002",
|
||||
"*prefix:~*req.Account:10",
|
||||
"*string:~*req.Destination:1001",
|
||||
"*prefix:~*req.Destination:20",
|
||||
"*string:~*req.Account:1002"},
|
||||
},
|
||||
}
|
||||
if err := tFIdxRpc.Call(utils.ApierV1SetResourceProfile, resPrf, &result); err != nil {
|
||||
@@ -1559,13 +1559,13 @@ func testV1FIdxPopulateDatabase(t *testing.T) {
|
||||
Tenant: tenant,
|
||||
ID: "ResProfile2",
|
||||
FilterIDs: []string{"*string:~*req.Account:1001",
|
||||
"*string:~Destination:1001",
|
||||
"*string:~Destination:2001",
|
||||
"*string:~Account:2002",
|
||||
"*prefix:~Account:10",
|
||||
"*string:~Destination:2001",
|
||||
"*prefix:~Destination:20",
|
||||
"*string:~Account:1002"},
|
||||
"*string:~*req.Destination:1001",
|
||||
"*string:~*req.Destination:2001",
|
||||
"*string:~*req.Account:2002",
|
||||
"*prefix:~*req.Account:10",
|
||||
"*string:~*req.Destination:2001",
|
||||
"*prefix:~*req.Destination:20",
|
||||
"*string:~*req.Account:1002"},
|
||||
},
|
||||
}
|
||||
if err := tFIdxRpc.Call(utils.ApierV1SetResourceProfile, resPrf, &result); err != nil {
|
||||
@@ -1578,13 +1578,13 @@ func testV1FIdxPopulateDatabase(t *testing.T) {
|
||||
Tenant: tenant,
|
||||
ID: "ResProfile3",
|
||||
FilterIDs: []string{"*string:~*req.Account:3001",
|
||||
"*string:~Destination:1001",
|
||||
"*string:~Destination:2001",
|
||||
"*string:~Account:1002",
|
||||
"*prefix:~Account:10",
|
||||
"*prefix:~Destination:1001",
|
||||
"*prefix:~Destination:200",
|
||||
"*string:~Account:1003"},
|
||||
"*string:~*req.Destination:1001",
|
||||
"*string:~*req.Destination:2001",
|
||||
"*string:~*req.Account:1002",
|
||||
"*prefix:~*req.Account:10",
|
||||
"*prefix:~*req.Destination:1001",
|
||||
"*prefix:~*req.Destination:200",
|
||||
"*string:~*req.Account:1003"},
|
||||
},
|
||||
}
|
||||
if err := tFIdxRpc.Call(utils.ApierV1SetResourceProfile, resPrf, &result); err != nil {
|
||||
@@ -1600,27 +1600,27 @@ func testV1FIdxGetFilterIndexes1(t *testing.T) {
|
||||
ItemType: utils.MetaResources,
|
||||
}
|
||||
expectedIndexes := []string{
|
||||
"*string:~Account:3001:ResProfile3",
|
||||
"*string:~Destination:1001:ResProfile1",
|
||||
"*string:~Destination:1001:ResProfile2",
|
||||
"*string:~Destination:1001:ResProfile3",
|
||||
"*string:~Account:1002:ResProfile1",
|
||||
"*string:~Account:1002:ResProfile2",
|
||||
"*string:~Account:1002:ResProfile3",
|
||||
"*string:~Account:1003:ResProfile3",
|
||||
"*prefix:~Destination:20:ResProfile1",
|
||||
"*prefix:~Destination:20:ResProfile2",
|
||||
"*string:~Account:1001:ResProfile1",
|
||||
"*string:~Account:1001:ResProfile2",
|
||||
"*string:~Account:2002:ResProfile2",
|
||||
"*prefix:~Destination:1001:ResProfile3",
|
||||
"*prefix:~Destination:200:ResProfile3",
|
||||
"*string:~Destination:2001:ResProfile1",
|
||||
"*string:~Destination:2001:ResProfile2",
|
||||
"*string:~Destination:2001:ResProfile3",
|
||||
"*prefix:~Account:10:ResProfile1",
|
||||
"*prefix:~Account:10:ResProfile2",
|
||||
"*prefix:~Account:10:ResProfile3"}
|
||||
"*string:~*req.Account:3001:ResProfile3",
|
||||
"*string:~*req.Destination:1001:ResProfile1",
|
||||
"*string:~*req.Destination:1001:ResProfile2",
|
||||
"*string:~*req.Destination:1001:ResProfile3",
|
||||
"*string:~*req.Account:1002:ResProfile1",
|
||||
"*string:~*req.Account:1002:ResProfile2",
|
||||
"*string:~*req.Account:1002:ResProfile3",
|
||||
"*string:~*req.Account:1003:ResProfile3",
|
||||
"*prefix:~*req.Destination:20:ResProfile1",
|
||||
"*prefix:~*req.Destination:20:ResProfile2",
|
||||
"*string:~*req.Account:1001:ResProfile1",
|
||||
"*string:~*req.Account:1001:ResProfile2",
|
||||
"*string:~*req.Account:2002:ResProfile2",
|
||||
"*prefix:~*req.Destination:1001:ResProfile3",
|
||||
"*prefix:~*req.Destination:200:ResProfile3",
|
||||
"*string:~*req.Destination:2001:ResProfile1",
|
||||
"*string:~*req.Destination:2001:ResProfile2",
|
||||
"*string:~*req.Destination:2001:ResProfile3",
|
||||
"*prefix:~*req.Account:10:ResProfile1",
|
||||
"*prefix:~*req.Account:10:ResProfile2",
|
||||
"*prefix:~*req.Account:10:ResProfile3"}
|
||||
sort.Strings(expectedIndexes)
|
||||
var reply []string
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, arg, &reply); err != nil {
|
||||
@@ -1637,20 +1637,20 @@ func testV1FIdxGetFilterIndexes2(t *testing.T) {
|
||||
FilterType: utils.MetaString,
|
||||
}
|
||||
expectedIndexes := []string{
|
||||
"*string:~Account:1003:ResProfile3",
|
||||
"*string:~Account:3001:ResProfile3",
|
||||
"*string:~Destination:1001:ResProfile1",
|
||||
"*string:~Destination:1001:ResProfile2",
|
||||
"*string:~Destination:1001:ResProfile3",
|
||||
"*string:~Account:1002:ResProfile1",
|
||||
"*string:~Account:1002:ResProfile2",
|
||||
"*string:~Account:1002:ResProfile3",
|
||||
"*string:~Account:1001:ResProfile1",
|
||||
"*string:~Account:1001:ResProfile2",
|
||||
"*string:~Destination:2001:ResProfile3",
|
||||
"*string:~Destination:2001:ResProfile1",
|
||||
"*string:~Destination:2001:ResProfile2",
|
||||
"*string:~Account:2002:ResProfile2"}
|
||||
"*string:~*req.Account:1003:ResProfile3",
|
||||
"*string:~*req.Account:3001:ResProfile3",
|
||||
"*string:~*req.Destination:1001:ResProfile1",
|
||||
"*string:~*req.Destination:1001:ResProfile2",
|
||||
"*string:~*req.Destination:1001:ResProfile3",
|
||||
"*string:~*req.Account:1002:ResProfile1",
|
||||
"*string:~*req.Account:1002:ResProfile2",
|
||||
"*string:~*req.Account:1002:ResProfile3",
|
||||
"*string:~*req.Account:1001:ResProfile1",
|
||||
"*string:~*req.Account:1001:ResProfile2",
|
||||
"*string:~*req.Destination:2001:ResProfile3",
|
||||
"*string:~*req.Destination:2001:ResProfile1",
|
||||
"*string:~*req.Destination:2001:ResProfile2",
|
||||
"*string:~*req.Account:2002:ResProfile2"}
|
||||
sort.Strings(expectedIndexes)
|
||||
var reply []string
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, arg, &reply); err != nil {
|
||||
@@ -1667,13 +1667,13 @@ func testV1FIdxGetFilterIndexes3(t *testing.T) {
|
||||
FilterType: utils.MetaPrefix,
|
||||
}
|
||||
expectedIndexes := []string{
|
||||
"*prefix:~Destination:20:ResProfile1",
|
||||
"*prefix:~Destination:20:ResProfile2",
|
||||
"*prefix:~Account:10:ResProfile1",
|
||||
"*prefix:~Account:10:ResProfile2",
|
||||
"*prefix:~Account:10:ResProfile3",
|
||||
"*prefix:~Destination:200:ResProfile3",
|
||||
"*prefix:~Destination:1001:ResProfile3"}
|
||||
"*prefix:~*req.Destination:20:ResProfile1",
|
||||
"*prefix:~*req.Destination:20:ResProfile2",
|
||||
"*prefix:~*req.Account:10:ResProfile1",
|
||||
"*prefix:~*req.Account:10:ResProfile2",
|
||||
"*prefix:~*req.Account:10:ResProfile3",
|
||||
"*prefix:~*req.Destination:200:ResProfile3",
|
||||
"*prefix:~*req.Destination:1001:ResProfile3"}
|
||||
sort.Strings(expectedIndexes)
|
||||
var reply []string
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, arg, &reply); err != nil {
|
||||
@@ -1691,14 +1691,14 @@ func testV1FIdxGetFilterIndexes4(t *testing.T) {
|
||||
FilterField: "Account",
|
||||
}
|
||||
expectedIndexes := []string{
|
||||
"*string:~Account:1003:ResProfile3",
|
||||
"*string:~Account:3001:ResProfile3",
|
||||
"*string:~Account:1002:ResProfile1",
|
||||
"*string:~Account:1002:ResProfile2",
|
||||
"*string:~Account:1002:ResProfile3",
|
||||
"*string:~Account:1001:ResProfile1",
|
||||
"*string:~Account:1001:ResProfile2",
|
||||
"*string:~Account:2002:ResProfile2"}
|
||||
"*string:~*req.Account:1003:ResProfile3",
|
||||
"*string:~*req.Account:3001:ResProfile3",
|
||||
"*string:~*req.Account:1002:ResProfile1",
|
||||
"*string:~*req.Account:1002:ResProfile2",
|
||||
"*string:~*req.Account:1002:ResProfile3",
|
||||
"*string:~*req.Account:1001:ResProfile1",
|
||||
"*string:~*req.Account:1001:ResProfile2",
|
||||
"*string:~*req.Account:2002:ResProfile2"}
|
||||
sort.Strings(expectedIndexes)
|
||||
var reply []string
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, arg, &reply); err != nil {
|
||||
@@ -1715,7 +1715,7 @@ func testV1FIdxSetDispatcherProfile(t *testing.T) {
|
||||
DispatcherProfile: &engine.DispatcherProfile{
|
||||
Tenant: "cgrates.org",
|
||||
ID: "DSP_Test1",
|
||||
FilterIDs: []string{"*string:~Account:1001", "*string:~Subject:2012", "*prefix:~RandomField:RandomValue"},
|
||||
FilterIDs: []string{"*string:~*req.Account:1001", "*string:~*req.Subject:2012", "*prefix:~*req.RandomField:RandomValue"},
|
||||
Strategy: utils.MetaFirst,
|
||||
Subsystems: []string{utils.MetaAttributes, utils.MetaSessionS},
|
||||
Weight: 20,
|
||||
@@ -1738,8 +1738,8 @@ func testV1FIdxSetDispatcherProfile(t *testing.T) {
|
||||
FilterType: utils.MetaString,
|
||||
}
|
||||
expectedIndexes := []string{
|
||||
"*string:~Account:1001:DSP_Test1",
|
||||
"*string:~Subject:2012:DSP_Test1",
|
||||
"*string:~*req.Account:1001:DSP_Test1",
|
||||
"*string:~*req.Subject:2012:DSP_Test1",
|
||||
}
|
||||
sort.Strings(expectedIndexes)
|
||||
var idx []string
|
||||
@@ -1757,8 +1757,8 @@ func testV1FIdxSetDispatcherProfile(t *testing.T) {
|
||||
FilterType: utils.MetaString,
|
||||
}
|
||||
expectedIndexes = []string{
|
||||
"*string:~Account:1001:DSP_Test1",
|
||||
"*string:~Subject:2012:DSP_Test1",
|
||||
"*string:~*req.Account:1001:DSP_Test1",
|
||||
"*string:~*req.Subject:2012:DSP_Test1",
|
||||
}
|
||||
sort.Strings(expectedIndexes)
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, arg, &idx); err != nil {
|
||||
@@ -1774,9 +1774,9 @@ func testV1FIdxSetDispatcherProfile(t *testing.T) {
|
||||
ItemType: utils.MetaDispatchers,
|
||||
}
|
||||
expectedIndexes = []string{
|
||||
"*prefix:~RandomField:RandomValue:DSP_Test1",
|
||||
"*string:~Account:1001:DSP_Test1",
|
||||
"*string:~Subject:2012:DSP_Test1",
|
||||
"*prefix:~*req.RandomField:RandomValue:DSP_Test1",
|
||||
"*string:~*req.Account:1001:DSP_Test1",
|
||||
"*string:~*req.Subject:2012:DSP_Test1",
|
||||
}
|
||||
sort.Strings(expectedIndexes)
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, arg, &idx); err != nil {
|
||||
@@ -1808,9 +1808,9 @@ func testV1FIdxSetDispatcherProfile(t *testing.T) {
|
||||
ItemType: utils.MetaDispatchers,
|
||||
}
|
||||
expectedIndexes = []string{
|
||||
"*prefix:~RandomField:RandomValue:DSP_Test1",
|
||||
"*string:~Account:1001:DSP_Test1",
|
||||
"*string:~Subject:2012:DSP_Test1",
|
||||
"*prefix:~*req.RandomField:RandomValue:DSP_Test1",
|
||||
"*string:~*req.Account:1001:DSP_Test1",
|
||||
"*string:~*req.Subject:2012:DSP_Test1",
|
||||
}
|
||||
sort.Strings(expectedIndexes)
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, arg, &idx); err != nil {
|
||||
@@ -1840,9 +1840,9 @@ func testV1FIdxComputeDispatcherProfileIndexes(t *testing.T) {
|
||||
t.Errorf("Error: %+v", result)
|
||||
}
|
||||
expectedIndexes := []string{
|
||||
"*prefix:~RandomField:RandomValue:DSP_Test1",
|
||||
"*string:~Account:1001:DSP_Test1",
|
||||
"*string:~Subject:2012:DSP_Test1",
|
||||
"*prefix:~*req.RandomField:RandomValue:DSP_Test1",
|
||||
"*string:~*req.Account:1001:DSP_Test1",
|
||||
"*string:~*req.Subject:2012:DSP_Test1",
|
||||
}
|
||||
sort.Strings(expectedIndexes)
|
||||
var indexes []string
|
||||
@@ -1904,9 +1904,9 @@ func testV1FIdxSetDispatcherProfile2(t *testing.T) {
|
||||
}
|
||||
expectedIndexes := []string{
|
||||
"*none:*any:*any:DSP_Test2",
|
||||
"*prefix:~RandomField:RandomValue:DSP_Test1",
|
||||
"*string:~Account:1001:DSP_Test1",
|
||||
"*string:~Subject:2012:DSP_Test1",
|
||||
"*prefix:~*req.RandomField:RandomValue:DSP_Test1",
|
||||
"*string:~*req.Account:1001:DSP_Test1",
|
||||
"*string:~*req.Subject:2012:DSP_Test1",
|
||||
}
|
||||
sort.Strings(expectedIndexes)
|
||||
var idx []string
|
||||
@@ -1924,9 +1924,9 @@ func testV1FIdxSetDispatcherProfile2(t *testing.T) {
|
||||
}
|
||||
expectedIndexes = []string{
|
||||
"*none:*any:*any:DSP_Test3",
|
||||
"*prefix:~RandomField:RandomValue:DSP_Test1",
|
||||
"*string:~Account:1001:DSP_Test1",
|
||||
"*string:~Subject:2012:DSP_Test1",
|
||||
"*prefix:~*req.RandomField:RandomValue:DSP_Test1",
|
||||
"*string:~*req.Account:1001:DSP_Test1",
|
||||
"*string:~*req.Subject:2012:DSP_Test1",
|
||||
}
|
||||
sort.Strings(expectedIndexes)
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, arg, &idx); err != nil {
|
||||
@@ -1994,9 +1994,9 @@ func testV1FIdxComputeDispatcherProfileIndexes2(t *testing.T) {
|
||||
}
|
||||
expectedIndexes := []string{
|
||||
"*none:*any:*any:DSP_Test3",
|
||||
"*prefix:~RandomField:RandomValue:DSP_Test1",
|
||||
"*string:~Account:1001:DSP_Test1",
|
||||
"*string:~Subject:2012:DSP_Test1",
|
||||
"*prefix:~*req.RandomField:RandomValue:DSP_Test1",
|
||||
"*string:~*req.Account:1001:DSP_Test1",
|
||||
"*string:~*req.Subject:2012:DSP_Test1",
|
||||
}
|
||||
sort.Strings(expectedIndexes)
|
||||
var indexes []string
|
||||
@@ -2028,9 +2028,9 @@ func testV1FIdxComputeDispatcherProfileIndexes2(t *testing.T) {
|
||||
}
|
||||
expectedIndexes = []string{
|
||||
"*none:*any:*any:DSP_Test2",
|
||||
"*prefix:~RandomField:RandomValue:DSP_Test1",
|
||||
"*string:~Account:1001:DSP_Test1",
|
||||
"*string:~Subject:2012:DSP_Test1",
|
||||
"*prefix:~*req.RandomField:RandomValue:DSP_Test1",
|
||||
"*string:~*req.Account:1001:DSP_Test1",
|
||||
"*string:~*req.Subject:2012:DSP_Test1",
|
||||
}
|
||||
sort.Strings(expectedIndexes)
|
||||
if err := tFIdxRpc.Call(utils.ApierV1GetFilterIndexes, &AttrGetFilterIndexes{
|
||||
|
||||
@@ -158,12 +158,12 @@ func testV1FIdxCaSetThresholdProfile(t *testing.T) {
|
||||
ID: "TestFilter",
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Account,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Account,
|
||||
Type: "*string",
|
||||
Values: []string{"1001"},
|
||||
},
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.EventType,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.EventType,
|
||||
Type: "*string",
|
||||
Values: []string{utils.BalanceUpdate},
|
||||
},
|
||||
@@ -252,12 +252,12 @@ func testV1FIdxCaUpdateThresholdProfile(t *testing.T) {
|
||||
ID: "TestFilter2",
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Account,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Account,
|
||||
Type: "*string",
|
||||
Values: []string{"1002"},
|
||||
},
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.EventType,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.EventType,
|
||||
Type: "*string",
|
||||
Values: []string{utils.AccountUpdate},
|
||||
},
|
||||
@@ -332,12 +332,12 @@ func testV1FIdxCaUpdateThresholdProfileFromTP(t *testing.T) {
|
||||
ID: "TestFilter3",
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Account,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Account,
|
||||
Type: "*string",
|
||||
Values: []string{"1003"},
|
||||
},
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.EventType,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.EventType,
|
||||
Type: "*string",
|
||||
Values: []string{utils.BalanceUpdate},
|
||||
},
|
||||
@@ -495,12 +495,12 @@ func testV1FIdxCaSetStatQueueProfile(t *testing.T) {
|
||||
ID: "FLTR_1",
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Account,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Account,
|
||||
Type: "*string",
|
||||
Values: []string{"1001"},
|
||||
},
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.EventType,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.EventType,
|
||||
Type: "*string",
|
||||
Values: []string{utils.AccountUpdate},
|
||||
},
|
||||
@@ -649,12 +649,12 @@ func testV1FIdxCaUpdateStatQueueProfile(t *testing.T) {
|
||||
ID: "FLTR_2",
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Account,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Account,
|
||||
Type: "*string",
|
||||
Values: []string{"1003"},
|
||||
},
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.EventType,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.EventType,
|
||||
Type: "*string",
|
||||
Values: []string{utils.BalanceUpdate},
|
||||
},
|
||||
@@ -724,12 +724,12 @@ func testV1FIdxCaUpdateStatQueueProfileFromTP(t *testing.T) {
|
||||
ID: "FLTR_3",
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Account,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Account,
|
||||
Type: "*string",
|
||||
Values: []string{"1003"},
|
||||
},
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.EventType,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.EventType,
|
||||
Type: "*string",
|
||||
Values: []string{utils.AccountUpdate},
|
||||
},
|
||||
@@ -885,12 +885,12 @@ func testV1FIdxCaSetAttributeProfile(t *testing.T) {
|
||||
ID: "TestFilter",
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Account,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Account,
|
||||
Type: "*string",
|
||||
Values: []string{"1009"},
|
||||
},
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Destination,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Destination,
|
||||
Type: "*string",
|
||||
Values: []string{"+491511231234"},
|
||||
},
|
||||
@@ -978,12 +978,12 @@ func testV1FIdxCaUpdateAttributeProfile(t *testing.T) {
|
||||
ID: "TestFilter2",
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Account,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Account,
|
||||
Type: "*string",
|
||||
Values: []string{"2009"},
|
||||
},
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Destination,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Destination,
|
||||
Type: "*string",
|
||||
Values: []string{"+492511231234"},
|
||||
},
|
||||
@@ -1051,12 +1051,12 @@ func testV1FIdxCaUpdateAttributeProfileFromTP(t *testing.T) {
|
||||
ID: "TestFilter3",
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Account,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Account,
|
||||
Type: "*string",
|
||||
Values: []string{"3009"},
|
||||
},
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Destination,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Destination,
|
||||
Type: "*string",
|
||||
Values: []string{"+492511231234"},
|
||||
},
|
||||
@@ -1204,17 +1204,17 @@ func testV1FIdxCaSetResourceProfile(t *testing.T) {
|
||||
ID: "FLTR_RES_RCFG1",
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Account,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Account,
|
||||
Type: "*string",
|
||||
Values: []string{"1001"},
|
||||
},
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Subject,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Subject,
|
||||
Type: "*string",
|
||||
Values: []string{"1002"},
|
||||
},
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Destination,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Destination,
|
||||
Type: "*string",
|
||||
Values: []string{"1001"},
|
||||
},
|
||||
@@ -1333,17 +1333,17 @@ func testV1FIdxCaUpdateResourceProfile(t *testing.T) {
|
||||
ID: "FLTR_RES_RCFG2",
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Account,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Account,
|
||||
Type: "*string",
|
||||
Values: []string{"2002"},
|
||||
},
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Subject,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Subject,
|
||||
Type: "*string",
|
||||
Values: []string{"2001"},
|
||||
},
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Destination,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Destination,
|
||||
Type: "*string",
|
||||
Values: []string{"2002"},
|
||||
},
|
||||
@@ -1409,17 +1409,17 @@ func testV1FIdxCaUpdateResourceProfileFromTP(t *testing.T) {
|
||||
ID: "FLTR_RES_RCFG3",
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Account,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Account,
|
||||
Type: "*string",
|
||||
Values: []string{"1002"},
|
||||
},
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Subject,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Subject,
|
||||
Type: "*string",
|
||||
Values: []string{"1001"},
|
||||
},
|
||||
{
|
||||
FieldName: utils.DynamicDataPrefix + utils.Destination,
|
||||
FieldName: utils.DynamicDataPrefix + utils.MetaReq + utils.NestingSep + utils.Destination,
|
||||
Type: "*string",
|
||||
Values: []string{"1002"},
|
||||
},
|
||||
|
||||
@@ -679,7 +679,7 @@ func testV1RsGetResourceProfileAfterSet(t *testing.T) {
|
||||
|
||||
func testV1RsUpdateResourceProfile(t *testing.T) {
|
||||
var result string
|
||||
rlsConfig.FilterIDs = []string{"*string:~Account:1001", "*prefix:~DST:10"}
|
||||
rlsConfig.FilterIDs = []string{"*string:~*req.Account:1001", "*prefix:~*req.DST:10"}
|
||||
if err := rlsV1Rpc.Call(utils.ApierV1SetResourceProfile, rlsConfig, &result); err != nil {
|
||||
t.Error(err)
|
||||
} else if result != utils.OK {
|
||||
|
||||
@@ -151,7 +151,8 @@ func testV1STSFromFolder(t *testing.T) {
|
||||
func testV1STSGetStats(t *testing.T) {
|
||||
var reply []string
|
||||
expectedIDs := []string{"Stats1"}
|
||||
if err := stsV1Rpc.Call(utils.StatSv1GetQueueIDs, &utils.TenantWithArgDispatcher{TenantArg: &utils.TenantArg{"cgrates.org"}}, &reply); err != nil {
|
||||
if err := stsV1Rpc.Call(utils.StatSv1GetQueueIDs,
|
||||
&utils.TenantWithArgDispatcher{TenantArg: &utils.TenantArg{"cgrates.org"}}, &reply); err != nil {
|
||||
t.Error(err)
|
||||
} else if !reflect.DeepEqual(expectedIDs, reply) {
|
||||
t.Errorf("expecting: %+v, received reply: %s", expectedIDs, reply)
|
||||
@@ -168,7 +169,8 @@ func testV1STSGetStats(t *testing.T) {
|
||||
utils.ConcatenatedKey(utils.MetaAverage, utils.DynamicDataPrefix+utils.Usage): utils.NOT_AVAILABLE,
|
||||
}
|
||||
if err := stsV1Rpc.Call(utils.StatSv1GetQueueStringMetrics,
|
||||
&utils.TenantIDWithArgDispatcher{TenantID: &utils.TenantID{Tenant: "cgrates.org", ID: expectedIDs[0]}}, &metrics); err != nil {
|
||||
&utils.TenantIDWithArgDispatcher{TenantID: &utils.TenantID{Tenant: "cgrates.org", ID: expectedIDs[0]}},
|
||||
&metrics); err != nil {
|
||||
t.Error(err)
|
||||
} else if !reflect.DeepEqual(expectedMetrics, metrics) {
|
||||
t.Errorf("expecting: %+v, received reply: %s", expectedMetrics, metrics)
|
||||
@@ -340,7 +342,7 @@ func testV1STSSetStatQueueProfile(t *testing.T) {
|
||||
ID: "FLTR_1",
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
FieldName: "~Account",
|
||||
FieldName: "~*req.Account",
|
||||
Type: "*string",
|
||||
Values: []string{"1001"},
|
||||
},
|
||||
@@ -420,7 +422,7 @@ func testV1STSUpdateStatQueueProfile(t *testing.T) {
|
||||
ID: "FLTR_2",
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
FieldName: "~Account",
|
||||
FieldName: "~*req.Account",
|
||||
Type: "*string",
|
||||
Values: []string{"1001"},
|
||||
},
|
||||
@@ -484,15 +486,15 @@ func testV1STSProcessMetricsWithFilter(t *testing.T) {
|
||||
Metrics: []*engine.MetricWithFilters{
|
||||
&engine.MetricWithFilters{
|
||||
MetricID: "*acd",
|
||||
FilterIDs: []string{"*rsr::~Usage{*duration}(>10s)"},
|
||||
FilterIDs: []string{"*rsr::~*req.Usage{*duration}(>10s)"},
|
||||
},
|
||||
&engine.MetricWithFilters{
|
||||
MetricID: "*tcd",
|
||||
FilterIDs: []string{"*gt:~Usage:5s"},
|
||||
FilterIDs: []string{"*gt:~*req.Usage:5s"},
|
||||
},
|
||||
&engine.MetricWithFilters{
|
||||
MetricID: "*sum:~CustomValue",
|
||||
FilterIDs: []string{"*exists:~CustomValue:", "*gte:~CustomValue:10.0"},
|
||||
FilterIDs: []string{"*exists:~*req.CustomValue:", "*gte:~*req.CustomValue:10.0"},
|
||||
},
|
||||
},
|
||||
ThresholdIDs: []string{"*none"},
|
||||
@@ -554,7 +556,8 @@ func testV1STSProcessMetricsWithFilter(t *testing.T) {
|
||||
utils.ConcatenatedKey(utils.MetaSum, "~CustomValue"): utils.NOT_AVAILABLE,
|
||||
}
|
||||
if err := stsV1Rpc.Call(utils.StatSv1GetQueueStringMetrics,
|
||||
&utils.TenantIDWithArgDispatcher{TenantID: &utils.TenantID{Tenant: "cgrates.org", ID: expectedIDs[0]}}, &metrics); err != nil {
|
||||
&utils.TenantIDWithArgDispatcher{
|
||||
TenantID: &utils.TenantID{Tenant: "cgrates.org", ID: expectedIDs[0]}}, &metrics); err != nil {
|
||||
t.Error(err)
|
||||
} else if !reflect.DeepEqual(expectedMetrics, metrics) {
|
||||
t.Errorf("expecting: %+v, received reply: %s", expectedMetrics, metrics)
|
||||
@@ -580,7 +583,8 @@ func testV1STSProcessMetricsWithFilter(t *testing.T) {
|
||||
utils.ConcatenatedKey(utils.MetaSum, "~CustomValue"): "10",
|
||||
}
|
||||
if err := stsV1Rpc.Call(utils.StatSv1GetQueueStringMetrics,
|
||||
&utils.TenantIDWithArgDispatcher{TenantID: &utils.TenantID{Tenant: "cgrates.org", ID: expectedIDs[0]}}, &metrics); err != nil {
|
||||
&utils.TenantIDWithArgDispatcher{
|
||||
TenantID: &utils.TenantID{Tenant: "cgrates.org", ID: expectedIDs[0]}}, &metrics); err != nil {
|
||||
t.Error(err)
|
||||
} else if !reflect.DeepEqual(expectedMetrics, metrics) {
|
||||
t.Errorf("expecting: %+v, received reply: %s", expectedMetrics, metrics)
|
||||
@@ -658,7 +662,8 @@ func testV1STSProcessStaticMetrics(t *testing.T) {
|
||||
utils.ConcatenatedKey(utils.MetaAverage, "2"): "2",
|
||||
}
|
||||
if err := stsV1Rpc.Call(utils.StatSv1GetQueueStringMetrics,
|
||||
&utils.TenantIDWithArgDispatcher{TenantID: &utils.TenantID{Tenant: "cgrates.org", ID: expectedIDs[0]}}, &metrics); err != nil {
|
||||
&utils.TenantIDWithArgDispatcher{
|
||||
TenantID: &utils.TenantID{Tenant: "cgrates.org", ID: expectedIDs[0]}}, &metrics); err != nil {
|
||||
t.Error(err)
|
||||
} else if !reflect.DeepEqual(expectedMetrics, metrics) {
|
||||
t.Errorf("expecting: %+v, received reply: %s", expectedMetrics, metrics)
|
||||
@@ -674,7 +679,8 @@ func testV1STSProcessStaticMetrics(t *testing.T) {
|
||||
utils.ConcatenatedKey(utils.MetaAverage, "2"): "2",
|
||||
}
|
||||
if err := stsV1Rpc.Call(utils.StatSv1GetQueueStringMetrics,
|
||||
&utils.TenantIDWithArgDispatcher{TenantID: &utils.TenantID{Tenant: "cgrates.org", ID: expectedIDs[0]}}, &metrics); err != nil {
|
||||
&utils.TenantIDWithArgDispatcher{
|
||||
TenantID: &utils.TenantID{Tenant: "cgrates.org", ID: expectedIDs[0]}}, &metrics); err != nil {
|
||||
t.Error(err)
|
||||
} else if !reflect.DeepEqual(expectedMetrics, metrics) {
|
||||
t.Errorf("expecting: %+v, received reply: %s", expectedMetrics, metrics)
|
||||
@@ -725,7 +731,7 @@ func testV1STSProcessStatWithThreshold(t *testing.T) {
|
||||
Tenant: "cgrates.org",
|
||||
ID: "THD_Stat",
|
||||
FilterIDs: []string{"*string:~*req.EventType:StatUpdate",
|
||||
"*string:~StatID:StatWithThreshold", "*exists:*tcd:", "*gte:~*tcd:1s"},
|
||||
"*string:~*req.StatID:StatWithThreshold", "*exists:~*req.*tcd:", "*gte:~*req.*tcd:1s"},
|
||||
ActivationInterval: &utils.ActivationInterval{
|
||||
ActivationTime: time.Date(2014, 7, 14, 14, 35, 0, 0, time.UTC),
|
||||
},
|
||||
|
||||
@@ -161,9 +161,9 @@ func (self *CsvRecordsProcessor) recordToStoredCdr(record []string, cdrcCfg *con
|
||||
if utils.SliceHasMember([]string{utils.MetaKamFlatstore, utils.MetaOsipsFlatstore}, self.dfltCdrcCfg.CdrFormat) { // Hardcode some values in case of flatstore
|
||||
switch cdrFldCfg.FieldId {
|
||||
case utils.OriginID:
|
||||
cdrFldCfg.Value = config.NewRSRParsersMustCompile("~3;~1;~2", true, utils.INFIELD_SEP) // in case of flatstore, accounting id is made up out of callid, from_tag and to_tag
|
||||
cdrFldCfg.Value = config.NewRSRParsersMustCompile("~*req.3;~*req.1;~*req.2", true, utils.INFIELD_SEP) // in case of flatstore, accounting id is made up out of callid, from_tag and to_tag
|
||||
case utils.Usage:
|
||||
cdrFldCfg.Value = config.NewRSRParsersMustCompile("~"+strconv.Itoa(len(record)-1), true, utils.INFIELD_SEP) // in case of flatstore, last element will be the duration computed by us
|
||||
cdrFldCfg.Value = config.NewRSRParsersMustCompile("~*req."+strconv.Itoa(len(record)-1), true, utils.INFIELD_SEP) // in case of flatstore, last element will be the duration computed by us
|
||||
}
|
||||
}
|
||||
switch cdrFldCfg.Type {
|
||||
|
||||
@@ -501,7 +501,7 @@ func TestCsvIT5AddFilters(t *testing.T) {
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
Type: "*string",
|
||||
FieldName: "~3",
|
||||
FieldName: "~*req.3",
|
||||
Values: []string{"1002"},
|
||||
},
|
||||
},
|
||||
@@ -518,7 +518,7 @@ func TestCsvIT5AddFilters(t *testing.T) {
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
Type: "*string",
|
||||
FieldName: "~3",
|
||||
FieldName: "~*req.3",
|
||||
Values: []string{"1001"},
|
||||
},
|
||||
},
|
||||
|
||||
@@ -468,12 +468,12 @@ func TestXmlIT5AddFilters(t *testing.T) {
|
||||
Rules: []*engine.FilterRule{
|
||||
{
|
||||
Type: "*string",
|
||||
FieldName: "~broadWorksCDR.cdrData.basicModule.userNumber",
|
||||
FieldName: "~*req.broadWorksCDR.cdrData.basicModule.userNumber",
|
||||
Values: []string{"1002"},
|
||||
},
|
||||
{
|
||||
Type: "*string",
|
||||
FieldName: "~broadWorksCDR.cdrData.headerModule.type",
|
||||
FieldName: "~*req.broadWorksCDR.cdrData.headerModule.type",
|
||||
Values: []string{"Normal"},
|
||||
},
|
||||
},
|
||||
|
||||
@@ -37,22 +37,22 @@
|
||||
"partial_cache_expiry_action": "*dump_to_file",
|
||||
"content_fields":[ // import content_fields template, tag will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "ToR", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "AccId1", "field_id": "OriginID", "type": "*composed", "value": "~0"},
|
||||
{"tag": "AccId1", "field_id": "OriginID", "type": "*composed", "value": "~*req.0"},
|
||||
{"tag": "AccId2", "field_id": "OriginID", "type": "*composed", "value": "_"},
|
||||
{"tag": "AccId3", "field_id": "OriginID", "type": "*composed", "value": "~1"},
|
||||
{"tag": "AccId3", "field_id": "OriginID", "type": "*composed", "value": "~*req.1"},
|
||||
{"tag": "AccId4", "field_id": "OriginID", "type": "*composed", "value": "_"},
|
||||
{"tag": "AccId5", "field_id": "OriginID", "type": "*composed", "value": "~4"},
|
||||
{"tag": "OrderID", "field_id": "OrderID", "type": "*unix_timestamp", "value": "~3"},
|
||||
{"tag": "AccId5", "field_id": "OriginID", "type": "*composed", "value": "~*req.4"},
|
||||
{"tag": "OrderID", "field_id": "OrderID", "type": "*unix_timestamp", "value": "~*req.3"},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "*rated", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "*out", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "cgrates.org", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~0:s/^49([1-9]\\d+)$/0$1/", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~1:s/^00(\\d+)$/+$1/", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~4", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~4", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~6:s/^(\\d+)$/${1}s/", "mandatory": true},
|
||||
{"tag": "Partial", "field_id": "Partial", "type": "*composed", "value": "true", "filters":["*string:~10:partial"]},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.0:s/^49([1-9]\\d+)$/0$1/", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.1:s/^00(\\d+)$/+$1/", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.4", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.4", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~*req.6:s/^(\\d+)$/${1}s/", "mandatory": true},
|
||||
{"tag": "Partial", "field_id": "Partial", "type": "*composed", "value": "true", "filters":["*string:~*req.10:partial"]},
|
||||
],
|
||||
"cache_dump_fields": [
|
||||
{"tag": "OriginID", "type": "*composed", "value": "~OriginID"},
|
||||
@@ -77,22 +77,22 @@
|
||||
"partial_cache_expiry_action": "*post_cdr",
|
||||
"content_fields":[ // import content_fields template, tag will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "ToR", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "AccId1", "field_id": "OriginID", "type": "*composed", "value": "~0"},
|
||||
{"tag": "AccId1", "field_id": "OriginID", "type": "*composed", "value": "~*req.0"},
|
||||
{"tag": "AccId2", "field_id": "OriginID", "type": "*composed", "value": "_"},
|
||||
{"tag": "AccId3", "field_id": "OriginID", "type": "*composed", "value": "~1"},
|
||||
{"tag": "AccId3", "field_id": "OriginID", "type": "*composed", "value": "~*req.1"},
|
||||
{"tag": "AccId4", "field_id": "OriginID", "type": "*composed", "value": "_"},
|
||||
{"tag": "AccId5", "field_id": "OriginID", "type": "*composed", "value": "~4"},
|
||||
{"tag": "OrderID", "field_id": "OrderID", "type": "*unix_timestamp", "value": "~3"},
|
||||
{"tag": "AccId5", "field_id": "OriginID", "type": "*composed", "value": "~*req.4"},
|
||||
{"tag": "OrderID", "field_id": "OrderID", "type": "*unix_timestamp", "value": "~*req.3"},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "*rated", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "*out", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "cgrates.org", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~0:s/^49([1-9]\\d+)$/0$1/", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~1:s/^00(\\d+)$/+$1/", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~4", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~4", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~6:s/^(\\d+)$/${1}s/", "mandatory": true},
|
||||
{"tag": "Partial", "field_id": "Partial", "type": "*composed", "value": "true", "filters":["*string:~10:partial"]},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.0:s/^49([1-9]\\d+)$/0$1/", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.1:s/^00(\\d+)$/+$1/", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.4", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.4", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~*req.6:s/^(\\d+)$/${1}s/", "mandatory": true},
|
||||
{"tag": "Partial", "field_id": "Partial", "type": "*composed", "value": "true", "filters":["*string:~*req.10:partial"]},
|
||||
],
|
||||
},
|
||||
],
|
||||
|
||||
@@ -45,20 +45,20 @@
|
||||
"cdr_source_id": "csvit2", // free form field, tag identifying the source of the CDRs within CDRS database
|
||||
"content_fields":[ // import content_fields template, tag will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "TOR", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~0", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "~1", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~*req.0", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "~*req.1", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "*out", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "~2", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "~*req.2", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~3", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~3", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~4:s/0([1-9]\\d+)/+49${1}/", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~5", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~5", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "HDRExtra3", "field_id": "HDRExtra3", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "HDRExtra2", "field_id": "HDRExtra2", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "HDRExtra1", "field_id": "HDRExtra1", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.3", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~*req.3", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.4:s/0([1-9]\\d+)/+49${1}/", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.5", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.5", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "HDRExtra3", "field_id": "HDRExtra3", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "HDRExtra2", "field_id": "HDRExtra2", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "HDRExtra1", "field_id": "HDRExtra1", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
],
|
||||
},
|
||||
{
|
||||
@@ -68,23 +68,23 @@
|
||||
"cdr_in_path": "/tmp/csvwithfilter1/csvit1/in", // absolute path towards the directory where the CDRs are stored
|
||||
"cdr_out_path": "/tmp/csvwithfilter1/csvit1/out", // absolute path towards the directory where processed CDRs will be moved
|
||||
"cdr_source_id": "csvit1", // free form field, tag identifying the source of the CDRs within CDRS database
|
||||
"filters":["*string:~3:1002"], //filter Account to be 1002
|
||||
"filters":["*string:~*req.3:1002"], //filter Account to be 1002
|
||||
"content_fields":[ // import content_fields template, tag will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "TOR", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~0", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "~1", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~*req.0", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "~*req.1", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "*out", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "~2", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "~*req.2", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~3", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~3", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~4:s/0([1-9]\\d+)/+49${1}/", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~5", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~5", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "HDRExtra3", "field_id": "HDRExtra3", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "HDRExtra2", "field_id": "HDRExtra2", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "HDRExtra1", "field_id": "HDRExtra1", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.3", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~*req.3", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.4:s/0([1-9]\\d+)/+49${1}/", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.5", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.5", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "HDRExtra3", "field_id": "HDRExtra3", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "HDRExtra2", "field_id": "HDRExtra2", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "HDRExtra1", "field_id": "HDRExtra1", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
],
|
||||
},
|
||||
{
|
||||
@@ -94,23 +94,23 @@
|
||||
"cdr_in_path": "/tmp/csvwithfilter2/csvit2/in", // absolute path towards the directory where the CDRs are stored
|
||||
"cdr_out_path": "/tmp/csvwithfilter2/csvit2/out", // absolute path towards the directory where processed CDRs will be moved
|
||||
"cdr_source_id": "csvit2", // free form field, tag identifying the source of the CDRs within CDRS database
|
||||
"filters":["*string:~3:1002","*string:~1:*prepaid","*gte:~6:70"], //filter Account to be 1002 and RequestType *prepaid
|
||||
"filters":["*string:~*req.3:1002","*string:~*req.1:*prepaid","*gte:~*req.6:70"], //filter Account to be 1002 and RequestType *prepaid
|
||||
"content_fields":[ // import content_fields template, tag will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "TOR", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~0", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "~1", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~*req.0", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "~*req.1", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "*out", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "~2", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "~*req.2", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~3", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~3", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~4:s/0([1-9]\\d+)/+49${1}/", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~5", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~5", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "HDRExtra3", "field_id": "HDRExtra3", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "HDRExtra2", "field_id": "HDRExtra2", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "HDRExtra1", "field_id": "HDRExtra1", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.3", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~*req.3", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.4:s/0([1-9]\\d+)/+49${1}/", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.5", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.5", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "HDRExtra3", "field_id": "HDRExtra3", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "HDRExtra2", "field_id": "HDRExtra2", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "HDRExtra1", "field_id": "HDRExtra1", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
],
|
||||
},
|
||||
{
|
||||
@@ -120,24 +120,24 @@
|
||||
"cdr_in_path": "/tmp/csvwithfilter3/csvit3/in", // absolute path towards the directory where the CDRs are stored
|
||||
"cdr_out_path": "/tmp/csvwithfilter3/csvit3/out", // absolute path towards the directory where processed CDRs will be moved
|
||||
"cdr_source_id": "csvit4", // free form field, tag identifying the source of the CDRs within CDRS database
|
||||
"filters":["*string:~1:*postpaid"], //filter Account to be 1002
|
||||
"filters":["*string:~*req.1:*postpaid"], //filter Account to be 1002
|
||||
"content_fields":[ // import content_fields template, tag will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "TOR", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~0", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "~1", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~*req.0", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "~*req.1", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "*out", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "~2", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "~*req.2", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~3", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~3", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~4:s/0([1-9]\\d+)/+49${1}/", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~5", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~5", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "HDRExtra3", "field_id": "HDRExtra3", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "HDRExtra2", "field_id": "HDRExtra2", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "HDRExtra1", "field_id": "HDRExtra1", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "RandomVal", "field_id": "RandomVal", "type": "*composed", "value": "*randomValue","filters":["*string:~3:1001"]},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.3", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~*req.3", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.4:s/0([1-9]\\d+)/+49${1}/", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.5", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.5", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "HDRExtra3", "field_id": "HDRExtra3", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "HDRExtra2", "field_id": "HDRExtra2", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "HDRExtra1", "field_id": "HDRExtra1", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "RandomVal", "field_id": "RandomVal", "type": "*composed", "value": "*randomValue","filters":["*string:~*req.3:1001"]},
|
||||
],
|
||||
},
|
||||
{
|
||||
@@ -146,27 +146,27 @@
|
||||
"field_separator": ";",
|
||||
"cdr_in_path": "/tmp/csvwithfilter4/csvit4/in", // absolute path towards the directory where the CDRs are stored
|
||||
"cdr_out_path": "/tmp/csvwithfilter4/csvit4/out", // absolute path towards the directory where processed CDRs will be moved
|
||||
"tenant": "~2", // tenant used in filterS.Pass
|
||||
"tenant": "~*req.2", // tenant used in filterS.Pass
|
||||
"filters":["FLTR_CDRC_ACC"], // if tenant is itsyscom.com will check if Account is 1001 and if tenant is cgrates.org will check if Account is 1002
|
||||
"cdr_source_id": "diffTenant", // free form field, tag identifying the source of the CDRs within CDRS database
|
||||
"content_fields":[ // import content_fields template, tag will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "TOR", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~0", "mandatory": true},
|
||||
{"tag": "OriginHost", "field_id": "OriginHost", "type": "*composed", "value": "~10", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "~1", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~*req.0", "mandatory": true},
|
||||
{"tag": "OriginHost", "field_id": "OriginHost", "type": "*composed", "value": "~*req.10", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "~*req.1", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "*out", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "~2", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "~*req.2", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~3", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~3", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~4:s/0([1-9]\\d+)/+49${1}/", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~5", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~5", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "HDRExtra3", "field_id": "HDRExtra3", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "HDRExtra2", "field_id": "HDRExtra2", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "HDRExtra1", "field_id": "HDRExtra1", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "RandomVal", "field_id": "RandomVal", "type": "*composed", "value": "*randomValue","filters":["*string:~3:1001"]},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.3", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~*req.3", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.4:s/0([1-9]\\d+)/+49${1}/", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.5", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.5", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "HDRExtra3", "field_id": "HDRExtra3", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "HDRExtra2", "field_id": "HDRExtra2", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "HDRExtra1", "field_id": "HDRExtra1", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "RandomVal", "field_id": "RandomVal", "type": "*composed", "value": "*randomValue","filters":["*string:~*req.3:1001"]},
|
||||
],
|
||||
},
|
||||
],
|
||||
|
||||
@@ -52,18 +52,18 @@
|
||||
"content_fields":[ // import template, id will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "Tor", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "~7", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "~*req.7", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "out", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "cgrates.org", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~8", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~8", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~9", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~6", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.8", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~*req.8", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.9", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.6", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "mandatory": true},
|
||||
{"tag": "DisconnectCause", "field_id": "DisconnectCause", "type": "*composed", "value": "~4; ;~5", "mandatory": true},
|
||||
{"tag": "DialogId", "field_id": "DialogId", "type": "*composed", "value": "~11"},
|
||||
{"tag": "DisconnectCause", "field_id": "DisconnectCause", "type": "*composed", "value": "~*req.4; ;~*req.5", "mandatory": true},
|
||||
{"tag": "DialogId", "field_id": "DialogId", "type": "*composed", "value": "~*req.11"},
|
||||
],
|
||||
},
|
||||
],
|
||||
|
||||
@@ -45,32 +45,32 @@
|
||||
"cdr_out_path": "/tmp/cgr_fwv/cdrc/out", // absolute path towards the directory where processed CDRs will be moved
|
||||
"cdr_source_id": "cdrc", // free form field, tag identifying the source of the CDRs within CDRS database
|
||||
"header_fields": [
|
||||
{"tag": "FileName", "field_id": "CdrFileName", "type": "*composed", "value": "~95-135", "padding":"right"},
|
||||
{"tag": "FileSeqNr", "field_id": "FileSeqNr", "type": "*composed", "value": "~135-141", "padding":"zeroleft"},
|
||||
{"tag": "AccId1", "field_id": "AccId1", "type": "*composed", "value": "~135-141", "padding":"zeroleft"},
|
||||
{"tag": "FileName", "field_id": "CdrFileName", "type": "*composed", "value": "~*req.95-135", "padding":"right"},
|
||||
{"tag": "FileSeqNr", "field_id": "FileSeqNr", "type": "*composed", "value": "~*req.135-141", "padding":"zeroleft"},
|
||||
{"tag": "AccId1", "field_id": "AccId1", "type": "*composed", "value": "~*req.135-141", "padding":"zeroleft"},
|
||||
],
|
||||
"content_fields": [ // import template, id will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "Tor", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "rated", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "*out", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~0-10", "padding":"right", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~*req.0-10", "padding":"right", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "cgrates.org", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~30-49", "padding":"right", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~30-49", "padding":"right", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~52-80", "padding":"right", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~14-30:s/(\\d{4})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}-${2}-${3} ${4}:${5}:${6}/", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~14-30:s/(\\d{4})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}-${2}-${3} ${4}:${5}:${6}/", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~127-135:s/(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}h${2}m${3}s/", "mandatory": true},
|
||||
{"tag": "DisconnectCause", "field_id": "DisconnectCause", "type": "*composed", "value": "~138-139", "mandatory": true},
|
||||
{"tag": "RetailAmount", "field_id": "RetailAmount", "type": "*composed", "value": "~103-111", "padding":"zeroleft"},
|
||||
{"tag": "WholesaleAmount", "field_id": "RetailAmount", "type": "*composed", "value": "~115-123", "padding":"zeroleft"},
|
||||
{"tag": "AccId1", "field_id": "AccId1", "type": "*composed", "value": "~3-6", "padding":"zeroleft", "mandatory": true},
|
||||
{"tag": "AccId2", "field_id": "AccId2", "type": "*composed", "value": "~14-30", "padding":"right", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.30-49", "padding":"right", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~*req.30-49", "padding":"right", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.52-80", "padding":"right", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.14-30:s/(\\d{4})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}-${2}-${3} ${4}:${5}:${6}/", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.14-30:s/(\\d{4})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}-${2}-${3} ${4}:${5}:${6}/", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~*req.127-135:s/(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}h${2}m${3}s/", "mandatory": true},
|
||||
{"tag": "DisconnectCause", "field_id": "DisconnectCause", "type": "*composed", "value": "~*req.138-139", "mandatory": true},
|
||||
{"tag": "RetailAmount", "field_id": "RetailAmount", "type": "*composed", "value": "~*req.103-111", "padding":"zeroleft"},
|
||||
{"tag": "WholesaleAmount", "field_id": "RetailAmount", "type": "*composed", "value": "~*req.115-123", "padding":"zeroleft"},
|
||||
{"tag": "AccId1", "field_id": "AccId1", "type": "*composed", "value": "~*req.3-6", "padding":"zeroleft", "mandatory": true},
|
||||
{"tag": "AccId2", "field_id": "AccId2", "type": "*composed", "value": "~*req.14-30", "padding":"right", "mandatory": true},
|
||||
],
|
||||
"trailer_fields": [
|
||||
{"tag": "NrOfCdrs", "type": "metatag", "metatag_id":"total_cdrs", "value": "~142-150"},
|
||||
{"tag": "TotalDuration", "type": "metatag", "metatag_id":"total_duration", "value": "~150-162"},
|
||||
{"tag": "NrOfCdrs", "type": "metatag", "metatag_id":"total_cdrs", "value": "~*req.142-150"},
|
||||
{"tag": "TotalDuration", "type": "metatag", "metatag_id":"total_duration", "value": "~*req.150-162"},
|
||||
],
|
||||
},
|
||||
],
|
||||
|
||||
@@ -45,34 +45,34 @@
|
||||
"cdr_in_path": "/tmp/cgr_fwv/cdrc/in", // absolute path towards the directory where the CDRs are stored
|
||||
"cdr_out_path": "/tmp/cgr_fwv/cdrc/out", // absolute path towards the directory where processed CDRs will be moved
|
||||
"cdr_source_id": "cdrc", // free form field, id identifying the source of the CDRs within CDRS database
|
||||
"filters":["*string:~0-10:CDR0000010"],
|
||||
"filters":["*string:~*req.0-10:CDR0000010"],
|
||||
"header_fields": [
|
||||
{"tag": "FileName", "field_id": "CdrFileName", "type": "*composed", "value": "~95-135", "padding":"right"},
|
||||
{"tag": "FileSeqNr", "field_id": "FileSeqNr", "type": "*composed", "value": "~135-141", "padding":"zeroleft"},
|
||||
{"tag": "AccId1", "field_id": "AccId1", "type": "*composed", "value": "~135-141", "padding":"zeroleft"},
|
||||
{"tag": "FileName", "field_id": "CdrFileName", "type": "*composed", "value": "~*req.95-135", "padding":"right"},
|
||||
{"tag": "FileSeqNr", "field_id": "FileSeqNr", "type": "*composed", "value": "~*req.135-141", "padding":"zeroleft"},
|
||||
{"tag": "AccId1", "field_id": "AccId1", "type": "*composed", "value": "~*req.135-141", "padding":"zeroleft"},
|
||||
],
|
||||
"content_fields": [ // import template, id will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "Tor", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "rated", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "*out", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~0-10", "padding":"right", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~*req.0-10", "padding":"right", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "cgrates.org", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~30-49", "padding":"right", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~30-49", "padding":"right", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~52-80", "padding":"right", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~14-30:s/(\\d{4})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}-${2}-${3} ${4}:${5}:${6}/", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~14-30:s/(\\d{4})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}-${2}-${3} ${4}:${5}:${6}/", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~127-135:s/(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}h${2}m${3}s/", "mandatory": true},
|
||||
{"tag": "DisconnectCause", "field_id": "DisconnectCause", "type": "*composed", "value": "~138-139", "mandatory": true},
|
||||
{"tag": "RetailAmount", "field_id": "RetailAmount", "type": "*composed", "value": "~103-111", "padding":"zeroleft"},
|
||||
{"tag": "WholesaleAmount", "field_id": "RetailAmount", "type": "*composed", "value": "~115-123", "padding":"zeroleft"},
|
||||
{"tag": "AccId1", "field_id": "AccId1", "type": "*composed", "value": "~3-6", "padding":"zeroleft", "mandatory": true},
|
||||
{"tag": "AccId2", "field_id": "AccId2", "type": "*composed", "value": "~14-30", "padding":"right", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.30-49", "padding":"right", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~*req.30-49", "padding":"right", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.52-80", "padding":"right", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.14-30:s/(\\d{4})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}-${2}-${3} ${4}:${5}:${6}/", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.14-30:s/(\\d{4})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}-${2}-${3} ${4}:${5}:${6}/", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~*req.127-135:s/(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}h${2}m${3}s/", "mandatory": true},
|
||||
{"tag": "DisconnectCause", "field_id": "DisconnectCause", "type": "*composed", "value": "~*req.138-139", "mandatory": true},
|
||||
{"tag": "RetailAmount", "field_id": "RetailAmount", "type": "*composed", "value": "~*req.103-111", "padding":"zeroleft"},
|
||||
{"tag": "WholesaleAmount", "field_id": "RetailAmount", "type": "*composed", "value": "~*req.115-123", "padding":"zeroleft"},
|
||||
{"tag": "AccId1", "field_id": "AccId1", "type": "*composed", "value": "~*req.3-6", "padding":"zeroleft", "mandatory": true},
|
||||
{"tag": "AccId2", "field_id": "AccId2", "type": "*composed", "value": "~*req.14-30", "padding":"right", "mandatory": true},
|
||||
],
|
||||
"trailer_fields": [
|
||||
{"tag": "NrOfCdrs", "type": "metatag", "metatag_id":"total_cdrs", "value": "~142-150"},
|
||||
{"tag": "TotalDuration", "type": "metatag", "metatag_id":"total_duration", "value": "~150-162"},
|
||||
{"tag": "NrOfCdrs", "type": "metatag", "metatag_id":"total_cdrs", "value": "~*req.142-150"},
|
||||
{"tag": "TotalDuration", "type": "metatag", "metatag_id":"total_duration", "value": "~*req.150-162"},
|
||||
],
|
||||
},
|
||||
|
||||
@@ -89,32 +89,32 @@
|
||||
"cdr_source_id": "cdrc", // free form field, id identifying the source of the CDRs within CDRS database
|
||||
"filters":["FLTR_FWV"],
|
||||
"header_fields": [
|
||||
{"tag": "FileName", "field_id": "CdrFileName", "type": "*composed", "value": "~95-135", "padding":"right"},
|
||||
{"tag": "FileSeqNr", "field_id": "FileSeqNr", "type": "*composed", "value": "~135-141", "padding":"zeroleft"},
|
||||
{"tag": "AccId1", "field_id": "AccId1", "type": "*composed", "value": "~135-141", "padding":"zeroleft"},
|
||||
{"tag": "FileName", "field_id": "CdrFileName", "type": "*composed", "value": "~*req.95-135", "padding":"right"},
|
||||
{"tag": "FileSeqNr", "field_id": "FileSeqNr", "type": "*composed", "value": "~*req.135-141", "padding":"zeroleft"},
|
||||
{"tag": "AccId1", "field_id": "AccId1", "type": "*composed", "value": "~*req.135-141", "padding":"zeroleft"},
|
||||
],
|
||||
"content_fields": [ // import template, id will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "Tor", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "rated", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "*out", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~0-10", "padding":"right", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~*req.0-10", "padding":"right", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "cgrates.org", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~30-49", "padding":"right", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~30-49", "padding":"right", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~52-80", "padding":"right", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~14-30:s/(\\d{4})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}-${2}-${3} ${4}:${5}:${6}/", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~14-30:s/(\\d{4})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}-${2}-${3} ${4}:${5}:${6}/", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~127-135:s/(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}h${2}m${3}s/", "mandatory": true},
|
||||
{"tag": "DisconnectCause", "field_id": "DisconnectCause", "type": "*composed", "value": "~138-139", "mandatory": true},
|
||||
{"tag": "RetailAmount", "field_id": "RetailAmount", "type": "*composed", "value": "~103-111", "padding":"zeroleft"},
|
||||
{"tag": "WholesaleAmount", "field_id": "RetailAmount", "type": "*composed", "value": "~115-123", "padding":"zeroleft"},
|
||||
{"tag": "AccId1", "field_id": "AccId1", "type": "*composed", "value": "~3-6", "padding":"zeroleft", "mandatory": true},
|
||||
{"tag": "AccId2", "field_id": "AccId2", "type": "*composed", "value": "~14-30", "padding":"right", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.30-49", "padding":"right", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~*req.30-49", "padding":"right", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.52-80", "padding":"right", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.14-30:s/(\\d{4})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}-${2}-${3} ${4}:${5}:${6}/", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.14-30:s/(\\d{4})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}-${2}-${3} ${4}:${5}:${6}/", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*composed", "value": "~*req.127-135:s/(\\d{2})(\\d{2})(\\d{2})(\\d{2})/${1}h${2}m${3}s/", "mandatory": true},
|
||||
{"tag": "DisconnectCause", "field_id": "DisconnectCause", "type": "*composed", "value": "~*req.138-139", "mandatory": true},
|
||||
{"tag": "RetailAmount", "field_id": "RetailAmount", "type": "*composed", "value": "~*req.103-111", "padding":"zeroleft"},
|
||||
{"tag": "WholesaleAmount", "field_id": "RetailAmount", "type": "*composed", "value": "~*req.115-123", "padding":"zeroleft"},
|
||||
{"tag": "AccId1", "field_id": "AccId1", "type": "*composed", "value": "~*req.3-6", "padding":"zeroleft", "mandatory": true},
|
||||
{"tag": "AccId2", "field_id": "AccId2", "type": "*composed", "value": "~*req.14-30", "padding":"right", "mandatory": true},
|
||||
],
|
||||
"trailer_fields": [
|
||||
{"tag": "NrOfCdrs", "type": "metatag", "metatag_id":"total_cdrs", "value": "~142-150"},
|
||||
{"tag": "TotalDuration", "type": "metatag", "metatag_id":"total_duration", "value": "~150-162"},
|
||||
{"tag": "NrOfCdrs", "type": "metatag", "metatag_id":"total_cdrs", "value": "~*req.142-150"},
|
||||
{"tag": "TotalDuration", "type": "metatag", "metatag_id":"total_duration", "value": "~*req.150-162"},
|
||||
],
|
||||
},
|
||||
],
|
||||
|
||||
@@ -32,16 +32,16 @@
|
||||
"cdr_source_id": "xmlit1",
|
||||
"content_fields":[ // import content_fields template, id will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "TOR", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.localCallId", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.localCallId", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "*rated", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "*out", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.userId:s/.*@(.*)/${1}/", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.userId:s/.*@(.*)/${1}/", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.userNumber", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.calledNumber", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.startTime", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.answerTime", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*handler", "handler_id": "*substract_usage", "value": "~broadWorksCDR.cdrData.basicModule.releaseTime;|;~broadWorksCDR.cdrData.basicModule.answerTime", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.userNumber", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.calledNumber", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.startTime", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.answerTime", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*handler", "handler_id": "*substract_usage", "value": "~*req.broadWorksCDR.cdrData.basicModule.releaseTime;|;~*req.broadWorksCDR.cdrData.basicModule.answerTime", "mandatory": true},
|
||||
],
|
||||
},
|
||||
],
|
||||
|
||||
@@ -30,19 +30,19 @@
|
||||
"cdr_out_path": "/tmp/cdrcxmlwithfilters/xmlit1/out",
|
||||
"cdr_root_path": "broadWorksCDR.cdrData",
|
||||
"cdr_source_id": "xmlit1",
|
||||
"filters": ["*string:~broadWorksCDR.cdrData.basicModule.userNumber:1002","*string:~broadWorksCDR.cdrData.headerModule.type:Normal"],
|
||||
"filters": ["*string:~*req.broadWorksCDR.cdrData.basicModule.userNumber:1002","*string:~*req.broadWorksCDR.cdrData.headerModule.type:Normal"],
|
||||
"content_fields":[ // import content_fields template, id will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "TOR", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.localCallId", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.localCallId", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "*rated", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "*out", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.userId:s/.*@(.*)/${1}/", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.userId:s/.*@(.*)/${1}/", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.userNumber", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.calledNumber", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.startTime", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.answerTime", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*handler", "handler_id": "*substract_usage", "value": "~broadWorksCDR.cdrData.basicModule.releaseTime;|;~broadWorksCDR.cdrData.basicModule.answerTime", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.userNumber", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.calledNumber", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.startTime", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.answerTime", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*handler", "handler_id": "*substract_usage", "value": "~*req.broadWorksCDR.cdrData.basicModule.releaseTime;|;~*req.broadWorksCDR.cdrData.basicModule.answerTime", "mandatory": true},
|
||||
],
|
||||
},
|
||||
{
|
||||
@@ -55,17 +55,17 @@
|
||||
"cdr_source_id": "zw_cfs1", // free form field, tag identifying the source of the CDRs within CDRS database
|
||||
"content_fields":[ // import content_fields template, id will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "TOR", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~File.CDRs.Call.SignalingInfo.PChargingVector.icidvalue", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~*req.File.CDRs.Call.SignalingInfo.PChargingVector.icidvalue", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "*rated", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "*out", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "XX.liquid.tel", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~File.CDRs.Call.OrigParty.SubscriberAddr", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~File.CDRs.Call.OrigParty.SubscriberAddr", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~File.CDRs.Call.RoutingInfo.DestAddr", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~File.CDRs.Call.RingingTime", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~File.CDRs.Call.ConnectTime", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*handler", "handler_id": "*substract_usage", "value": "~File.CDRs.Call.ReleaseTime;|;~File.CDRs.Call.ConnectTime", "mandatory": true}
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.File.CDRs.Call.OrigParty.SubscriberAddr", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~*req.File.CDRs.Call.OrigParty.SubscriberAddr", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.File.CDRs.Call.RoutingInfo.DestAddr", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.File.CDRs.Call.RingingTime", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.File.CDRs.Call.ConnectTime", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*handler", "handler_id": "*substract_usage", "value": "~*req.File.CDRs.Call.ReleaseTime;|;~*req.File.CDRs.Call.ConnectTime", "mandatory": true}
|
||||
],
|
||||
},
|
||||
{
|
||||
@@ -78,19 +78,19 @@
|
||||
"cdr_source_id": "zw_cfs1", // free form field, tag identifying the source of the CDRs within CDRS database
|
||||
"content_fields":[ // import content_fields template, id will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "TOR", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~File.CDRs.Call.SignalingInfo.PChargingVector.icidvalue", "mandatory": true},
|
||||
{"tag": "OriginID2", "field_id": "OriginID", "type": "*composed", "value": "~File.CDRs.Call.OrigParty.SIPCallId:s/^(.*)@.*/$1/", "mandatory": true},
|
||||
{"tag": "OriginHost", "field_id": "OriginHost", "type": "*composed", "value": "~File.CDRs.Call.OrigParty.SIPCallId:s/^.*@(.*)/$1/", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~*req.File.CDRs.Call.SignalingInfo.PChargingVector.icidvalue", "mandatory": true},
|
||||
{"tag": "OriginID2", "field_id": "OriginID", "type": "*composed", "value": "~*req.File.CDRs.Call.OrigParty.SIPCallId:s/^(.*)@.*/$1/", "mandatory": true},
|
||||
{"tag": "OriginHost", "field_id": "OriginHost", "type": "*composed", "value": "~*req.File.CDRs.Call.OrigParty.SIPCallId:s/^.*@(.*)/$1/", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "*rated", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "*out", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "XX.liquid.tel", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~File.CDRs.Call.OrigParty.SubscriberAddr", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~File.CDRs.Call.OrigParty.SubscriberAddr", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~File.CDRs.Call.RoutingInfo.DestAddr", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~File.CDRs.Call.RingingTime", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~File.CDRs.Call.ConnectTime", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*handler", "handler_id": "*substract_usage", "value": "~File.CDRs.Call.ReleaseTime;|;~File.CDRs.Call.ConnectTime", "mandatory": true}
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.File.CDRs.Call.OrigParty.SubscriberAddr", "mandatory": true},
|
||||
{"tag": "Subject", "field_id": "Subject", "type": "*composed", "value": "~*req.File.CDRs.Call.OrigParty.SubscriberAddr", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.File.CDRs.Call.RoutingInfo.DestAddr", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.File.CDRs.Call.RingingTime", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.File.CDRs.Call.ConnectTime", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*handler", "handler_id": "*substract_usage", "value": "~*req.File.CDRs.Call.ReleaseTime;|;~*req.File.CDRs.Call.ConnectTime", "mandatory": true}
|
||||
],
|
||||
},
|
||||
{
|
||||
@@ -104,16 +104,16 @@
|
||||
"filters": ["FLTR_XML"],
|
||||
"content_fields":[ // import content_fields template, id will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "TOR", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.localCallId", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.localCallId", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "*rated", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "*out", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.userId:s/.*@(.*)/${1}/", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.userId:s/.*@(.*)/${1}/", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.userNumber", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.calledNumber", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.startTime", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~broadWorksCDR.cdrData.basicModule.answerTime", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*handler", "handler_id": "*substract_usage", "value": "~broadWorksCDR.cdrData.basicModule.releaseTime;|;~broadWorksCDR.cdrData.basicModule.answerTime", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.userNumber", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.calledNumber", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.startTime", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.broadWorksCDR.cdrData.basicModule.answerTime", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*handler", "handler_id": "*substract_usage", "value": "~*req.broadWorksCDR.cdrData.basicModule.releaseTime;|;~*req.broadWorksCDR.cdrData.basicModule.answerTime", "mandatory": true},
|
||||
],
|
||||
},
|
||||
{
|
||||
@@ -126,16 +126,16 @@
|
||||
"cdr_source_id": "xmlit1",
|
||||
"content_fields":[ // import content_fields template, id will match internally CDR field, in case of .csv value will be represented by index of the field value
|
||||
{"tag": "TOR", "field_id": "ToR", "type": "*composed", "value": "*voice", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~complete-success-notification.userid", "mandatory": true},
|
||||
{"tag": "OriginID", "field_id": "OriginID", "type": "*composed", "value": "~*req.complete-success-notification.userid", "mandatory": true},
|
||||
{"tag": "RequestType", "field_id": "RequestType", "type": "*composed", "value": "*rated", "mandatory": true},
|
||||
{"tag": "Direction", "field_id": "Direction", "type": "*composed", "value": "*out", "mandatory": true},
|
||||
{"tag": "Tenant", "field_id": "Tenant", "type": "*composed", "value": "cgrates.org", "mandatory": true},
|
||||
{"tag": "Category", "field_id": "Category", "type": "*composed", "value": "call", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~complete-success-notification.callleg.number", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~complete-success-notification.callleg[1].number", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~complete-success-notification.createtime", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~complete-success-notification.connecttime", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*handler", "handler_id": "*substract_usage", "value": "~complete-success-notification.endtime;|;~complete-success-notification.connecttime", "mandatory": true},
|
||||
{"tag": "Account", "field_id": "Account", "type": "*composed", "value": "~*req.complete-success-notification.callleg.number", "mandatory": true},
|
||||
{"tag": "Destination", "field_id": "Destination", "type": "*composed", "value": "~*req.complete-success-notification.callleg[1].number", "mandatory": true},
|
||||
{"tag": "SetupTime", "field_id": "SetupTime", "type": "*composed", "value": "~*req.complete-success-notification.createtime", "mandatory": true},
|
||||
{"tag": "AnswerTime", "field_id": "AnswerTime", "type": "*composed", "value": "~*req.complete-success-notification.connecttime", "mandatory": true},
|
||||
{"tag": "Usage", "field_id": "Usage", "type": "*handler", "handler_id": "*substract_usage", "value": "~*req.complete-success-notification.endtime;|;~*req.complete-success-notification.connecttime", "mandatory": true},
|
||||
],
|
||||
},
|
||||
],
|
||||
|
||||
@@ -46,19 +46,19 @@
|
||||
"export_format": "*file_csv",
|
||||
"export_path": "/tmp/",
|
||||
"attributes_context":"*cdre",
|
||||
"filters" :["*string:~Source:test2"],
|
||||
"filters" :["*string:~*req.Source:test2"],
|
||||
"content_fields": [
|
||||
{"tag": "CGRID", "type": "*composed", "value": "~CGRID"},
|
||||
{"tag": "RunID", "type": "*composed", "value": "~RunID"},
|
||||
{"tag":"Source", "type": "*composed", "value": "~Source"},
|
||||
{"tag":"OriginID", "type": "*composed", "value": "~OriginID"},
|
||||
{"tag":"Tenant", "type": "*composed", "value": "~Tenant"},
|
||||
{"tag":"Category", "type": "*composed", "value": "~Category"},
|
||||
{"tag":"Account", "type": "*composed", "value": "~Account"},
|
||||
{"tag":"Subject", "type": "*composed", "value": "~Subject"},
|
||||
{"tag":"Destination", "type": "*composed", "value": "~Destination"},
|
||||
{"tag":"Usage", "type": "*composed", "value": "~Usage"},
|
||||
{"tag":"Cost", "type": "*composed", "value": "~Cost", "rounding_decimals": 4},
|
||||
{"tag": "CGRID", "type": "*composed", "value": "~*req.CGRID"},
|
||||
{"tag": "RunID", "type": "*composed", "value": "~*req.RunID"},
|
||||
{"tag":"Source", "type": "*composed", "value": "~*req.Source"},
|
||||
{"tag":"OriginID", "type": "*composed", "value": "~*req.OriginID"},
|
||||
{"tag":"Tenant", "type": "*composed", "value": "~*req.Tenant"},
|
||||
{"tag":"Category", "type": "*composed", "value": "~*req.Category"},
|
||||
{"tag":"Account", "type": "*composed", "value": "~*req.Account"},
|
||||
{"tag":"Subject", "type": "*composed", "value": "~*req.Subject"},
|
||||
{"tag":"Destination", "type": "*composed", "value": "~*req.Destination"},
|
||||
{"tag":"Usage", "type": "*composed", "value": "~*req.Usage"},
|
||||
{"tag":"Cost", "type": "*composed", "value": "~*req.Cost", "rounding_decimals": 4},
|
||||
],
|
||||
},
|
||||
},
|
||||
|
||||
@@ -54,18 +54,18 @@
|
||||
"TemplateWithFilter": {
|
||||
"export_format": "*file_csv",
|
||||
"export_path": "/tmp/",
|
||||
"filters" :["*string:~Source:test2"],
|
||||
"filters" :["*string:~*req.Source:test2"],
|
||||
"content_fields": [
|
||||
{"tag": "CGRID", "type": "*composed", "value": "~CGRID"},
|
||||
{"tag": "RunID", "type": "*composed", "value": "~RunID"},
|
||||
{"tag":"Source", "type": "*composed", "value": "~Source"},
|
||||
{"tag":"OriginID", "type": "*composed", "value": "~OriginID"},
|
||||
{"tag":"Tenant", "type": "*composed", "value": "~Tenant"},
|
||||
{"tag":"Category", "type": "*composed", "value": "~Category"},
|
||||
{"tag":"Account", "type": "*composed", "value": "~Account"},
|
||||
{"tag":"Destination", "type": "*composed", "value": "~Destination"},
|
||||
{"tag":"Usage", "type": "*composed", "value": "~Usage"},
|
||||
{"tag":"Cost", "type": "*composed", "value": "~Cost", "rounding_decimals": 4},
|
||||
{"tag": "CGRID", "type": "*composed", "value": "~*req.CGRID"},
|
||||
{"tag": "RunID", "type": "*composed", "value": "~*req.RunID"},
|
||||
{"tag":"Source", "type": "*composed", "value": "~*req.Source"},
|
||||
{"tag":"OriginID", "type": "*composed", "value": "~*req.OriginID"},
|
||||
{"tag":"Tenant", "type": "*composed", "value": "~*req.Tenant"},
|
||||
{"tag":"Category", "type": "*composed", "value": "~*req.Category"},
|
||||
{"tag":"Account", "type": "*composed", "value": "~*req.Account"},
|
||||
{"tag":"Destination", "type": "*composed", "value": "~*req.Destination"},
|
||||
{"tag":"Usage", "type": "*composed", "value": "~*req.Usage"},
|
||||
{"tag":"Cost", "type": "*composed", "value": "~*req.Cost", "rounding_decimals": 4},
|
||||
],
|
||||
},
|
||||
},
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
#Tenant,ID,Contexts,FilterIDs,ActivationInterval,AttributeFilterIDs,FieldName,Type,Value,Blocker,Weight
|
||||
cgrates.org,LRN_Dst3125650565,lrn,*string:~Destination:3125650565,,,Destination,*constant,13128543000,false,10
|
||||
cgrates.org,LRN_Dst3125650565,lrn,*string:~*req.Destination:3125650565,,,Destination,*constant,13128543000,false,10
|
||||
cgrates.org,LRN_Dst3125650565,,,,,OriginalDestination,*constant,3125650565,false,10
|
||||
cgrates.org,LRN_LATA_Dst13128543000,lrn,*string:~Destination:13128543000;*rsr::~OriginalDestination(!^$),,,DestinationLATA,*constant,358,false,20
|
||||
cgrates.org,LRN_LATA_Cli9174269000,lrn,*string:~Account:9174269000;*rsr::~DestinationLATA(!^$),,,CallerLATA,*constant,132,false,30
|
||||
cgrates.org,LRN_LATA_Dst13128543000,lrn,*string:~*req.Destination:13128543000;*rsr::~*req.OriginalDestination(!^$),,,DestinationLATA,*constant,358,false,20
|
||||
cgrates.org,LRN_LATA_Cli9174269000,lrn,*string:~*req.Account:9174269000;*rsr::~*req.DestinationLATA(!^$),,,CallerLATA,*constant,132,false,30
|
||||
cgrates.org,LRN_JURISDICTION_NY,lrn,FLTR_INTRALATA_NEWYORK,,,LRNJurisdiction,*constant,INTRA,false,50
|
||||
cgrates.org,LRN_JURISDICTION_IL,lrn,FLTR_INTRALATA_ILLINOIS,,,LRNJurisdiction,*constant,INTRA,false,50
|
||||
cgrates.org,LRN_JURISDICTION_INTER,lrn,*string:~Destination:13128543000;*rsr::~CallerLATA(!^$),,,LRNJurisdiction,*constant,INTER,false,40
|
||||
cgrates.org,LRN_JURISDICTION_INTER,lrn,*string:~*req.Destination:13128543000;*rsr::~*req.CallerLATA(!^$),,,LRNJurisdiction,*constant,INTER,false,40
|
||||
|
||||
|
@@ -1,5 +1,5 @@
|
||||
#Tenant[0],ID[1],FilterType[2],FilterFieldName[3],FilterFieldValues[4],ActivationInterval[5]
|
||||
cgrates.org,FLTR_INTRALATA_NEWYORK,*string,~CallerLATA,224;222;220;132,
|
||||
cgrates.org,FLTR_INTRALATA_NEWYORK,*string,~DestinationLATA,224;222;220;132,
|
||||
cgrates.org,FLTR_INTRALATA_ILLINOIS,*string,~CallerLATA,358;359,
|
||||
cgrates.org,FLTR_INTRALATA_ILLINOIS,*string,~DestinationLATA,358;359,
|
||||
cgrates.org,FLTR_INTRALATA_NEWYORK,*string,~*req.CallerLATA,224;222;220;132,
|
||||
cgrates.org,FLTR_INTRALATA_NEWYORK,*string,~*req.DestinationLATA,224;222;220;132,
|
||||
cgrates.org,FLTR_INTRALATA_ILLINOIS,*string,~*req.CallerLATA,358;359,
|
||||
cgrates.org,FLTR_INTRALATA_ILLINOIS,*string,~*req.DestinationLATA,358;359,
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
#Tenant,ID,FilterIDs,ActivationInterval,Sorting,SortingParamameters,SupplierID,SupplierFilterIDs,SupplierAccountIDs,SupplierRatingPlanIDs,SupplierResourceIDs,SupplierStatIDs,SupplierWeight,SupplierBlocker,SupplierParameters,Weight
|
||||
cgrates.org,SPL_CLUELRN_INTER,*string:Account:9174269000;*string:LRNJurisdiction:INTER,2017-11-27T00:00:00Z,*lc,,LEVEL3,,,RP_LEVEL3_INTER,,,,false,,10
|
||||
cgrates.org,SPL_CLUELRN_INTER,*string:~*req.Account:9174269000;*string:~*req.LRNJurisdiction:INTER,2017-11-27T00:00:00Z,*lc,,LEVEL3,,,RP_LEVEL3_INTER,,,,false,,10
|
||||
cgrates.org,SPL_CLUELRN_INTER,,,,,TMOBILE,,,RP_TMOBILE_INTER,,,,false,,
|
||||
cgrates.org,SPL_CLUELRN_INTER,,,,,COMCAST,,,RP_COMCAST_INTER,,,,false,,
|
||||
|
||||
|
@@ -1,22 +1,22 @@
|
||||
#Tenant,ID,Contexts,FilterIDs,ActivationInterval,AttributeFilterIDs,FieldName,Type,Value,Blocker,Weight
|
||||
cgrates.org,ATTR_1001_SIMPLEAUTH,*any,*string:~Account:1001,,,Password,*constant,CGRateS.org,false,20
|
||||
cgrates.org,ATTR_1001_SIMPLEAUTH,*any,*string:~*req.Account:1001,,,Password,*constant,CGRateS.org,false,20
|
||||
cgrates.org,ATTR_1001_SIMPLEAUTH,*any,,,,EventName,*constant,*none,false,20
|
||||
cgrates.org,ATTR_1003_SIMPLEAUTH,*any,*string:~Account:1003,,,Password,*constant,CGRateS.com,false,20
|
||||
cgrates.org,ATTR_API_ATTR_FAKE_AUTH,*auth,*string:~APIKey:12345,,,APIMethods,*constant,,false,20
|
||||
cgrates.org,ATTR_API_ATTR_AUTH,*auth,*string:~APIKey:attr12345,,,APIMethods,*constant,AttributeSv1.Ping&AttributeSv1.GetAttributeForEvent&AttributeSv1.ProcessEvent,false,20
|
||||
cgrates.org,ATTR_API_CHRG_AUTH,*auth,*string:~APIKey:chrg12345,,,APIMethods,*constant,ChargerSv1.Ping&ChargerSv1.GetChargersForEvent&ChargerSv1.ProcessEvent,false,20
|
||||
cgrates.org,ATTR_API_THR_AUTH,*auth,*string:~APIKey:thr12345,,,APIMethods,*constant,ThresholdSv1.Ping&ThresholdSv1.GetThresholdsForEvent&ThresholdSv1.ProcessEvent&ThresholdSv1.GetThreshold&ThresholdSv1.GetThresholdIDs,false,20
|
||||
cgrates.org,ATTR_API_SUP_AUTH,*auth,*string:~APIKey:sup12345,,,APIMethods,*constant,SupplierSv1.Ping&SupplierSv1.GetSuppliers&SupplierSv1.GetSupplierProfilesForEvent,false,20
|
||||
cgrates.org,ATTR_API_STAT_AUTH,*auth,*string:~APIKey:stat12345,,,APIMethods,*constant,StatSv1.Ping&StatSv1.GetStatQueuesForEvent&StatSv1.GetQueueStringMetrics&StatSv1.ProcessEvent&StatSv1.GetQueueIDs&StatSv1.GetQueueFloatMetrics,false,20
|
||||
cgrates.org,ATTR_API_RES_AUTH,*auth,*string:~APIKey:res12345,,,APIMethods,*constant,ResourceSv1.Ping&ResourceSv1.GetResourcesForEvent&ResourceSv1.AuthorizeResources&ResourceSv1.AllocateResources&ResourceSv1.ReleaseResources,false,20
|
||||
cgrates.org,ATTR_API_SES_AUTH,*auth,*string:~APIKey:ses12345,,,APIMethods,*constant,SessionSv1.Ping&SessionSv1.AuthorizeEvent&SessionSv1.AuthorizeEventWithDigest&SessionSv1.InitiateSession&SessionSv1.InitiateSessionWithDigest&SessionSv1.UpdateSession&SessionSv1.SyncSessions&SessionSv1.TerminateSession&SessionSv1.ProcessCDR&SessionSv1.ProcessMessage&SessionSv1.GetActiveSessions&SessionSv1.GetActiveSessionsCount&SessionSv1.ForceDisconnect&SessionSv1.GetPassiveSessions&SessionSv1.GetPassiveSessionsCount&SessionSv1.ReplicateSessions&SessionSv1.SetPassiveSession&SessionSv1.ProcessEvent,false,20
|
||||
cgrates.org,ATTR_API_RSP_AUTH,*auth,*string:~APIKey:rsp12345,,,APIMethods,*constant,CoreSv1.Status&CoreSv1.Ping&Responder.GetTimeout&Responder.Shutdown&Responder.Ping,false,20
|
||||
cgrates.org,ATTR_API_CHC_AUTH,*auth,*string:~APIKey:chc12345,,,APIMethods,*constant,CacheSv1.Ping&CacheSv1.GetCacheStats&CacheSv1.LoadCache&CacheSv1.PrecacheStatus&CacheSv1.GetItemIDs&CacheSv1.HasItem&CacheSv1.GetItemExpiryTime&CacheSv1.ReloadCache&CacheSv1.RemoveItem&CacheSv1.FlushCache&CacheSv1.Clear,false,20
|
||||
cgrates.org,ATTR_API_GRD_AUTH,*auth,*string:~APIKey:grd12345,,,APIMethods,*constant,GuardianSv1.Ping&GuardianSv1.RemoteLock&GuardianSv1.RemoteUnlock,false,20
|
||||
cgrates.org,ATTR_API_SCHD_AUTH,*auth,*string:~APIKey:sched12345,,,APIMethods,*constant,SchedulerSv1.Ping,false,20
|
||||
cgrates.org,ATTR_API_CDRS_AUTH,*auth,*string:~APIKey:cdrs12345,,,APIMethods,*constant,CDRsV1.Ping&CDRsV1.ProcessEvent&CDRsV1.GetCDRs&CDRsV1.CountCDRs&CDRsV1.ProcessCDR&CDRsV1.ProcessExternalCDR,false,20
|
||||
cgrates.org,ATTR_API_DSP_AUTH,*auth,*string:~APIKey:dsp12345,,,APIMethods,*constant,DispatcherSv1.Ping&DispatcherSv1.GetProfileForEvent,false,20
|
||||
cgrates.org,ATTR_API_PSE_AUTH,*auth,*string:~APIKey:pse12345,,,APIMethods,*constant,SessionSv1.Ping&SessionSv1.AuthorizeEvent&SessionSv1.AuthorizeEventWithDigest&SessionSv1.InitiateSession&SessionSv1.InitiateSessionWithDigest&SessionSv1.UpdateSession&SessionSv1.SyncSessions&SessionSv1.TerminateSession&SessionSv1.ProcessCDR&SessionSv1.ProcessMessage&SessionSv1.GetActiveSessions&SessionSv1.GetActiveSessionsCount&SessionSv1.ForceDisconnect&SessionSv1.GetPassiveSessions&SessionSv1.GetPassiveSessionsCount&SessionSv1.ReplicateSessions&SessionSv1.SetPassiveSession&AttributeSv1.ProcessEvent&Responder.Debit&ResourceSv1.AllocateResources&ChargerSv1.ProcessEvent&Responder.MaxDebit,false,20
|
||||
cgrates.org,ATTR_API_CFG_AUTH,*auth,*string:~APIKey:cfg12345,,,APIMethods,*constant,ConfigSv1.GetJSONSection&ConfigSv1.ReloadConfig,false,20
|
||||
cgrates.org,ATTR_API_APIER_AUTH,*auth,*string:~APIKey:apier12345,,,APIMethods,*constant,ApierV1.GetAttributeProfile&ApierV1.SetAttributeProfile,false,20
|
||||
cgrates.org,ATTR_API_RALS_AUTH,*auth,*string:~APIKey:rals12345,,,APIMethods,*constant,RALsV1.Ping&RALsV1.GetRatingPlansCost,false,20
|
||||
cgrates.org,ATTR_1003_SIMPLEAUTH,*any,*string:~*req.Account:1003,,,Password,*constant,CGRateS.com,false,20
|
||||
cgrates.org,ATTR_API_ATTR_FAKE_AUTH,*auth,*string:~*req.APIKey:12345,,,APIMethods,*constant,,false,20
|
||||
cgrates.org,ATTR_API_ATTR_AUTH,*auth,*string:~*req.APIKey:attr12345,,,APIMethods,*constant,AttributeSv1.Ping&AttributeSv1.GetAttributeForEvent&AttributeSv1.ProcessEvent,false,20
|
||||
cgrates.org,ATTR_API_CHRG_AUTH,*auth,*string:~*req.APIKey:chrg12345,,,APIMethods,*constant,ChargerSv1.Ping&ChargerSv1.GetChargersForEvent&ChargerSv1.ProcessEvent,false,20
|
||||
cgrates.org,ATTR_API_THR_AUTH,*auth,*string:~*req.APIKey:thr12345,,,APIMethods,*constant,ThresholdSv1.Ping&ThresholdSv1.GetThresholdsForEvent&ThresholdSv1.ProcessEvent&ThresholdSv1.GetThreshold&ThresholdSv1.GetThresholdIDs,false,20
|
||||
cgrates.org,ATTR_API_SUP_AUTH,*auth,*string:~*req.APIKey:sup12345,,,APIMethods,*constant,SupplierSv1.Ping&SupplierSv1.GetSuppliers&SupplierSv1.GetSupplierProfilesForEvent,false,20
|
||||
cgrates.org,ATTR_API_STAT_AUTH,*auth,*string:~*req.APIKey:stat12345,,,APIMethods,*constant,StatSv1.Ping&StatSv1.GetStatQueuesForEvent&StatSv1.GetQueueStringMetrics&StatSv1.ProcessEvent&StatSv1.GetQueueIDs&StatSv1.GetQueueFloatMetrics,false,20
|
||||
cgrates.org,ATTR_API_RES_AUTH,*auth,*string:~*req.APIKey:res12345,,,APIMethods,*constant,ResourceSv1.Ping&ResourceSv1.GetResourcesForEvent&ResourceSv1.AuthorizeResources&ResourceSv1.AllocateResources&ResourceSv1.ReleaseResources,false,20
|
||||
cgrates.org,ATTR_API_SES_AUTH,*auth,*string:~*req.APIKey:ses12345,,,APIMethods,*constant,SessionSv1.Ping&SessionSv1.AuthorizeEvent&SessionSv1.AuthorizeEventWithDigest&SessionSv1.InitiateSession&SessionSv1.InitiateSessionWithDigest&SessionSv1.UpdateSession&SessionSv1.SyncSessions&SessionSv1.TerminateSession&SessionSv1.ProcessCDR&SessionSv1.ProcessMessage&SessionSv1.GetActiveSessions&SessionSv1.GetActiveSessionsCount&SessionSv1.ForceDisconnect&SessionSv1.GetPassiveSessions&SessionSv1.GetPassiveSessionsCount&SessionSv1.ReplicateSessions&SessionSv1.SetPassiveSession&SessionSv1.ProcessEvent,false,20
|
||||
cgrates.org,ATTR_API_RSP_AUTH,*auth,*string:~*req.APIKey:rsp12345,,,APIMethods,*constant,CoreSv1.Status&CoreSv1.Ping&Responder.GetTimeout&Responder.Shutdown&Responder.Ping,false,20
|
||||
cgrates.org,ATTR_API_CHC_AUTH,*auth,*string:~*req.APIKey:chc12345,,,APIMethods,*constant,CacheSv1.Ping&CacheSv1.GetCacheStats&CacheSv1.LoadCache&CacheSv1.PrecacheStatus&CacheSv1.GetItemIDs&CacheSv1.HasItem&CacheSv1.GetItemExpiryTime&CacheSv1.ReloadCache&CacheSv1.RemoveItem&CacheSv1.FlushCache&CacheSv1.Clear,false,20
|
||||
cgrates.org,ATTR_API_GRD_AUTH,*auth,*string:~*req.APIKey:grd12345,,,APIMethods,*constant,GuardianSv1.Ping&GuardianSv1.RemoteLock&GuardianSv1.RemoteUnlock,false,20
|
||||
cgrates.org,ATTR_API_SCHD_AUTH,*auth,*string:~*req.APIKey:sched12345,,,APIMethods,*constant,SchedulerSv1.Ping,false,20
|
||||
cgrates.org,ATTR_API_CDRS_AUTH,*auth,*string:~*req.APIKey:cdrs12345,,,APIMethods,*constant,CDRsV1.Ping&CDRsV1.ProcessEvent&CDRsV1.GetCDRs&CDRsV1.CountCDRs&CDRsV1.ProcessCDR&CDRsV1.ProcessExternalCDR,false,20
|
||||
cgrates.org,ATTR_API_DSP_AUTH,*auth,*string:~*req.APIKey:dsp12345,,,APIMethods,*constant,DispatcherSv1.Ping&DispatcherSv1.GetProfileForEvent,false,20
|
||||
cgrates.org,ATTR_API_PSE_AUTH,*auth,*string:~*req.APIKey:pse12345,,,APIMethods,*constant,SessionSv1.Ping&SessionSv1.AuthorizeEvent&SessionSv1.AuthorizeEventWithDigest&SessionSv1.InitiateSession&SessionSv1.InitiateSessionWithDigest&SessionSv1.UpdateSession&SessionSv1.SyncSessions&SessionSv1.TerminateSession&SessionSv1.ProcessCDR&SessionSv1.ProcessMessage&SessionSv1.GetActiveSessions&SessionSv1.GetActiveSessionsCount&SessionSv1.ForceDisconnect&SessionSv1.GetPassiveSessions&SessionSv1.GetPassiveSessionsCount&SessionSv1.ReplicateSessions&SessionSv1.SetPassiveSession&AttributeSv1.ProcessEvent&Responder.Debit&ResourceSv1.AllocateResources&ChargerSv1.ProcessEvent&Responder.MaxDebit,false,20
|
||||
cgrates.org,ATTR_API_CFG_AUTH,*auth,*string:~*req.APIKey:cfg12345,,,APIMethods,*constant,ConfigSv1.GetJSONSection&ConfigSv1.ReloadConfig,false,20
|
||||
cgrates.org,ATTR_API_APIER_AUTH,*auth,*string:~*req.APIKey:apier12345,,,APIMethods,*constant,ApierV1.GetAttributeProfile&ApierV1.SetAttributeProfile,false,20
|
||||
cgrates.org,ATTR_API_RALS_AUTH,*auth,*string:~*req.APIKey:rals12345,,,APIMethods,*constant,RALsV1.Ping&RALsV1.GetRatingPlansCost,false,20
|
||||
|
||||
|
@@ -1,12 +1,12 @@
|
||||
#Tenant,ID,Subsystems,FilterIDs,ActivationInterval,Strategy,StrategyParameters,ConnID,ConnFilterIDs,ConnWeight,ConnBlocker,ConnParameters,Weight
|
||||
cgrates.org,PING1,*any,,,*weight,,ALL,,20,false,,10
|
||||
cgrates.org,PING1,,,,,,ALL2,,10,,,
|
||||
cgrates.org,EVENT1,*any,*string:~EventName:Event1,,*weight,,ALL2,,20,false,,30
|
||||
cgrates.org,EVENT1,*any,*string:~*req.EventName:Event1,,*weight,,ALL2,,20,false,,30
|
||||
cgrates.org,EVENT1,,,,,,ALL,,10,,,
|
||||
cgrates.org,EVENT2,*any,*string:~EventName:RoundRobin,,*round_robin,,ALL2,,20,false,,20
|
||||
cgrates.org,EVENT2,*any,*string:~*req.EventName:RoundRobin,,*round_robin,,ALL2,,20,false,,20
|
||||
cgrates.org,EVENT2,,,,,,ALL,,10,,,
|
||||
cgrates.org,EVENT3,*any,*string:~EventName:Random,,*random,,ALL2,,20,false,,20
|
||||
cgrates.org,EVENT3,*any,*string:~*req.EventName:Random,,*random,,ALL2,,20,false,,20
|
||||
cgrates.org,EVENT3,,,,,,ALL,,10,,,
|
||||
cgrates.org,EVENT4,*any,*string:~EventName:Broadcast,,*broadcast,,ALL2,,20,false,,20
|
||||
cgrates.org,EVENT4,*any,*string:~*req.EventName:Broadcast,,*broadcast,,ALL2,,20,false,,20
|
||||
cgrates.org,EVENT4,,,,,,ALL,,10,,,
|
||||
cgrates.org,EVENT5,*any,*string:~EventName:Internal,,*weight,,SELF,,20,false,,20
|
||||
cgrates.org,EVENT5,*any,*string:~*req.EventName:Internal,,*weight,,SELF,,20,false,,20
|
||||
|
||||
|
@@ -1,3 +1,3 @@
|
||||
#Tenant,ID,Contexts,FilterIDs,ActivationInterval,AttributeFilterIDs,FieldName,Type,Value,Blocker,Weight
|
||||
cgrates.org,ATTR_NAPTR_ADDR,*any,*string:~E164Address:4986517174964,,,NAPTRAddress,*constant,sip:\1@172.16.1.1.,false,20
|
||||
cgrates.org,ATTR_NAPTR_ADDR,*any,*string:~*req.E164Address:4986517174964,,,NAPTRAddress,*constant,sip:\1@172.16.1.1.,false,20
|
||||
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
#Tenant,ID,FilterIDs,ActivationInterval,Sorting,SortingParamameters,SupplierID,SupplierFilterIDs,SupplierAccountIDs,SupplierRatingPlanIDs,SupplierResourceIDs,SupplierStatIDs,SupplierWeight,SupplierBlocker,SupplierParameters,Weight
|
||||
cgrates.org,SPL_ACNT_1001,*string:~Account:1001,,*weight,,supplier1,,,,,,10,,!^(.*)$!sip:\1@172.16.1.11!,10
|
||||
cgrates.org,SPL_ACNT_1001,*string:~*req.Account:1001,,*weight,,supplier1,,,,,,10,,!^(.*)$!sip:\1@172.16.1.11!,10
|
||||
cgrates.org,SPL_ACNT_1001,,,,,supplier2,,,,,,5,,!^(.*)$!sip:\1@172.16.1.12!,10
|
||||
|
||||
|
||||
|
@@ -1,3 +1,3 @@
|
||||
#Tenant,ID,Contexts,FilterIDs,ActivationInterval,AttributeFilterIDs,FieldName,Type,Value,Blocker,Weight
|
||||
cgrates.org,ATTR_1,*sessions;*cdrs,*string:~Account:1007,2014-01-14T00:00:00Z,,Account,*constant,1001,false,10
|
||||
cgrates.org,ATTR_1,*sessions;*cdrs,*string:~*req.Account:1007,2014-01-14T00:00:00Z,,Account,*constant,1001,false,10
|
||||
cgrates.org,ATTR_1,,,,,Subject,*constant,1001,,
|
||||
|
||||
|
@@ -1,32 +1,32 @@
|
||||
#Tenant[0],ID[1],FilterType[2],FilterFieldName[3],FilterFieldValues[4],ActivationInterval[5]
|
||||
cgrates.org,FLTR_1,*string,~Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*prefix,~Destination,10;20,
|
||||
cgrates.org,FLTR_1,*rsr,,~Subject(~^1.*1$);~Destination(1002),
|
||||
cgrates.org,FLTR_ACNT_1007,*string,~Account,1007,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_dan,*string,~Account,dan,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_DE,*destinations,~Destination,DST_DE_MOBILE,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_NL,*destinations,~Destination,DST_NL,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*string,~Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*string,~EventType,BalanceUpdate,
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*gte,~Units,10.0,
|
||||
cgrates.org,FLTR_ACNT_EXPIRED,*string,~Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_EXPIRED,*gte,~ExpiryTime,*now,
|
||||
cgrates.org,FLTR_STATS_1,*string,~Account,1002,
|
||||
cgrates.org,FLTR_STATS_1,*string,~EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_1,*lt,~ASR,40.0,
|
||||
cgrates.org,FLTR_STATS_1,*lt,~ACD,3m,
|
||||
cgrates.org,FLTR_STATS_2,*string,~EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_2,*string,~StatID,STATS_HOURLY_DE,
|
||||
cgrates.org,FLTR_STATS_2,*gt,~TCD,30m,
|
||||
cgrates.org,FLTR_STATS_3,*string,~EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_3,*string,~StatID,STATS_DAILY_DE,
|
||||
cgrates.org,FLTR_STATS_3,*gt,~TCD,3h,
|
||||
cgrates.org,FLTR_RES_1,*string,~EventType,ResourceUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_RES_1,*string,~ResourceID,RES_GRP_1,
|
||||
cgrates.org,FLTR_RES_1,*gte,~Usage,10.0,
|
||||
cgrates.org,FLTR_DST_FS,*string,~Account,1001;1002;dan,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_FS,*destinations,~Destination,DST_FS,
|
||||
cgrates.org,FLTR_RES_GR3,*string,~Account,3001,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STS1,*string,~Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_CDR_UPDATE,*string,~EventType,CDR,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*string,~*req.Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*prefix,~*req.Destination,10;20,
|
||||
cgrates.org,FLTR_1,*rsr,,~*req.Subject(~^1.*1$);~*req.Destination(1002),
|
||||
cgrates.org,FLTR_ACNT_1007,*string,~*req.Account,1007,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_dan,*string,~*req.Account,dan,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_DE,*destinations,~*req.Destination,DST_DE_MOBILE,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_NL,*destinations,~*req.Destination,DST_NL,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*string,~*req.Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*string,~*req.EventType,BalanceUpdate,
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*gte,~*req.Units,10.0,
|
||||
cgrates.org,FLTR_ACNT_EXPIRED,*string,~*req.Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_EXPIRED,*gte,~*req.ExpiryTime,*now,
|
||||
cgrates.org,FLTR_STATS_1,*string,~*req.Account,1002,
|
||||
cgrates.org,FLTR_STATS_1,*string,~*req.EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_1,*lt,~*req.ASR,40.0,
|
||||
cgrates.org,FLTR_STATS_1,*lt,~*req.ACD,3m,
|
||||
cgrates.org,FLTR_STATS_2,*string,~*req.EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_2,*string,~*req.StatID,STATS_HOURLY_DE,
|
||||
cgrates.org,FLTR_STATS_2,*gt,~*req.TCD,30m,
|
||||
cgrates.org,FLTR_STATS_3,*string,~*req.EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_3,*string,~*req.StatID,STATS_DAILY_DE,
|
||||
cgrates.org,FLTR_STATS_3,*gt,~*req.TCD,3h,
|
||||
cgrates.org,FLTR_RES_1,*string,~*req.EventType,ResourceUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_RES_1,*string,~*req.ResourceID,RES_GRP_1,
|
||||
cgrates.org,FLTR_RES_1,*gte,~*req.Usage,10.0,
|
||||
cgrates.org,FLTR_DST_FS,*string,~*req.Account,1001;1002;dan,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_FS,*destinations,~*req.Destination,DST_FS,
|
||||
cgrates.org,FLTR_RES_GR3,*string,~*req.Account,3001,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STS1,*string,~*req.Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_CDR_UPDATE,*string,~*req.EventType,CDR,2014-07-29T15:00:00Z
|
||||
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
#Tenant[0],Id[1],FilterIDs[2],ActivationInterval[3],QueueLength[4],TTL[5],MinItems[6],Metrics[7],MetricFilterIDs[8],Stored[9],Blocker[10],Weight[11],ThresholdIDs[12]
|
||||
cgrates.org,Stats1,FLTR_STS1,2014-07-29T15:00:00Z,100,1s,2,*asr;*acc;*tcc;*acd;*tcd,,true,false,20,*none
|
||||
cgrates.org,Stats1,,,,,,*sum:~Usage;*average:~Usage,,,,,
|
||||
cgrates.org,Stats1,,,,,,*pdd,*exists:~PDD:,,,,
|
||||
cgrates.org,Stats1,,,,,,*pdd,*exists:~*req.PDD:,,,,
|
||||
|
@@ -1,3 +1,3 @@
|
||||
#Tenant,ID,Contexts,FilterIDs,ActivationInterval,AttributeFilterIDs,FieldName,Type,Value,Blocker,Weight
|
||||
cgrates.org,ATTR_1,*sessions;*cdrs,*string:~Account:1007,2014-01-14T00:00:00Z,,Account,*constant,1001,false,10
|
||||
cgrates.org,ATTR_1,*sessions;*cdrs,*string:~*req.Account:1007,2014-01-14T00:00:00Z,,Account,*constant,1001,false,10
|
||||
cgrates.org,ATTR_1,,,,,Subject,*constant,1001,,
|
||||
|
||||
|
@@ -1,12 +1,12 @@
|
||||
#Tenant,ID,Subsystems,FilterIDs,ActivationInterval,Strategy,StrategyParameters,ConnID,ConnFilterIDs,ConnWeight,ConnBlocker,ConnParameters,Weight
|
||||
cgrates.org,PING1,*any,,,*weight,,ALL,,20,false,,10
|
||||
cgrates.org,PING1,,,,,,ALL2,,10,,,
|
||||
cgrates.org,EVENT1,*any,*string:~EventName:Event1,,*weight,,ALL2,,20,false,,30
|
||||
cgrates.org,EVENT1,*any,*string:~*req.EventName:Event1,,*weight,,ALL2,,20,false,,30
|
||||
cgrates.org,EVENT1,,,,,,ALL,,10,,,
|
||||
cgrates.org,EVENT2,*any,*string:~EventName:RoundRobin,,*round_robin,,ALL2,,20,false,,20
|
||||
cgrates.org,EVENT2,*any,*string:~*req.EventName:RoundRobin,,*round_robin,,ALL2,,20,false,,20
|
||||
cgrates.org,EVENT2,,,,,,ALL,,10,,,
|
||||
cgrates.org,EVENT3,*any,*string:~EventName:Random,,*random,,ALL2,,20,false,,20
|
||||
cgrates.org,EVENT3,*any,*string:~*req.EventName:Random,,*random,,ALL2,,20,false,,20
|
||||
cgrates.org,EVENT3,,,,,,ALL,,10,,,
|
||||
cgrates.org,EVENT4,*any,*string:~EventName:Broadcast,,*broadcast,,ALL2,,20,false,,20
|
||||
cgrates.org,EVENT4,*any,*string:~*req.EventName:Broadcast,,*broadcast,,ALL2,,20,false,,20
|
||||
cgrates.org,EVENT4,,,,,,ALL,,10,,,
|
||||
cgrates.org,EVENT5,*any,*string:~EventName:Internal,,*weight,,SELF,,20,false,,20
|
||||
cgrates.org,EVENT5,*any,*string:~*req.EventName:Internal,,*weight,,SELF,,20,false,,20
|
||||
|
||||
|
@@ -1,32 +1,32 @@
|
||||
#Tenant[0],ID[1],FilterType[2],FilterFieldName[3],FilterFieldValues[4],ActivationInterval[5]
|
||||
cgrates.org,FLTR_1,*string,~Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*prefix,~Destination,10;20,
|
||||
cgrates.org,FLTR_1,*rsr,,~Subject(~^1.*1$);~Destination(1002),
|
||||
cgrates.org,FLTR_ACNT_1007,*string,~Account,1007,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_dan,*string,~Account,dan,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_DE,*destinations,~Destination,DST_DE_MOBILE,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_NL,*destinations,~Destination,DST_NL,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*string,~Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*string,~EventType,BalanceUpdate,
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*gte,~Units,10.0,
|
||||
cgrates.org,FLTR_ACNT_EXPIRED,*string,~Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_EXPIRED,*gte,~ExpiryTime,*now,
|
||||
cgrates.org,FLTR_STATS_1,*string,~Account,1002,
|
||||
cgrates.org,FLTR_STATS_1,*string,~EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_1,*lt,~ASR,40.0,
|
||||
cgrates.org,FLTR_STATS_1,*lt,~ACD,3m,
|
||||
cgrates.org,FLTR_STATS_2,*string,~EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_2,*string,~StatID,STATS_HOURLY_DE,
|
||||
cgrates.org,FLTR_STATS_2,*gt,~TCD,30m,
|
||||
cgrates.org,FLTR_STATS_3,*string,~EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_3,*string,~StatID,STATS_DAILY_DE,
|
||||
cgrates.org,FLTR_STATS_3,*gt,~TCD,3h,
|
||||
cgrates.org,FLTR_RES_1,*string,~EventType,ResourceUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_RES_1,*string,~ResourceID,RES_GRP_1,
|
||||
cgrates.org,FLTR_RES_1,*gte,~Usage,10.0,
|
||||
cgrates.org,FLTR_DST_FS,*string,~Account,1001;1002;dan,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_FS,*destinations,~Destination,DST_FS,
|
||||
cgrates.org,FLTR_RES_GR3,*string,~Account,3001,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STS1,*string,~Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_CDR_UPDATE,*string,~EventType,CDR,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*string,~*req.Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*prefix,~*req.Destination,10;20,
|
||||
cgrates.org,FLTR_1,*rsr,,~*req.Subject(~^1.*1$);~Destination(1002),
|
||||
cgrates.org,FLTR_ACNT_1007,*string,~*req.Account,1007,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_dan,*string,~*req.Account,dan,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_DE,*destinations,~*req.Destination,DST_DE_MOBILE,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_NL,*destinations,~*req.Destination,DST_NL,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*string,~*req.Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*string,~*req.EventType,BalanceUpdate,
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*gte,~*req.Units,10.0,
|
||||
cgrates.org,FLTR_ACNT_EXPIRED,*string,~*req.Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_EXPIRED,*gte,~*req.ExpiryTime,*now,
|
||||
cgrates.org,FLTR_STATS_1,*string,~*req.Account,1002,
|
||||
cgrates.org,FLTR_STATS_1,*string,~*req.EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_1,*lt,~*req.ASR,40.0,
|
||||
cgrates.org,FLTR_STATS_1,*lt,~*req.ACD,3m,
|
||||
cgrates.org,FLTR_STATS_2,*string,~*req.EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_2,*string,~*req.StatID,STATS_HOURLY_DE,
|
||||
cgrates.org,FLTR_STATS_2,*gt,~*req.TCD,30m,
|
||||
cgrates.org,FLTR_STATS_3,*string,~*req.EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_3,*string,~*req.StatID,STATS_DAILY_DE,
|
||||
cgrates.org,FLTR_STATS_3,*gt,~*req.TCD,3h,
|
||||
cgrates.org,FLTR_RES_1,*string,~*req.EventType,ResourceUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_RES_1,*string,~*req.ResourceID,RES_GRP_1,
|
||||
cgrates.org,FLTR_RES_1,*gte,~*req.Usage,10.0,
|
||||
cgrates.org,FLTR_DST_FS,*string,~*req.Account,1001;1002;dan,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_FS,*destinations,~*req.Destination,DST_FS,
|
||||
cgrates.org,FLTR_RES_GR3,*string,~*req.Account,3001,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STS1,*string,~*req.Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_CDR_UPDATE,*string,~*req.EventType,CDR,2014-07-29T15:00:00Z
|
||||
|
||||
|
||||
|
@@ -1,4 +1,4 @@
|
||||
#Tenant,ID,Context,FilterIDs,ActivationInterval,AttributeFilterIDs,FieldName,Type,Value,Blocker,Weight
|
||||
cgrates.org,ATTR_ACNT_1001,*sessions,FLTR_ACCOUNT_1001,,,OfficeGroup,*constant,Marketing,false,10
|
||||
cgrates.org,ATTR_SUPPLIER1,*chargers,,,,Subject,*constant,SUPPLIER1,false,10
|
||||
cgrates.org,ATTR_PAYPAL,*cdrs,*string:~Subject:ANY2CNT,,,PayPalAccount,*constant,paypal@cgrates.org,false,10
|
||||
cgrates.org,ATTR_PAYPAL,*cdrs,*string:~*req.Subject:ANY2CNT,,,PayPalAccount,*constant,paypal@cgrates.org,false,10
|
||||
|
||||
|
@@ -1,27 +1,27 @@
|
||||
#Tenant[0],ID[1],FilterType[2],FilterFieldName[3],FilterFieldValues[4],ActivationInterval[5]
|
||||
cgrates.org,FLTR_ACCOUNT_1001,*string,~Account,1001,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_DE,*destinations,~Destination,DST_DE_MOBILE,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*string,~Account,1003;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*prefix,~Destination,10;20,
|
||||
cgrates.org,FLTR_1,*rsr,,~Destination(1002),
|
||||
cgrates.org,FLTR_ACNT_1007,*string,~Account,1007,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_dan,*string,~Account,dan,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACCOUNT_1001,*string,~*req.Account,1001,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_DE,*destinations,~*req.Destination,DST_DE_MOBILE,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*string,~*req.Account,1003;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*prefix,~*req.Destination,10;20,
|
||||
cgrates.org,FLTR_1,*rsr,,~*req.Destination(1002),
|
||||
cgrates.org,FLTR_ACNT_1007,*string,~*req.Account,1007,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_dan,*string,~*req.Account,dan,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_SPP_ACNT_dan,*string,~*req.Account,dan,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_SPP_2,*string,~Account,1003,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_SPP_2,*prefix,~Destination,10;20,
|
||||
cgrates.org,FLTR_SPP_2,*string,~DistinctMatch,*highest_cost,
|
||||
cgrates.org,FLTR_SPP_3,*string,~DistinctMatch,*qos,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STAT_1,*string,~Account,1001,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STAT_2,*string,~Account,1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STAT_3,*string,~Account,1003,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_SPP_4,*string,~DistinctMatch,*qos2,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_SPP_5,*string,~DistinctMatch,*qos3,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STAT_1_1,*string,~Stat,Stat1_1,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_SPP_6,*string,~DistinctMatch,*qos_filtred,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_SPP_2,*string,~*req.Account,1003,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_SPP_2,*prefix,~*req.Destination,10;20,
|
||||
cgrates.org,FLTR_SPP_2,*string,~*req.DistinctMatch,*highest_cost,
|
||||
cgrates.org,FLTR_SPP_3,*string,~*req.DistinctMatch,*qos,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STAT_1,*string,~*req.Account,1001,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STAT_2,*string,~*req.Account,1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STAT_3,*string,~*req.Account,1003,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_SPP_4,*string,~*req.DistinctMatch,*qos2,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_SPP_5,*string,~*req.DistinctMatch,*qos3,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STAT_1_1,*string,~*req.Stat,Stat1_1,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_SPP_6,*string,~*req.DistinctMatch,*qos_filtred,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_QOS_SP1,*gte,~*vars.*acd,10.0,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_QOS_SP2,*gte,~*vars.*acd,10.0,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_QOS_SP2,*gte,~*vars.*tcd,11.0,
|
||||
cgrates.org,FLTR_SPP_QOS_2,*string,~DistinctMatch,*qos_filtred2,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_SPP_QOS_2,*string,~*req.DistinctMatch,*qos_filtred2,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_QOS_SP1_2,*gte,~*vars.Cost,0.1,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_QOS_SP2_2,*gte,~*vars.Cost,0.2,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_TEST,*string,~Subject,TEST,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_TEST,*string,~*req.Subject,TEST,2014-07-29T15:00:00Z
|
||||
|
@@ -1,29 +1,29 @@
|
||||
#Tenant[0],ID[1],FilterType[2],FilterFieldName[3],FilterFieldValues[4],ActivationInterval[5]
|
||||
cgrates.org,FLTR_1,*string,~Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*prefix,~Destination,10;20,
|
||||
cgrates.org,FLTR_1,*rsr,,~Subject(~^1.*1$);~Destination(1002),
|
||||
cgrates.org,FLTR_ACNT_1007,*string,~Account,1007,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_dan,*string,~Account,dan,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_DE,*destinations,~Destination,DST_DE,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_NL,*destinations,~Destination,DST_NL,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*string,~Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*string,~EventType,BalanceUpdate,
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*gte,~Units,10.0,
|
||||
cgrates.org,FLTR_ACNT_EXPIRED,*string,~Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_EXPIRED,*gte,~ExpiryTime,*now,
|
||||
cgrates.org,FLTR_STATS_1,*string,~EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_1,*lt,~ASR,40.0,
|
||||
cgrates.org,FLTR_STATS_1,*lt,~ACD,3m,
|
||||
cgrates.org,FLTR_STATS_2,*string,~EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_2,*string,`StatID,STATS_HOURLY_DE,
|
||||
cgrates.org,FLTR_STATS_2,*gt,~TCD,30m,
|
||||
cgrates.org,FLTR_STATS_3,*string,~EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_3,*string,~StatID,STATS_DAILY_DE,
|
||||
cgrates.org,FLTR_STATS_3,*gt,~TCD,3h,
|
||||
cgrates.org,FLTR_RES_1,*string,~EventType,ResourceUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_RES_1,*string,`ResourceID,RES_GRP_1,
|
||||
cgrates.org,FLTR_RES_1,*gte,~Usage,10.0,
|
||||
cgrates.org,FLTR_DST_FS,*destinations,~Destination,DST_FS,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_RES_GR3,*string,~Account,3001,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STS1,*string,~Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_CDR_UPDATE,*string,~EventType,CDR,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*string,~*req.Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_1,*prefix,~*req.Destination,10;20,
|
||||
cgrates.org,FLTR_1,*rsr,,~*req.Subject(~^1.*1$);~Destination(1002),
|
||||
cgrates.org,FLTR_ACNT_1007,*string,~*req.Account,1007,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_dan,*string,~*req.Account,dan,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_DE,*destinations,~*req.Destination,DST_DE,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_NL,*destinations,~*req.Destination,DST_NL,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*string,~*req.Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*string,~*req.EventType,BalanceUpdate,
|
||||
cgrates.org,FLTR_ACNT_BALANCE_1,*gte,~*req.Units,10.0,
|
||||
cgrates.org,FLTR_ACNT_EXPIRED,*string,~*req.Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_EXPIRED,*gte,~*req.ExpiryTime,*now,
|
||||
cgrates.org,FLTR_STATS_1,*string,~*req.EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_1,*lt,~*req.ASR,40.0,
|
||||
cgrates.org,FLTR_STATS_1,*lt,~*req.ACD,3m,
|
||||
cgrates.org,FLTR_STATS_2,*string,~*req.EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_2,*string,~*req.StatID,STATS_HOURLY_DE,
|
||||
cgrates.org,FLTR_STATS_2,*gt,~*req.TCD,30m,
|
||||
cgrates.org,FLTR_STATS_3,*string,~*req.EventType,StatUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STATS_3,*string,~*req.StatID,STATS_DAILY_DE,
|
||||
cgrates.org,FLTR_STATS_3,*gt,~*req.TCD,3h,
|
||||
cgrates.org,FLTR_RES_1,*string,~*req.EventType,ResourceUpdate,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_RES_1,*string,~*req.ResourceID,RES_GRP_1,
|
||||
cgrates.org,FLTR_RES_1,*gte,~*req.Usage,10.0,
|
||||
cgrates.org,FLTR_DST_FS,*destinations,~*req.Destination,DST_FS,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_RES_GR3,*string,~*req.Account,3001,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_STS1,*string,~*req.Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_CDR_UPDATE,*string,~*req.EventType,CDR,2014-07-29T15:00:00Z
|
||||
|
||||
|
@@ -1,24 +1,24 @@
|
||||
#Tenant,ID,Contexts,FilterIDs,ActivationInterval,AttributeFilterIDs,FieldName,Type,Value,Blocker,Weight
|
||||
cgrates.org,ATTR_1001_SIMPLEAUTH,simpleauth,*string:~Account:1001,,,Password,*constant,CGRateS.org,false,20
|
||||
cgrates.org,ATTR_1002_SIMPLEAUTH,simpleauth,*string:~Account:1002,,,Password,*constant,CGRateS.org,false,20
|
||||
cgrates.org,ATTR_1003_SIMPLEAUTH,simpleauth,*string:~Account:1003,,,Password,*constant,CGRateS.org,false,20
|
||||
cgrates.org,ATTR_1001_SESSIONAUTH,*sessions,*string:~Account:1001,,,Password,*constant,CGRateS.org,false,10
|
||||
cgrates.org,ATTR_1001_SIMPLEAUTH,simpleauth,*string:~*req.Account:1001,,,Password,*constant,CGRateS.org,false,20
|
||||
cgrates.org,ATTR_1002_SIMPLEAUTH,simpleauth,*string:~*req.Account:1002,,,Password,*constant,CGRateS.org,false,20
|
||||
cgrates.org,ATTR_1003_SIMPLEAUTH,simpleauth,*string:~*req.Account:1003,,,Password,*constant,CGRateS.org,false,20
|
||||
cgrates.org,ATTR_1001_SESSIONAUTH,*sessions,*string:~*req.Account:1001,,,Password,*constant,CGRateS.org,false,10
|
||||
cgrates.org,ATTR_1001_SESSIONAUTH,,,,,RequestType,*constant,*prepaid,,
|
||||
cgrates.org,ATTR_1001_SESSIONAUTH,,,,,PaypalAccount,*constant,cgrates@paypal.com,,
|
||||
cgrates.org,ATTR_1001_SESSIONAUTH,,,,,LCRProfile,*constant,premium_cli,,
|
||||
cgrates.org,ATTR_1002_SESSIONAUTH,*sessions,*string:~Account:1002,,,Password,*constant,CGRateS.org,false,10
|
||||
cgrates.org,ATTR_1002_SESSIONAUTH,*sessions,*string:~*req.Account:1002,,,Password,*constant,CGRateS.org,false,10
|
||||
cgrates.org,ATTR_1002_SESSIONAUTH,,,,,RequestType,*constant,*postpaid,,
|
||||
cgrates.org,ATTR_1002_SESSIONAUTH,,,,,PaypalAccount,*constant,cgrates@paypal.com,,
|
||||
cgrates.org,ATTR_1002_SESSIONAUTH,,,,,LCRProfile,*constant,premium_cli,,
|
||||
cgrates.org,ATTR_1002_SESSIONAUTH,,,,,ResourceAllocation,*constant,"ResGroup1",,
|
||||
cgrates.org,ATTR_1003_SESSIONAUTH,*sessions,*string:~Account:1003,,,Password,*constant,CGRateS.org,false,10
|
||||
cgrates.org,ATTR_1003_SESSIONAUTH,*sessions,*string:~*req.Account:1003,,,Password,*constant,CGRateS.org,false,10
|
||||
cgrates.org,ATTR_1003_SESSIONAUTH,,,,,RequestType,*constant,*prepaid,,
|
||||
cgrates.org,ATTR_1003_SESSIONAUTH,,,,,PaypalAccount,*constant,cgrates@paypal.com,,
|
||||
cgrates.org,ATTR_1003_SESSIONAUTH,,,,,LCRProfile,*constant,premium_cli,,
|
||||
cgrates.org,ATTR_ACC_ALIAS,*any,*string:~SubscriberId:1006,,,Account,*constant,1001,false,10
|
||||
cgrates.org,ATTR_ACC_ALIAS,*any,*string:~*req.SubscriberId:1006,,,Account,*constant,1001,false,10
|
||||
cgrates.org,ATTR_ACC_ALIAS,*any,,,,RequestType,*constant,*prepaid,,
|
||||
cgrates.com,ATTR_TNT_ALIAS,*any,*string:~SubscriberId:1006,,,Account,*constant,1001,false,10
|
||||
cgrates.com,ATTR_TNT_ALIAS,*any,*string:~*req.SubscriberId:1006,,,Account,*constant,1001,false,10
|
||||
cgrates.com,ATTR_TNT_ALIAS,*any,,,,RequestType,*constant,*prepaid,,
|
||||
cgrates.com,ATTR_TNT_ALIAS,*any,,,,*tenant,*constant,cgrates.org,,
|
||||
cgrates.com,ATTR_TNT_1001,*any,*string:~Account:1001,,,*tenant,*constant,cgrates.org,,
|
||||
cgrates.com,ATTR_TNT_DISC,*any,*string:~Account:testDiamInitWithSessionDisconnect,,,*tenant,*constant,cgrates.org,,
|
||||
cgrates.com,ATTR_TNT_1001,*any,*string:~*req.Account:1001,,,*tenant,*constant,cgrates.org,,
|
||||
cgrates.com,ATTR_TNT_DISC,*any,*string:~*req.Account:testDiamInitWithSessionDisconnect,,,*tenant,*constant,cgrates.org,,
|
||||
|
||||
|
@@ -1,13 +1,13 @@
|
||||
#Tenant[0],ID[1],FilterType[2],FilterFieldName[3],FilterFieldValues[4],ActivationInterval[5]
|
||||
cgrates.org,FLTR_RES,*string,~Account,1001;1002;1003,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_FS,*string,~Account,1001,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_FS,*destinations,~Destination,DST_FS,
|
||||
cgrates.org,FLTR_ACNT_1001_1002,*string,~Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_1001_1002,*string,~RunID,*default,
|
||||
cgrates.org,FLTR_ACNT_1001_1002,*string,~Destination,1001;1002;1003,
|
||||
cgrates.org,FLTR_ACNT_1001,*string,~Account,1001,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_1002,*string,~Account,1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_1003,*string,~Account,1003,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_1003_1001,*string,~Account,1003,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_1003_1001,*string,~RunID,*default,
|
||||
cgrates.org,FLTR_ACNT_1003_1001,*string,~Destination,1001,
|
||||
cgrates.org,FLTR_RES,*string,~*req.Account,1001;1002;1003,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_FS,*string,~*req.Account,1001,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_DST_FS,*destinations,~*req.Destination,DST_FS,
|
||||
cgrates.org,FLTR_ACNT_1001_1002,*string,~*req.Account,1001;1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_1001_1002,*string,~*req.RunID,*default,
|
||||
cgrates.org,FLTR_ACNT_1001_1002,*string,~*req.Destination,1001;1002;1003,
|
||||
cgrates.org,FLTR_ACNT_1001,*string,~*req.Account,1001,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_1002,*string,~*req.Account,1002,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_1003,*string,~*req.Account,1003,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_1003_1001,*string,~*req.Account,1003,2014-07-29T15:00:00Z
|
||||
cgrates.org,FLTR_ACNT_1003_1001,*string,~*req.RunID,*default,
|
||||
cgrates.org,FLTR_ACNT_1003_1001,*string,~*req.Destination,1001,
|
||||
|
||||
|
@@ -135,6 +135,8 @@ func (dS *DispatcherService) dispatcherProfileForEvent(ev *utils.CGREvent,
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
evNm := config.NewNavigableMap(nil)
|
||||
evNm.Set([]string{utils.MetaReq}, ev.Event, false, false)
|
||||
for prflID := range prflIDs {
|
||||
prfl, err := dS.dm.GetDispatcherProfile(ev.Tenant, prflID, true, true, utils.NonTransactional)
|
||||
if err != nil {
|
||||
@@ -148,7 +150,7 @@ func (dS *DispatcherService) dispatcherProfileForEvent(ev *utils.CGREvent,
|
||||
continue
|
||||
}
|
||||
if pass, err := dS.fltrS.Pass(ev.Tenant, prfl.FilterIDs,
|
||||
config.NewNavigableMap(ev.Event)); err != nil {
|
||||
evNm); err != nil {
|
||||
return nil, err
|
||||
} else if !pass {
|
||||
continue
|
||||
|
||||
@@ -554,7 +554,8 @@ func (fS *FilterS) getFieldNameDataProvider(initialDP config.DataProvider,
|
||||
strings.HasPrefix(*fieldName, utils.DynamicDataPrefix+utils.MetaCgreq),
|
||||
strings.HasPrefix(*fieldName, utils.DynamicDataPrefix+utils.MetaCgrep),
|
||||
strings.HasPrefix(*fieldName, utils.DynamicDataPrefix+utils.MetaRep),
|
||||
strings.HasPrefix(*fieldName, utils.DynamicDataPrefix+utils.MetaCGRAReq):
|
||||
strings.HasPrefix(*fieldName, utils.DynamicDataPrefix+utils.MetaCGRAReq),
|
||||
strings.HasPrefix(*fieldName, utils.DynamicDataPrefix+utils.MetaAct):
|
||||
dp = initialDP
|
||||
// don't need to take out the prefix because the navigable map have ~*req prefix
|
||||
case *fieldName == utils.EmptyString:
|
||||
@@ -634,7 +635,8 @@ func (fS *FilterS) getFieldValueDataProvider(initialDP config.DataProvider,
|
||||
strings.HasPrefix(*fieldValue, utils.DynamicDataPrefix+utils.MetaCgreq),
|
||||
strings.HasPrefix(*fieldValue, utils.DynamicDataPrefix+utils.MetaCgrep),
|
||||
strings.HasPrefix(*fieldValue, utils.DynamicDataPrefix+utils.MetaRep),
|
||||
strings.HasPrefix(*fieldValue, utils.DynamicDataPrefix+utils.MetaCGRAReq):
|
||||
strings.HasPrefix(*fieldValue, utils.DynamicDataPrefix+utils.MetaCGRAReq),
|
||||
strings.HasPrefix(*fieldValue, utils.DynamicDataPrefix+utils.MetaAct):
|
||||
dp = initialDP
|
||||
default: // in case of constant we give an empty DataProvider ( empty navigable map )
|
||||
dp = config.NewNavigableMap(nil)
|
||||
|
||||
@@ -272,7 +272,7 @@ func testV1FltrPupulateThreshold(t *testing.T) {
|
||||
tPrfl := &engine.ThresholdProfile{
|
||||
Tenant: "cgrates.org",
|
||||
ID: "TH_Stats1",
|
||||
FilterIDs: []string{"FLTR_TH_Stats1", "*string:~Account:1010"},
|
||||
FilterIDs: []string{"FLTR_TH_Stats1", "*string:~*req.Account:1010"},
|
||||
ActivationInterval: &utils.ActivationInterval{
|
||||
ActivationTime: time.Date(2014, 7, 14, 14, 35, 0, 0, time.UTC),
|
||||
ExpiryTime: time.Date(2014, 7, 14, 14, 35, 0, 0, time.UTC),
|
||||
@@ -340,7 +340,7 @@ func testV1FltrGetThresholdForEvent2(t *testing.T) {
|
||||
tPrfl := &engine.ThresholdProfile{
|
||||
Tenant: "cgrates.org",
|
||||
ID: "TH_Stats1",
|
||||
FilterIDs: []string{"FLTR_TH_Stats1", "*string:~Account:1010"},
|
||||
FilterIDs: []string{"FLTR_TH_Stats1", "*string:~*req.Account:1010"},
|
||||
ActivationInterval: &utils.ActivationInterval{
|
||||
ActivationTime: time.Date(2014, 7, 14, 14, 35, 0, 0, time.UTC),
|
||||
ExpiryTime: time.Date(2014, 7, 14, 14, 35, 0, 0, time.UTC),
|
||||
@@ -441,7 +441,7 @@ func testV1FltrPopulateResources(t *testing.T) {
|
||||
tPrfl := &engine.ThresholdProfile{
|
||||
Tenant: "cgrates.org",
|
||||
ID: "TH_ResTest",
|
||||
FilterIDs: []string{"FLTR_TH_Resource", "*string:~Account:2020"},
|
||||
FilterIDs: []string{"FLTR_TH_Resource", "*string:~*req.Account:2020"},
|
||||
ActivationInterval: &utils.ActivationInterval{
|
||||
ActivationTime: time.Date(2014, 7, 14, 14, 35, 0, 0, time.UTC),
|
||||
ExpiryTime: time.Date(2014, 7, 14, 14, 35, 0, 0, time.UTC),
|
||||
@@ -558,7 +558,7 @@ func testV1FltrAccounts(t *testing.T) {
|
||||
tPrfl := &engine.ThresholdProfile{
|
||||
Tenant: "cgrates.org",
|
||||
ID: "TH_Account",
|
||||
FilterIDs: []string{"FLTR_TH_Accounts", "*string:~Account:1001"},
|
||||
FilterIDs: []string{"FLTR_TH_Accounts", "*string:~*req.Account:1001"},
|
||||
ActivationInterval: &utils.ActivationInterval{
|
||||
ActivationTime: time.Date(2014, 7, 14, 14, 35, 0, 0, time.UTC),
|
||||
ExpiryTime: time.Date(2014, 7, 14, 14, 35, 0, 0, time.UTC),
|
||||
|
||||
@@ -156,7 +156,7 @@ func testRPCMethodsAddData(t *testing.T) {
|
||||
tPrfl := &engine.ThresholdProfile{
|
||||
Tenant: "cgrates.org",
|
||||
ID: "THD_AccDisableAndLog",
|
||||
FilterIDs: []string{"*string:~*req.Account:1001", "*string:~DisableAction:DisableAction"},
|
||||
FilterIDs: []string{"*string:~*req.Account:1001", "*string:~*req.DisableAction:DisableAction"},
|
||||
MaxHits: -1,
|
||||
MinSleep: time.Duration(1 * time.Second),
|
||||
Weight: 30.0,
|
||||
@@ -171,7 +171,7 @@ func testRPCMethodsAddData(t *testing.T) {
|
||||
tPrfl2 := &engine.ThresholdProfile{
|
||||
Tenant: "cgrates.org",
|
||||
ID: "THD_AccEnableAndLog",
|
||||
FilterIDs: []string{"*string:~*req.Account:1001", "*string:~EnableAction:EnableAction"},
|
||||
FilterIDs: []string{"*string:~*req.Account:1001", "*string:~*req.EnableAction:EnableAction"},
|
||||
MaxHits: -1,
|
||||
MinSleep: time.Duration(1 * time.Second),
|
||||
Weight: 30.0,
|
||||
|
||||
@@ -238,7 +238,7 @@ func testV1SplSAddNewResPrf(t *testing.T) {
|
||||
rPrf := &engine.ResourceProfile{
|
||||
Tenant: "cgrates.org",
|
||||
ID: "ResourceSupplier1",
|
||||
FilterIDs: []string{"*string:~*req.Supplier:supplier1", "*string:~ResID:ResourceSupplier1"},
|
||||
FilterIDs: []string{"*string:~*req.Supplier:supplier1", "*string:~*req.ResID:ResourceSupplier1"},
|
||||
ActivationInterval: &utils.ActivationInterval{
|
||||
ActivationTime: time.Date(2014, 7, 14, 14, 25, 0, 0, time.UTC),
|
||||
ExpiryTime: time.Date(2014, 7, 14, 14, 25, 0, 0, time.UTC),
|
||||
@@ -259,7 +259,7 @@ func testV1SplSAddNewResPrf(t *testing.T) {
|
||||
rPrf2 := &engine.ResourceProfile{
|
||||
Tenant: "cgrates.org",
|
||||
ID: "Resource2Supplier1",
|
||||
FilterIDs: []string{"*string:~*req.Supplier:supplier1", "*string:~ResID:Resource2Supplier1"},
|
||||
FilterIDs: []string{"*string:~*req.Supplier:supplier1", "*string:~*req.ResID:Resource2Supplier1"},
|
||||
ActivationInterval: &utils.ActivationInterval{
|
||||
ActivationTime: time.Date(2014, 7, 14, 14, 25, 0, 0, time.UTC),
|
||||
ExpiryTime: time.Date(2014, 7, 14, 14, 25, 0, 0, time.UTC),
|
||||
@@ -280,7 +280,7 @@ func testV1SplSAddNewResPrf(t *testing.T) {
|
||||
rPrf3 := &engine.ResourceProfile{
|
||||
Tenant: "cgrates.org",
|
||||
ID: "ResourceSupplier2",
|
||||
FilterIDs: []string{"*string:~*req.Supplier:supplier2", "*string:~ResID:ResourceSupplier2"},
|
||||
FilterIDs: []string{"*string:~*req.Supplier:supplier2", "*string:~*req.ResID:ResourceSupplier2"},
|
||||
ActivationInterval: &utils.ActivationInterval{
|
||||
ActivationTime: time.Date(2014, 7, 14, 14, 25, 0, 0, time.UTC),
|
||||
ExpiryTime: time.Date(2014, 7, 14, 14, 25, 0, 0, time.UTC),
|
||||
@@ -301,7 +301,7 @@ func testV1SplSAddNewResPrf(t *testing.T) {
|
||||
rPrf4 := &engine.ResourceProfile{
|
||||
Tenant: "cgrates.org",
|
||||
ID: "ResourceSupplier3",
|
||||
FilterIDs: []string{"*string:~*req.Supplier:supplier3", "*string:~ResID:ResourceSupplier3"},
|
||||
FilterIDs: []string{"*string:~*req.Supplier:supplier3", "*string:~*req.ResID:ResourceSupplier3"},
|
||||
ActivationInterval: &utils.ActivationInterval{
|
||||
ActivationTime: time.Date(2014, 7, 14, 14, 25, 0, 0, time.UTC),
|
||||
ExpiryTime: time.Date(2014, 7, 14, 14, 25, 0, 0, time.UTC),
|
||||
|
||||
Reference in New Issue
Block a user