Module: sip-router
Branch: janakj/flatstore
Commit: 5269c8d891516498d10ea630ad872bb5d306cf60
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=5269c8d…
Author: Henning Westerholt <henning.westerholt(a)1und1.de>
Committer: Henning Westerholt <henning.westerholt(a)1und1.de>
Date: Wed Feb 27 13:53:33 2008 +0000
- first round of cleanups for documentation
- remove all FAQ and DEVEL files considered empty in content (no content at all
or just the default lines)
- remove of the <RevHistory>/</RevHistory> tag (and of course anything between
them)
- remove the comments at the end of the file that begins with
"<!-- Keep this element at the end of the file"
- credits for the patch/ the change scripts goes to Edson Gellert Schubert,
4lists at gmail dot com
git-svn-id: https://openser.svn.sourceforge.net/svnroot/openser/trunk@3769 689a6050-402a-0410-94f2-e92a70836424
---
.../db_flatstore/km_doc/db_flatstore_devel.sgml | 11 ---
modules/db_flatstore/km_doc/db_flatstore_faq.sgml | 70 --------------------
modules/db_flatstore/km_doc/db_flatstore_user.sgml | 11 ---
3 files changed, 0 insertions(+), 92 deletions(-)
diff --git a/modules/db_flatstore/km_doc/db_flatstore_devel.sgml b/modules/db_flatstore/km_doc/db_flatstore_devel.sgml
index f1afc53..cf299a2 100644
--- a/modules/db_flatstore/km_doc/db_flatstore_devel.sgml
+++ b/modules/db_flatstore/km_doc/db_flatstore_devel.sgml
@@ -2,12 +2,6 @@
<chapter>
<chapterinfo>
- <revhistory>
- <revision>
- <revnumber>$Revision$</revnumber>
- <date>$Date$</date>
- </revision>
- </revhistory>
</chapterinfo>
<title>Developer's Guide</title>
<para>
@@ -15,8 +9,3 @@
</para>
</chapter>
-<!-- Keep this element at the end of the file
-Local Variables:
-sgml-parent-document: ("db_flatstore.sgml" "book" "chapter")
-End:
--->
diff --git a/modules/db_flatstore/km_doc/db_flatstore_faq.sgml b/modules/db_flatstore/km_doc/db_flatstore_faq.sgml
deleted file mode 100644
index bc8e5b9..0000000
--- a/modules/db_flatstore/km_doc/db_flatstore_faq.sgml
+++ /dev/null
@@ -1,70 +0,0 @@
-<!-- Module FAQ -->
-
-<chapter>
- <chapterinfo>
- <revhistory>
- <revision>
- <revnumber>$Revision$</revnumber>
- <date>$Date$</date>
- </revision>
- </revhistory>
- </chapterinfo>
- <title>Frequently Asked Questions</title>
- <qandaset defaultlabel="number">
- <qandaentry>
- <question>
- <para>Where can I find more about OpenSER?</para>
- </question>
- <answer>
- <para>
- Take a look at &serhomelink;.
- </para>
- </answer>
- </qandaentry>
- <qandaentry>
- <question>
- <para>Where can I post a question about this module?</para>
- </question>
- <answer>
- <para>
- First at all check if your question was already answered on one of
- our mailing lists:
- </para>
- <itemizedlist>
- <listitem>
- <para>User Mailing List - &seruserslink;</para>
- </listitem>
- <listitem>
- <para>Developer Mailing List - &serdevlink;</para>
- </listitem>
- </itemizedlist>
- <para>
- E-mails regarding any stable &ser; release should be sent to
- &serusersmail; and e-mails regarding development versions
- should be sent to &serdevmail;.
- </para>
- <para>
- If you want to keep the mail private, send it to
- &serhelpmail;.
- </para>
- </answer>
- </qandaentry>
- <qandaentry>
- <question>
- <para>How can I report a bug?</para>
- </question>
- <answer>
- <para>
- Please follow the guidelines provided at:
- &serbugslink;.
- </para>
- </answer>
- </qandaentry>
- </qandaset>
-</chapter>
-
-<!-- Keep this element at the end of the file
-Local Variables:
-sgml-parent-document: ("db_flatstore.sgml" "Book" "chapter")
-End:
--->
diff --git a/modules/db_flatstore/km_doc/db_flatstore_user.sgml b/modules/db_flatstore/km_doc/db_flatstore_user.sgml
index 6043f35..a72a07a 100644
--- a/modules/db_flatstore/km_doc/db_flatstore_user.sgml
+++ b/modules/db_flatstore/km_doc/db_flatstore_user.sgml
@@ -2,12 +2,6 @@
<chapter>
<chapterinfo>
- <revhistory>
- <revision>
- <revnumber>$Revision$</revnumber>
- <date>$Date$</date>
- </revision>
- </revhistory>
</chapterinfo>
<title>User's Guide</title>
@@ -199,8 +193,3 @@ modparam("db_flatstore", "flush", 0)
</section>
</chapter>
-<!-- Keep this element at the end of the file
-Local Variables:
-sgml-parent-document: ("db_flatstore.sgml" "Book" "chapter")
-End:
--->
Module: sip-router
Branch: janakj/flatstore
Commit: bbf39b7f2fe6e73373d08b24359ed617bc4852cf
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=bbf39b7…
Author: Henning Westerholt <henning.westerholt(a)1und1.de>
Committer: Henning Westerholt <henning.westerholt(a)1und1.de>
Date: Tue Mar 4 13:15:47 2008 +0000
- change module docs FAQ link to a common one in the doc dir
- remove module specific FAQ content from the file in doc, this way no FAQ
content will be created
- credits for the patch/ the change scripts goes to Edson Gellert Schubert,
4lists at gmail dot com
- update all READMEs, for most module docs the FAQ and devel information were
now removed
git-svn-id: https://openser.svn.sourceforge.net/svnroot/openser/trunk@3839 689a6050-402a-0410-94f2-e92a70836424
---
modules/db_flatstore/km_README | 34 --------------------
modules/db_flatstore/km_doc/db_flatstore.sgml | 2 +-
.../db_flatstore/km_doc/db_flatstore_devel.sgml | 3 +-
modules/db_flatstore/km_doc/db_flatstore_user.sgml | 3 +-
4 files changed, 3 insertions(+), 39 deletions(-)
diff --git a/modules/db_flatstore/km_README b/modules/db_flatstore/km_README
index c8e11b3..b319acb 100644
--- a/modules/db_flatstore/km_README
+++ b/modules/db_flatstore/km_README
@@ -33,7 +33,6 @@ Jan Janak
1.5.1. flat_rotate
2. Developer's Guide
- 3. Frequently Asked Questions
List of Examples
1-1. Set "flush" parameter
@@ -173,36 +172,3 @@ modparam("db_flatstore", "flush", 0)
Chapter 2. Developer's Guide
The module implements the DB API.
- __________________________________________________________
-
-Chapter 3. Frequently Asked Questions
-
- 3.1. Where can I find more about OpenSER?
- 3.2. Where can I post a question about this module?
- 3.3. How can I report a bug?
-
- 3.1. Where can I find more about OpenSER?
-
- Take a look at http://openser.org/.
-
- 3.2. Where can I post a question about this module?
-
- First at all check if your question was already answered on one
- of our mailing lists:
-
- * User Mailing List -
- http://openser.org/cgi-bin/mailman/listinfo/users
- * Developer Mailing List -
- http://openser.org/cgi-bin/mailman/listinfo/devel
-
- E-mails regarding any stable OpenSER release should be sent to
- <users(a)openser.org> and e-mails regarding development versions
- should be sent to <devel(a)openser.org>.
-
- If you want to keep the mail private, send it to
- <team(a)openser.org>.
-
- 3.3. How can I report a bug?
-
- Please follow the guidelines provided at:
- http://sourceforge.net/tracker/?group_id=139143.
diff --git a/modules/db_flatstore/km_doc/db_flatstore.sgml b/modules/db_flatstore/km_doc/db_flatstore.sgml
index ba6c6b7..7ab9128 100644
--- a/modules/db_flatstore/km_doc/db_flatstore.sgml
+++ b/modules/db_flatstore/km_doc/db_flatstore.sgml
@@ -3,7 +3,7 @@
<!ENTITY user SYSTEM "db_flatstore_user.sgml">
<!ENTITY devel SYSTEM "db_flatstore_devel.sgml">
-<!ENTITY faq SYSTEM "db_flatstore_faq.sgml">
+<!ENTITY faq SYSTEM "../../../doc/module_faq.sgml">
<!-- Include general documentation entities -->
<!ENTITY % docentities SYSTEM "../../../doc/entities.sgml">
diff --git a/modules/db_flatstore/km_doc/db_flatstore_devel.sgml b/modules/db_flatstore/km_doc/db_flatstore_devel.sgml
index cf299a2..201da09 100644
--- a/modules/db_flatstore/km_doc/db_flatstore_devel.sgml
+++ b/modules/db_flatstore/km_doc/db_flatstore_devel.sgml
@@ -1,8 +1,7 @@
<!-- Module Developer's Guide -->
<chapter>
- <chapterinfo>
- </chapterinfo>
+
<title>Developer's Guide</title>
<para>
The module implements the DB <acronym>API</acronym>.
diff --git a/modules/db_flatstore/km_doc/db_flatstore_user.sgml b/modules/db_flatstore/km_doc/db_flatstore_user.sgml
index a72a07a..60d872e 100644
--- a/modules/db_flatstore/km_doc/db_flatstore_user.sgml
+++ b/modules/db_flatstore/km_doc/db_flatstore_user.sgml
@@ -1,8 +1,7 @@
<!-- Module User's Guide -->
<chapter>
- <chapterinfo>
- </chapterinfo>
+
<title>User's Guide</title>
<section>
Module: sip-router
Branch: janakj/flatstore
Commit: 6ad96b39d4d9fc6bf82b2c5532b330db0730a6d4
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=6ad96b3…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: Fri Mar 7 18:19:45 2008 +0000
- modules documentation migrated from sgml to xml docbook format
- many thanks to Edson <4lists (at) gmail (dot) com> for providing script to replace headers and rename files
- contact updated
- follows re-sync with todays changes and update of Makefile to generate README and html files from XML
git-svn-id: https://openser.svn.sourceforge.net/svnroot/openser/trunk@3886 689a6050-402a-0410-94f2-e92a70836424
---
modules/db_flatstore/km_README | 56 +++++++++++++++-----
.../km_doc/{db_flatstore.sgml => db_flatstore.xml} | 16 +++---
..._flatstore_user.sgml => db_flatstore_admin.xml} | 0
...flatstore_devel.sgml => db_flatstore_devel.xml} | 0
4 files changed, 51 insertions(+), 21 deletions(-)
diff --git a/modules/db_flatstore/km_README b/modules/db_flatstore/km_README
index b319acb..ac28ae6 100644
--- a/modules/db_flatstore/km_README
+++ b/modules/db_flatstore/km_README
@@ -9,9 +9,13 @@ Edited by
Jan Janak
Copyright � 2004, 2005 FhG FOKUS
+ Revision History
+ Revision $Revision$ $Date: 2008-03-04 15:15:47 +0200
+ (Tue, 04 Mar 2008) $
__________________________________________________________
Table of Contents
+
1. User's Guide
1.1. Overview
@@ -33,10 +37,11 @@ Jan Janak
1.5.1. flat_rotate
2. Developer's Guide
+ 3. Frequently Asked Questions
List of Examples
- 1-1. Set "flush" parameter
- __________________________________________________________
+
+ 1.1. Set "flush" parameter
Chapter 1. User's Guide
@@ -86,7 +91,6 @@ modparam("acc", "db_url", "flatstore:/var/log/acc")
the complete data for a table you can simply concatenate the
contents of files with the same table name but different
process id.
- __________________________________________________________
1.1.1. Rotating Log Files
@@ -96,7 +100,6 @@ modparam("acc", "db_url", "flatstore:/var/log/acc")
rotation itself has to be done by another application (such as
logrotate). Follow these steps to rotate files generated by
flatstore module:
-
* Rename the files that you want to rotate:
cd /var/log/acc
mv acc_1.log acc_1.log.20050605
@@ -116,24 +119,19 @@ openserctl fifo flat_rotate
write. It is normal that the files will be not created
immediately if there is no traffic on the proxy server.
* Move the renamed files somewhere else and process them.
- __________________________________________________________
1.2. Dependencies
1.2.1. OpenSER Modules
The following modules must be loaded before this module:
-
* No dependencies on other OpenSER modules.
- __________________________________________________________
1.2.2. External Libraries or Applications
The following libraries or applications must be installed
before running OpenSER with this module loaded:
-
* None.
- __________________________________________________________
1.3. Exported Parameters
@@ -143,20 +141,18 @@ openserctl fifo flat_rotate
Default value is 1.
- Example 1-1. Set "flush" parameter
+ Example 1.1. Set "flush" parameter
...
modparam("db_flatstore", "flush", 0)
...
- __________________________________________________________
1.4. Exported Functions
There are no function exported to routing script.
- __________________________________________________________
1.5. Exported MI Functions
-1.5.1. flat_rotate
+1.5.1. flat_rotate
It changes the name of the files where it is written.
@@ -167,8 +163,40 @@ modparam("db_flatstore", "flush", 0)
MI FIFO Command Format:
:flat_rotate:_reply_fifo_file_
_empty_line_
- __________________________________________________________
Chapter 2. Developer's Guide
The module implements the DB API.
+
+Chapter 3. Frequently Asked Questions
+
+ 3.1.
+
+ Where can I find more about OpenSER?
+
+ Take a look at http://openser.org/.
+
+ 3.2.
+
+ Where can I post a question about this module?
+
+ First at all check if your question was already answered on one
+ of our mailing lists:
+ * User Mailing List -
+ http://openser.org/cgi-bin/mailman/listinfo/users
+ * Developer Mailing List -
+ http://openser.org/cgi-bin/mailman/listinfo/devel
+
+ E-mails regarding any stable OpenSER release should be sent to
+ <users(a)openser.org> and e-mails regarding development versions
+ should be sent to <devel(a)openser.org>.
+
+ If you want to keep the mail private, send it to
+ <team(a)openser.org>.
+
+ 3.3.
+
+ How can I report a bug?
+
+ Please follow the guidelines provided at:
+ http://sourceforge.net/tracker/?group_id=139143.
diff --git a/modules/db_flatstore/km_doc/db_flatstore.sgml b/modules/db_flatstore/km_doc/db_flatstore.xml
similarity index 60%
rename from modules/db_flatstore/km_doc/db_flatstore.sgml
rename to modules/db_flatstore/km_doc/db_flatstore.xml
index 7ab9128..5474aa6 100644
--- a/modules/db_flatstore/km_doc/db_flatstore.sgml
+++ b/modules/db_flatstore/km_doc/db_flatstore.xml
@@ -1,12 +1,14 @@
-<!DOCTYPE Book PUBLIC "-//OASIS//DTD DocBook V4.2//EN" [
+<?xml version="1.0" encoding='ISO-8859-1'?>
+<!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.4//EN"
+"http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd" [
-<!ENTITY user SYSTEM "db_flatstore_user.sgml">
-<!ENTITY devel SYSTEM "db_flatstore_devel.sgml">
-<!ENTITY faq SYSTEM "../../../doc/module_faq.sgml">
+<!ENTITY user SYSTEM "db_flatstore_admin.xml">
+<!ENTITY devel SYSTEM "db_flatstore_devel.xml">
+<!ENTITY faq SYSTEM "../../../doc/module_faq.xml">
<!-- Include general documentation entities -->
-<!ENTITY % docentities SYSTEM "../../../doc/entities.sgml">
+<!ENTITY % docentities SYSTEM "../../../doc/entities.xml">
%docentities;
]>
@@ -39,8 +41,8 @@
</copyright>
<revhistory>
<revision>
- <revnumber>$Revision$</revnumber>
- <date>$Date$</date>
+ <revnumber>$Revision: 3839 $</revnumber>
+ <date>$Date: 2008-03-04 15:15:47 +0200 (Tue, 04 Mar 2008) $</date>
</revision>
</revhistory>
</bookinfo>
diff --git a/modules/db_flatstore/km_doc/db_flatstore_user.sgml b/modules/db_flatstore/km_doc/db_flatstore_admin.xml
similarity index 100%
rename from modules/db_flatstore/km_doc/db_flatstore_user.sgml
rename to modules/db_flatstore/km_doc/db_flatstore_admin.xml
diff --git a/modules/db_flatstore/km_doc/db_flatstore_devel.sgml b/modules/db_flatstore/km_doc/db_flatstore_devel.xml
similarity index 100%
rename from modules/db_flatstore/km_doc/db_flatstore_devel.sgml
rename to modules/db_flatstore/km_doc/db_flatstore_devel.xml
Module: sip-router
Branch: janakj/flatstore
Commit: 9a39980c160d0a992db1562e830f67f64ea70d68
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=9a39980…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: Mon Mar 10 11:17:28 2008 +0000
- content of faq removed (mistakenly added by me after Henning did the cleanup for modules' docs; rev 3839)
git-svn-id: https://openser.svn.sourceforge.net/svnroot/openser/trunk@3901 689a6050-402a-0410-94f2-e92a70836424
---
modules/db_flatstore/km_README | 42 +--------------------------------------
1 files changed, 2 insertions(+), 40 deletions(-)
diff --git a/modules/db_flatstore/km_README b/modules/db_flatstore/km_README
index b211702..4caf37b 100644
--- a/modules/db_flatstore/km_README
+++ b/modules/db_flatstore/km_README
@@ -10,8 +10,8 @@ Jan Janak
Copyright � 2004, 2005 FhG FOKUS
Revision History
- Revision $Revision$ $Date: 2008-03-07 21:52:29 +0200
- (Fri, 07 Mar 2008) $
+ Revision $Revision$ $Date: 2008-03-08 01:03:56 +0200
+ (Sat, 08 Mar 2008) $
__________________________________________________________
Table of Contents
@@ -37,7 +37,6 @@ Jan Janak
1.5.1. flat_rotate
2. Developer's Guide
- 3. Frequently Asked Questions
List of Examples
@@ -167,40 +166,3 @@ modparam("db_flatstore", "flush", 0)
Chapter 2. Developer's Guide
The module implements the DB API.
-
-Chapter 3. Frequently Asked Questions
-
- Revision History
- Revision $Revision$ $Date: 2005-06-13 19:47:24 +0300 (Mon,
- 13 Jun 2005) $
-
- 3.1.
-
- Where can I find more about OpenSER?
-
- Take a look at http://openser.org/.
-
- 3.2.
-
- Where can I post a question about this module?
-
- First at all check if your question was already answered on one
- of our mailing lists:
- * User Mailing List -
- http://openser.org/cgi-bin/mailman/listinfo/users
- * Developer Mailing List -
- http://openser.org/cgi-bin/mailman/listinfo/devel
-
- E-mails regarding any stable OpenSER release should be sent to
- <users(a)openser.org> and e-mails regarding development versions
- should be sent to <devel(a)openser.org>.
-
- If you want to keep the mail private, send it to
- <team(a)openser.org>.
-
- 3.3.
-
- How can I report a bug?
-
- Please follow the guidelines provided at:
- http://sourceforge.net/tracker/?group_id=139143.
Module: sip-router
Branch: janakj/flatstore
Commit: 04f0bfe2b359afaad6f227e41ad1e919debff73e
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=04f0bfe…
Author: Bogdan-Andrei Iancu <bogdan(a)voice-system.ro>
Committer: Bogdan-Andrei Iancu <bogdan(a)voice-system.ro>
Date: Fri Apr 18 09:04:44 2008 +0000
- fixed bug in keeping the dir path for the flatstore files - as the path is a substring of the DB URL, we need to explicitly allocate a str structure for it; otherwise we will randomly write in memory :D
git-svn-id: https://openser.svn.sourceforge.net/svnroot/openser/trunk@4040 689a6050-402a-0410-94f2-e92a70836424
---
modules/db_flatstore/km_flatstore.c | 24 +++++++++++++++---------
1 files changed, 15 insertions(+), 9 deletions(-)
diff --git a/modules/db_flatstore/km_flatstore.c b/modules/db_flatstore/km_flatstore.c
index 714ac3b..89cff26 100644
--- a/modules/db_flatstore/km_flatstore.c
+++ b/modules/db_flatstore/km_flatstore.c
@@ -57,6 +57,7 @@ static int parse_flat_url(const str* url, str* path)
db_con_t* flat_db_init(const str* url)
{
db_con_t* res;
+ str* path;
if (!url || !url->s) {
LM_ERR("invalid parameter value\n");
@@ -68,17 +69,22 @@ db_con_t* flat_db_init(const str* url)
* parameter in the table variable, flat_use_table will then pick that
* value and open the file
*/
- res = pkg_malloc(sizeof(db_con_t) + sizeof(struct flat_con*));
+ /* as the table (path) is a substring of the received str, we need to
+ * allocate a separate str struct for it -bogdan
+ */
+ res = pkg_malloc(sizeof(db_con_t)+sizeof(struct flat_con*)+sizeof(str));
if (!res) {
LM_ERR("no pkg memory left\n");
return 0;
}
- memset(res, 0, sizeof(db_con_t) + sizeof(struct flat_con*));
+ memset(res, 0, sizeof(db_con_t) + sizeof(struct flat_con*) + sizeof(str));
+ path = (str*)(((char*)res) + sizeof(db_con_t) + sizeof(struct flat_con*));
- if (parse_flat_url(url, (str*)res->table) < 0) {
+ if (parse_flat_url(url, path) < 0) {
pkg_free(res);
return 0;
}
+ res->table = path;
return res;
}
@@ -99,16 +105,16 @@ int flat_use_table(db_con_t* h, const str* t)
if (CON_TABLE(h)->s != t->s) {
if (CON_TAIL(h)) {
- /* Decrement the reference count
- * of the connection but do not remove
- * it from the connection pool
- */
+ /* Decrement the reference count
+ * of the connection but do not remove
+ * it from the connection pool
+ */
con = (struct flat_con*)CON_TAIL(h);
con->ref--;
-
}
- CON_TAIL(h) = (unsigned long)flat_get_connection((char*)CON_TABLE(h)->s, (char*)t->s);
+ CON_TAIL(h) = (unsigned long)
+ flat_get_connection((char*)CON_TABLE(h)->s, (char*)t->s);
if (!CON_TAIL(h)) {
return -1;
}