This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision Next revision Both sides next revision | ||
devel:kamailio-5.0-design [2016/02/24 23:34] miconda [Build System] |
devel:kamailio-5.0-design [2016/03/01 09:25] miconda [Exporting Functions To Embedded Interpreters] |
||
---|---|---|---|
Line 1: | Line 1: | ||
====== Kamailio v5.0 Design ====== | ====== Kamailio v5.0 Design ====== | ||
+ | |||
+ | ===== Overview ===== | ||
After 15 years of development, | After 15 years of development, | ||
+ | |||
+ | This page collects suggestions and ideas for major refactoring of various components to make the leap to v5.0. | ||
+ | |||
+ | When adding a remark that needs to be tracked by author, use initials in front of the paragraph. The list of contributors to this document and initials: | ||
+ | |||
+ | * Daniel-Constantin Mierla (dcm) | ||
+ | |||
+ | ===== Initial Remarks ===== | ||
+ | |||
+ | Initial content for this document is listing also ideas popped up during discussions at Fosdem 2016 and Kamailio Development Workshop - among participants: | ||
===== Configuration File ===== | ===== Configuration File ===== | ||
+ | |||
+ | Goals: | ||
+ | |||
+ | * have at least one option of an optimized configuration file interpreter targeting high performance SIP routing deployments | ||
+ | * have at least one option of a more flexible configuration language that allows: | ||
+ | * extended language syntax | ||
+ | * reloading routing rules at runtime | ||
+ | |||
+ | To achieve the above, following sub-sections collects the proposals for configuration file language. | ||
+ | |||
==== Exporting Functions To Embedded Interpreters ==== | ==== Exporting Functions To Embedded Interpreters ==== | ||
- | * define and implement an export interface from modules to embedded interpreters to automatically add new functions to embedded interpreters, in a similar fashion as for adding functions to configuration file | + | * define and implement an export interface from modules to embedded interpreters to automatically add new functions to embedded interpreters |
+ | * it should be in a similar fashion as for adding functions to configuration file, but without fixup mechanism, so bare string/ | ||
+ | |||
+ | Interface fields: | ||
+ | |||
+ | * submodule name in embedded interpreter | ||
+ | * function name in embedded interpreter | ||
+ | * parameter types | ||
+ | * pointer to c function | ||
+ | |||
+ | Example: | ||
+ | |||
+ | <code c> | ||
+ | // export t_reply(200, | ||
+ | |||
+ | sr_exapi_t mod_exapi[] = { | ||
+ | { " | ||
+ | { 0, 0, {0}, 0} | ||
+ | }; | ||
+ | </ | ||
==== Routing Logic In Embedded Interpreters Scripting ==== | ==== Routing Logic In Embedded Interpreters Scripting ==== | ||
Line 16: | Line 57: | ||
===== Source Tree Structure ===== | ===== Source Tree Structure ===== | ||
+ | |||
+ | Goals: | ||
+ | |||
+ | * group files per components to be easier to spot their role, especially the core, include files and utilities | ||
+ | |||
+ | ==== Reorganizing Source Files Location ==== | ||
It was discussed in the past: | It was discussed in the past: | ||
* source code files should be relocated to have a better structure for include headers, core files, modules and internal libraries as well as utilities | * source code files should be relocated to have a better structure for include headers, core files, modules and internal libraries as well as utilities | ||
+ | |||
+ | Two models proposed: | ||
+ | |||
+ | * a) only move core files in a new ' | ||
+ | * b) move all source code files for Kamailio in a new ' | ||
===== Build System ===== | ===== Build System ===== | ||
- | Revising | + | Goals: |
+ | |||
+ | * revising | ||
+ | |||
+ | ==== Reviewing Alternative Build Systems ==== | ||
Alternatives to analyze: | Alternatives to analyze: | ||
Line 31: | Line 87: | ||
===== Continuous Integration ===== | ===== Continuous Integration ===== | ||
+ | |||
+ | Goals: | ||
+ | |||
+ | * attempt to make a more consistent and "easy to contribute to" continuous integration eco-system | ||
+ | |||
==== Unit Test Framework ==== | ==== Unit Test Framework ==== |