new columns available:
EVENT_TIMESTAMP: same as TIMESTAMP (the edr event timestamp),
but including formatting (fractional seconds + rounding)
exactly like cdr START_TIME/INIT_TIME/END_TIME
EVENT_TIMEZONE: the subscriber's inherited timezone
TIMESTAMP_LOCALIZED: the event's timestamp with the
subscriber's inherited timezone applied. same formatting
as EVENT_TIMESTAMP
Change-Id: Id63b92d111e1c5bdb36e9f710f1d464e9e7ed44c
Nodename is always 'sp1' or 'sp2' for both PRO and Carrier,
while none of them are available into Carrier's network.yml.
We should not destroy proper nodename in 'out' on Carrier
(in CE failover code). Ensure we are on CE before using 'self'.
P.S CE network.yml uses 'hosts.self' historically as we never
controlled the server filename on CE.
Change-Id: I6042511e8383a01b1439323204284cfb087e7bca
The variable nodename is defined inside 'PERL' section only
and not available in template toolkit env, so we should check
variable 'out' here, as it currently contains the actual value.
The library has been created long time ago, while
we never used it previously, so the issue has been hidden here.
Change-Id: Iac3547fd60126456feea85d7bb5ffcdc6edb23a2
new fields for cdr exports:
TIMEZONE:
a. call to offnet destination: take source subscriber's inherited tz
b. offnet to local destination: take destination subscriber's inherited tz
c. onnet calls: take the *source* subscriber's inherited tz
(see cdr-exporter.pl -> source reseller folder will contain the
cdr only)
d. transit calls: take system timezone
INIT_TIME_LOCALIZED: init time with timezone applied
START_TIME: start time with timezone applied
END_TIME: end time with timezone applied
Change-Id: I29590fc1b6f37269294518cfece4b4e16f25c3e6
* ['online', 'inactive'] as default
* introduced in order to be able to filter values at templates
so we have the ability to install new nodes without
impacting the working system
Change-Id: I78739f66f80da310347861e86b682fcf72745080
Stop inferring from the metapackage presence and instead use the
variable general.ngcp_type from the constants.yml file which should now
always be present.
Change-Id: I68e97f6894094fe6a1589fa73b048b061eae4a7b
ticket 13069 describes in detail the additions for event-based
billing required by a customer of the hpbx platform. these
additional edr fields will allow to export a single column
showing the subscriber alias for both start and stop profile
events.
Change-Id: Ibd2f9b05ed708521b23cf3db09c68267cf085e3b
In templates' bootenv/sources.list.d/{debian,sipwise}.list we
don't want to hardcode the Debian release, but instead make sure
it matches the underlying Debian release.
Change-Id: I9c844fa2f22bdfa4008b7ff2b9afe9f6634f7d29
For iptables firewall rules it is necessary to translate hostnames,
which may be used in config.yml into a list of IPs as returned by
"gethostbyname".
Change-Id: I149227d5031534d3826a2c91012a599f7c7c4756
There are currently several places in templates where we do request
ngcp version, lets create a helper here, then we will be able to
switch on it after the next LTS is released (mr5.5).
Unfortunately we cannot switch on it before the next LTS,
otherwise upgrade mr4.4->mr5.5 may be corrupted by users.
If sp1 has been upgraded already and sp2 is not while
sp2 has received new templates already while ngcpcfg package
is still old -> templates cannot be built as helper is not found.
Change-Id: Icce966097335eddb7b09303ac2ef8081092bb8f3
the way we create these output timestamps with fractional
seconds is wrong, because FROM_UNIXTIME is not truncating
its argument to int, but its rounds up/down.
"CONCAT(FROM_UNIXTIME(accounting.cdr.start_time +
accounting.cdr.duration), \".
\", SUBSTRING_INDEX(accounting.cdr.start_time +
accounting.cdr.duration, \".\",
-1))"
correct values are:
start: 2016-09-06 06:58:27.586
+duration: 0.520
end: 2016-09-06 06:58:28.120
so all of init_time, start_time, end_time are wrongn. fix
means an explicit int cast via FLOOR:
"CONCAT(FROM_UNIXTIME(FLOOR(accounting.cdr.start_time +
accounting.cdr.duration)), \".
\", SUBSTRING_INDEX(accounting.cdr.start_time +
accounting.cdr.duration, \".\",
-1))"
Change-Id: If6afaed4b1a573b36d0151c0d39eea05ba14b9ba
new fields can be simply specified in config.yml, e.g.
" - source_customer_cash_balance_before"
" - source_customer_free_time_balance_before"
" - source_customer_profile_package_id"
" - source_customer_contract_balance_id"
whereby
+"source" can be replaced by "destination"
+"customer" can be replaced by "carrier", "reseller"
+"before" can be replaced by "after"
note that:
+ these field names are not case sensitive
+ those fields cannot be used in export conditions atm
finally, also melita's END_TIME named field was added,
identical like START_TIME.
Change-Id: I669259be53878058bc2ec0927e96496dcbd534bd
This was producing empty values at kamailio.cfg template on CE
with a cluster_set of central type
Thanks to Anibal Cañada for the bugreport
Change-Id: Ib11295611859ef2828dc1d2e6900bf201c20ad7a
This was producing empty values at ngcp-ossbss template mysql_values.cfg file
on a cluster_set of central type
Change-Id: I68160a9c5bef078d3154c6e8da6db1e9bcbb07aa