Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

p_usrloc: add new update function #2253

Merged
merged 1 commit into from Mar 16, 2020

Conversation

smititelu
Copy link
Contributor

Add also new "uniq" column.
The new update function will use this new column.

Pre-Submission Checklist

  • 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:

  • PR should be backported to stable branches
  • Tested changes locally
  • Related to issue #XXXX (replace XXXX with an open issue number)

Description

@henningw
Copy link
Contributor

Thanks for the pull request.
I think it might be better to use a value of "2" to specify the new scheme (at least in the docs). This would be more similar to the way other modules mode parameter work.
Did I understand it correctly that you add a new DB column? Is this for the reg_db table or the (partitioned) location table?

@smititelu
Copy link
Contributor Author

I've updated the pull request to consider only 0, 1, 2 values (docs and code).

I've added the new function to consider additional columns when updating database; "uniq_col" is one of them. We have some user agents that send "uniq" in Contact header of SIP REGISTER message.

@henningw
Copy link
Contributor

Thank you. So I understand correctly that the "new way" is using the uniq column for updates.

The p_usrloc module is not using the generic DB scheme infrastructure. So it would be great if you could also update the location.sql file in the p_usrloc module directory to include the new column definition, just to have it somewhere defined.

Add also new "uniq" column.
The new update function will use this new column.
@smititelu
Copy link
Contributor Author

Updated p_usrloc's location.sql to include "uniq" column.

@henningw
Copy link
Contributor

Thanks again, you can merge.

@smititelu smititelu merged commit d1f525c into kamailio:master Mar 16, 2020
@smititelu
Copy link
Contributor Author

Thanks for review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants