Skip to content

Commit b709875

Browse files
committed
config: add new module
1 parent 2e24dc6 commit b709875

File tree

21 files changed

+2108
-0
lines changed

21 files changed

+2108
-0
lines changed

db/schema/config.xml

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE table PUBLIC "-//opensips.org//DTD DBSchema V1.1//EN"
3+
"https://opensips.org/pub/opensips/dbschema/dtd/1.1/dbschema.dtd" [
4+
5+
<!ENTITY % entities SYSTEM "entities.xml">
6+
%entities;
7+
8+
]>
9+
10+
<table id="config" xmlns:db="http://docbook.org/ns/docbook">
11+
<name>config</name>
12+
<version>1</version>
13+
<type db="mysql">&MYSQL_TABLE_TYPE;</type>
14+
<description>
15+
<db:para>This table is used to store configuration values used by opensips.
16+
More information can be found at: &OPENSIPS_MOD_DOC;config.html.
17+
</db:para>
18+
</description>
19+
20+
<column id="id">
21+
<name>id</name>
22+
<type>unsigned int</type>
23+
<size>&table_id_len;</size>
24+
<autoincrement/>
25+
<natural/>
26+
<primary/>
27+
<type db="dbtext">int,auto</type>
28+
<description>Unique ID</description>
29+
</column>
30+
31+
<column id="name">
32+
<name>name</name>
33+
<type>string</type>
34+
<size>&description_len;</size>
35+
<description>The name of the configuration parameter.
36+
Arbitrary value. Example: "drain".
37+
</description>
38+
<unique/>
39+
</column>
40+
<column>
41+
<name>value</name>
42+
<type>text</type>
43+
<size>4096</size>
44+
<description>The value of the configuration parameter.
45+
Arbitrary value. Example: "no".
46+
</description>
47+
<default><null/></default>
48+
<null/>
49+
</column>
50+
<column>
51+
<name>description</name>
52+
<type>string</type>
53+
<size>&description_len;</size>
54+
<description>Arbitrary value describing the purpose of the value.
55+
</description>
56+
<default><null/></default>
57+
<null/>
58+
</column>
59+
<index>
60+
<name>name_idx</name>
61+
<colref linkend="name"/>
62+
<unique/>
63+
</index>
64+
</table>

db/schema/opensips-config.xml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!DOCTYPE database PUBLIC "-//opensips.org//DTD DBSchema V1.1//EN"
3+
"https://opensips.org/pub/opensips/dbschema/dtd/1.1/dbschema.dtd" [
4+
5+
<!ENTITY % entities SYSTEM "entities.xml">
6+
%entities;
7+
]>
8+
9+
<database xmlns:xi="http://www.w3.org/2001/XInclude">
10+
<name>CONFIG support</name>
11+
<xi:include href="config.xml"/>
12+
</database>

modules/config/Makefile

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
#
2+
# Config module
3+
#
4+
#
5+
# WARNING: do not run this directly, it should be run by the master Makefile
6+
7+
include ../../Makefile.defs
8+
auto_gen=
9+
NAME=config.so
10+
11+
12+
include ../../Makefile.modules

0 commit comments

Comments
 (0)