Blog: A Multi Tenant API for PJSIP

Towards a Multi Tenant API for PJSIP

Asterisk has been switching from the legacy chan_sip channel driver to a new SIP stack based on the PJSIP library. We have been using the new SIP stack in Wazo Platform for over a year now. The way we configure the SIP channel driver as of Wazo Platform 20.03 still relies on the API that existed for chan_sip with a translation layer in wazo-confgend to convert the chan_sip configuration to a chan_pjsip one…

https://wazo-platform.org/blog/pjsip-multi-tenant

Does this mean, when the system converts to an untranslated pjsip scenario, that we will have to update our SIP configurations to use only pjsip syntax?

The current setup has a mix of sip and pjsip and the translator handles this distinction, but will that not continue in the new system?

Hi Ramblin,

the upgrade from the old to the new system will do it’s best to migrate your configuration to the new format.

We expect that all working configuration that work today will also work after the upgrade. Including the mixing of SIP and PJSIP fields.

If you used a PJSIP configuration option, it will be used.
If you used a chan_sip configuration option, it will be translated.
Anything unspecified will implicitly use the pjsip defaults.

This is the same logic as what is currently applied. If there are exceptions there will be an entry in the changelog describing which part of the configuration we failed to migrate.

After the migration chan_sip configurations will NOT be translated to there pjsip equivalent anymore.

For example
adding nat=force_rport will not work after the migration. you’ll have to use the PJSIP options which are force_rport=yes, rewrite_contat=yes

Any manual configuration files in /etc/asterisk/pjsip.d/ will NOT be modified.

1 Like

When will the Wazo switch to the new system ?

You mention 20.03 as still using the translation system. Does this mena some (near-term) version 20.05, …?) will no longer offer the translation capability or is this something that is still in the works and will not be introduced for a few iterations?

If, in the Web GUI, I have set Options in Lines or SIP_General settings using chan_sip, do I go in and change to chan_pjsip or will the conversion do that for me and change the entries that show in the Options in Lines or SIP_General entries in the Web GUI?