TT#70068 Add new header to MWI SIP message.

- new header P-NGCP-MWI-Id, that contains the internal
  NGCP message id and needed to distinguish new/old
  messages order within a subscriber to perform selec-
  tive messages handling.

Change-Id: I21556b1ced05baac8f373c2cd15ca63ae45e2c02
changes/77/34677/10
Fabricio Santolin da Silva 6 years ago
parent fb7aa3a49e
commit 16104612e3

@ -9,7 +9,7 @@ Event: message-summary
User-Agent: Sipwise NGCP Application Server
Content-Type: application/simple-message-summary
Content-Length: $BODYLEN$
$MWI_ID$
$BODY_MW$
$BODY_VM$

@ -288,6 +288,7 @@ sub main {
($data{user}, $data{domain}) = get_user_domain($data{mailbox});
my $etag = get_etag($data{user}, $data{domain});
my $sipifmatch = defined $etag ? "SIP-If-Match: $etag" : "STRIP";
my $mwiid = $data{msgnum} ge 0 ? "P-NGCP-MWI-Id: $data{msgnum}\n": "";
my %macros = (
body_mw => "Messages-Waiting: ". ($data{new} ? "yes" : "no"),
@ -297,6 +298,7 @@ sub main {
user => $data{user},
domain => $data{domain},
sipifmatch => $sipifmatch,
mwi_id => $mwiid,
);
send_mwi_notify(\%macros);

Loading…
Cancel
Save