Hey Team,

I submitted a PR a while back that has not had much discussion:
https://github.com/kamailio/kamailio/pull/3828

The intention was to allow loading in unsigned integer IDs from DB into PVs.
Currently converting unsigned integers from DB to PVs will error by default unless the module specifically handles the ease use case. When the following parameter is enabled the srdb interface will allow the conversion to an integer PV value (possibly overflowing):

|modparam("db_mysql", "unsigned_type", 1) |

This PR allows the srdb APIs to convert the unsigned integer to an unsigned integer PV value. This can be quite useful in modules such as |auth_db| / |permissions| that can load an arbitrary column into a PV (|load_credentials|, |tag_col|/|peer_tag_avp|, etc..). Since most ID columns are auto incrementing unsigned integers this just makes sense for referring to customer data.

Elevator pitch over..
What I need help with is reviewing the srdb changes, since I am unsure what side effects that would have on other modules. Comments are welcome here, on the PR, or find me on the matrix channel (@devopsec).

Happy Coding..

Regards,

Tyler Moore
Full Stack Software Engineer
dOpenSource

​
_______________________________________________
Kamailio (SER) - Development Mailing List
To unsubscribe send an email to sr-dev-le...@lists.kamailio.org

Reply via email to