<!-- Kamailio Pull Request Template -->
<!--
IMPORTANT:
- for detailed contributing guidelines, read:
https://github.com/kamailio/kamailio/blob/master/.github/CONTRIBUTING.md
- pull requests must be done to master branch, unless they are backports
of fixes from master branch to a stable branch
- backports to stable branches must be done with 'git cherry-pick -x ...'
- code is contributed under BSD for core and main components (tm, sl, auth, tls)
- code is contributed GPLv2 or a compatible license for the other components
- GPL code is contributed with OpenSSL licensing exception
-->
#### Pre-Submission Checklist
<!-- Go over all points below, and after creating the PR, tick all the checkboxes that apply -->
<!-- All points should be verified, otherwise, read the CONTRIBUTING guidelines from above-->
<!-- If you're unsure about any of these, don't hesitate to ask on sr-dev mailing list -->
- [x] Commit message has the format required by CONTRIBUTING guide
- [x] Commits are split per component (core, individual modules, libs, utils, ...)
- [x] Each component has a single commit (if not, squash them into one commit)
- [x] No commits to README files for modules (changes must be done to docbook files
in `doc/` subfolder, the README file is autogenerated)
#### Type Of Change
- [x] Small bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds new functionality)
- [ ] Breaking change (fix or feature that would change existing functionality)
#### Checklist:
<!-- Go over all points below, and after creating the PR, tick the checkboxes that apply -->
- [ ] PR should be backported to stable branches
- [ ] Tested changes locally
- [ ] Related to issue #XXXX (replace XXXX with an open issue number)
#### Description
<!-- Describe your changes in detail -->
Adding sqlfile ims i-cscf to utils/kamctl/mysql copied from misc/examples/ims/icscf
so that sql file will be automatically included in kamailio-mysql-module packages in the future
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/3876
-- Commit Summary --
* IMS DB: Adding i-cscf database/tables under utils/kamctl/mysql
-- File Changes --
A utils/kamctl/mysql/ims-icscf.sql (94)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/3876.patchhttps://github.com/kamailio/kamailio/pull/3876.diff
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3876
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/pull/3876(a)github.com>
Related to #3961
<!-- Kamailio Pull Request Template -->
<!--
IMPORTANT:
- for detailed contributing guidelines, read:
https://github.com/kamailio/kamailio/blob/master/.github/CONTRIBUTING.md
- pull requests must be done to master branch, unless they are backports
of fixes from master branch to a stable branch
- backports to stable branches must be done with 'git cherry-pick -x ...'
- code is contributed under BSD for core and main components (tm, sl, auth, tls)
- code is contributed GPLv2 or a compatible license for the other components
- GPL code is contributed with OpenSSL licensing exception
-->
#### Pre-Submission Checklist
<!-- Go over all points below, and after creating the PR, tick all the checkboxes that apply -->
<!-- All points should be verified, otherwise, read the CONTRIBUTING guidelines from above-->
<!-- If you're unsure about any of these, don't hesitate to ask on sr-dev mailing list -->
- [x] Commit message has the format required by CONTRIBUTING guide
- [ ] Commits are split per component (core, individual modules, libs, utils, ...)
- [ ] Each component has a single commit (if not, squash them into one commit)
- [ ] No commits to README files for modules (changes must be done to docbook files
in `doc/` subfolder, the README file is autogenerated)
#### Type Of Change
- [ ] Small bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds new functionality)
- [ ] Breaking change (fix or feature that would change existing functionality)
#### Checklist:
<!-- Go over all points below, and after creating the PR, tick the checkboxes that apply -->
- [ ] PR should be backported to stable branches
- [ ] Tested changes locally
- [ ] Related to issue #XXXX (replace XXXX with an open issue number)
#### Description
<!-- Describe your changes in detail -->
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/3975
-- Commit Summary --
* dialog: Remove dlg_flag docs
-- File Changes --
M src/modules/dialog/dlg_handlers.c (2)
M src/modules/dialog/doc/dialog_admin.xml (16)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/3975.patchhttps://github.com/kamailio/kamailio/pull/3975.diff
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3975
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/pull/3975(a)github.com>
Hello
The tm.t_uac_start function generates a “tm:local-request” event.
But the tm.cancel function doesn't generete “tm:local-request” event.
Is it possible to activate a parameter in the TM or TMX module to generate the event?
Thanks
Juan
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3831
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/3831(a)github.com>
<!--
Kamailio Project uses GitHub Issues only for bugs in the code or feature requests. Please use this template only for feature requests.
If you have questions about using Kamailio or related to its configuration file, ask on sr-users mailing list:
* https://lists.kamailio.org/mailman3/postorius/lists/sr-users.lists.kamailio…
If you have questions about developing extensions to Kamailio or its existing C code, ask on sr-dev mailing list:
* https://lists.kamailio.org/mailman3/postorius/lists/sr-dev.lists.kamailio.o…
Please try to fill this template as much as possible for any issue. It helps the developers to troubleshoot the issue.
If you submit a feature request (or enhancement) add the description of what you would like to be added.
If there is no content to be filled in a section, the entire section can be removed.
Note that a feature request may be closed automatically after about 2 months
if there is no interest from developers or community users to implement it, being
considered expired. In such case can be reopened by writing a comment that includes
the token `/notexpired`. About two weeks before considered expired, the item is
marked with the label `stale`, trying to notify the submitter and everyone else
that might be interested in it. To remove the label `stale`, write a comment that
includes the token `/notstale`. Also, any comment postpone the `expire` timeline,
being considered that there is interest in the proposed feature request.
You can delete the comments from the template sections when filling.
You can delete next line and everything above before submitting (it is a comment).
-->
### Description
I followed the page 18~23 of this slide [20-Federico.Cabiddu-Kamailio-In-A-Mobile-World](https://www.kamailio.org/ev… to implement suspension & push notification, it worked well on mobile devices.
However, callee might have several location records on some occasions, for instance, they forcibly quit the app or kill the browser, meaning they don't de-register, the location hasn't expired and still exists, but it is stale and unreachable, this makes `t_relay` failed (return code is -2 and didn't trigger failure_route) since Kamailio `lookup` the stale location rather than the new one as they get push notification, below are some part of logs.
```
ERROR: tm [t_fwd.c:484]: prepare_new_uac(): could not build request
ERROR: tm [t_fwd.c:1764]: t_forward_nonack(): failure to add branches
ERROR: <script>: not t_relay by INVITE -2
ERROR: <script>: check status code is 100
```
The rest of Kamailio code triggers `sl_reply_error`, caller gets 500 and terminates.
### Expected behavior
When callee has several locations, even if some of them are stale, callee should not terminate the call and should find a valid location to ring the target.
#### Actual observed behavior
Caller finds invalid locations and gets 500 error msg.
#### Debugging Data
What I have tried
1. Run `suspend` when `t_relay` failed.
```
if (!t_relay()) {
revert_uri();
route(SUSPEND);
}
```
It doesn't work since `t_continue` still tries to recover the call with the stale location.
2. Run `append_branch` before `t_relay`.
```
if (!lookup("location")) {
send_replay("100", "Trying");
route(SUSPEND);
} else {
append_branch($tu);
t_relay();
ts_store();
$sht(vtp=>stored::$rU) = 1;
xdbg("stored transaction [$T(id_index):$T(id_label)] $fU=> $rU\n");
}
```
This version of caller won't get 500 and terminate, but callee cannot finds the resumed call.
3. Use `t_load_contacts` and `t_next_contact`.
```
t_load_contacts();
while (t_next_contacts()) {
xlog ("==== $ru\n");
}
```
t_next_contacts always return -2 (nothing to do), but I can see the new location via command `kamctl ul show`.
#### Log Messages
<!--
Check the syslog file and if there are relevant log messages printed by Kamailio, add them next, or attach to issue, or provide a link to download them (e.g., to a pastebin site).
-->
```
(paste your log messages here)
```
#### SIP Traffic
<!--
If the issue is exposed by processing specific SIP messages, grab them with ngrep or save in a pcap file, then add them next, or attach to issue, or provide a link to download them (e.g., to a pastebin site).
-->
```
(paste your sip traffic here)
```
### Possible Solutions
<!--
If you found a solution or workaround for the issue, describe it. Ideally, provide a pull request with a improvement.
-->
### Additional Information
* **Kamailio Version** - output of `kamailio -v`
```
(paste your output here)
```
* **Operating System**:
<!--
Details about the operating system, the type: Linux (e.g.,: Debian 8.4, Ubuntu 16.04, CentOS 7.1, ...), MacOS, xBSD, Solaris, ...;
Kernel details (output of `uname -a`)
-->
```
(paste your output here)
```
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/issues/3985
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/issues/3985(a)github.com>
#### Pre-Submission Checklist
- [x] Commit message has the format required by CONTRIBUTING guide
- [x] Commits are split per component (core, individual modules, libs, utils, ...)
- [x] Each component has a single commit (if not, squash them into one commit)
- [x] No commits to README files for modules (changes must be done to docbook files
in `doc/` subfolder, the README file is autogenerated)
#### Type Of Change
- [ ] Small bug fix (non-breaking change which fixes an issue)
- [x] New feature (non-breaking change which adds new functionality)
- [ ] Breaking change (fix or feature that would change existing functionality)
#### Checklist:
<!-- Go over all points below, and after creating the PR, tick the checkboxes that apply -->
- [x] PR should be backported to stable branches
- [x] Tested changes locally
- [ ] Related to issue #XXXX (replace XXXX with an open issue number)
#### Description
This change allows to enable/disable the insertion of SIP traces into the DB at runtime (i know we could do this with `siptrace.status`, but this is a different case).
This feature is strictly important if you start `Kamailio` with `trace_to_database` parameter disabled, and you want to enable it later and at runtime.
Nowadays, if you try to start `Kamailio` with `trace_to_database` enabled, but without a connection to the DB, the service won't start (`child_init` logic).
In this type of situation, it makes sense to start `Kamailio` disabling the `trace_to_database` parameter, and when the DB is ok, at runtime, we enable `trace_to_database` parameter. This prevents the need to restart the service, and also we can start `Kamailio` without problems, if DB of SIP Traces is NOK at that time.
My PR may need some improvements, especially on the enable side, so feel free to make any changes to improve that.
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/3877
-- Commit Summary --
* siptrace: handle trace_to_database param at runtime
-- File Changes --
M src/modules/siptrace/siptrace.c (100)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/3877.patchhttps://github.com/kamailio/kamailio/pull/3877.diff
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3877
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/pull/3877(a)github.com>
<!-- Kamailio Pull Request Template -->
<!--
IMPORTANT:
- for detailed contributing guidelines, read:
https://github.com/kamailio/kamailio/blob/master/.github/CONTRIBUTING.md
- pull requests must be done to master branch, unless they are backports
of fixes from master branch to a stable branch
- backports to stable branches must be done with 'git cherry-pick -x ...'
- code is contributed under BSD for core and main components (tm, sl, auth, tls)
- code is contributed GPLv2 or a compatible license for the other components
- GPL code is contributed with OpenSSL licensing exception
-->
#### Pre-Submission Checklist
<!-- Go over all points below, and after creating the PR, tick all the checkboxes that apply -->
<!-- All points should be verified, otherwise, read the CONTRIBUTING guidelines from above-->
<!-- If you're unsure about any of these, don't hesitate to ask on sr-dev mailing list -->
- [x] Commit message has the format required by CONTRIBUTING guide
- [x] Commits are split per component (core, individual modules, libs, utils, ...)
- [x] Each component has a single commit (if not, squash them into one commit)
- [x] No commits to README files for modules (changes must be done to docbook files
in `doc/` subfolder, the README file is autogenerated)
#### Type Of Change
- [ ] Small bug fix (non-breaking change which fixes an issue)
- [x] New feature (non-breaking change which adds new functionality)
- [ ] Breaking change (fix or feature that would change existing functionality)
#### Checklist:
<!-- Go over all points below, and after creating the PR, tick the checkboxes that apply -->
- [ ] PR should be backported to stable branches
- [x] Tested changes locally
- [ ] Related to issue #XXXX (replace XXXX with an open issue number)
#### Description
Allow Kamailio modules to register their log function so that all Kamailio log messages (coming from core and other modules) are logged uniformly in the format defined by the custom log function.
To enable the custom log format feature, Kamailio must be compiled with the `CUSTOM_LOG_FMT` flag. Then the module that wishes to modify the log format has to call `km_custom_log_func_set` during the initialization to supply a custom log formatting function (see `km_default_custom_log_func` as an example).
You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/3902
-- Commit Summary --
* core: add support for custom log function
-- File Changes --
M src/core/dprint.c (19)
M src/core/dprint.h (47)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/3902.patchhttps://github.com/kamailio/kamailio/pull/3902.diff
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3902
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/pull/3902(a)github.com>