Patches item #1707527, was opened at 2007-04-25 16:01 Message generated for change (Comment added) made by henningw You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=743022&aid=1707527&group_id=139143
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: tools Group: ver devel Status: Open Resolution: None Priority: 5 Private: No Submitted By: Ovidiu Sas (osas) Assigned to: Nobody/Anonymous (nobody) Summary: add dbtext support via openserctl Initial Comment: Hi, This patch integrates dbtext support into the openserctl script: - openserctl.patch - patch for openserctl script - openserctl.dbtext - new file to be installed This aims to add proper support for dbtext out of the box and hopefully better maintenance for dbtext. Todo: fix the Makefile to properly install the new openserctl.dbtext file (not included in the patch) ---------------------------------------------------------------------- >Comment By: Henning Westerholt (henningw) Date: 2007-10-05 15:42 Message: Logged In: YES user_id=337916 Originator: NO Updated patch committed in revision 2875. Thank you! Ovidiu, could you perhaps add a short note about the features that are still missing? Or should we close this entry, and open a new bug/ patch? Henning ---------------------------------------------------------------------- Comment By: Ovidiu Sas (osas) Date: 2007-10-04 14:52 Message: Logged In: YES user_id=1395524 Originator: YES Hi Henning, Here's an updated patch that will fix the $date_now issue and it will provide a default " " for first_name and last_name. Regards, Ovidiu File Added: dbtext.patch.gz ---------------------------------------------------------------------- Comment By: Henning Westerholt (henningw) Date: 2007-10-04 09:12 Message: Logged In: YES user_id=337916 Originator: NO Hello Ovidu, thank you for the update. Why do you need the NULL? There are default values defined for this columns, you could use them. Well, the problem with this modul is that to apparently to few people using this, and there are some limitation in the module as well, e.g. the DB_STRING issue.. Cheers, Henning ---------------------------------------------------------------------- Comment By: Ovidiu Sas (osas) Date: 2007-10-01 20:33 Message: Logged In: YES user_id=1395524 Originator: YES Hmmm ... date_now doesn't seem to be initialized anywhere ... # cd scripts # grep date_now * openserctl: line="$get_next_id_next_id:$OSERUSER:$OSERDOMAIN:$1:$date_now" openserctl: line="$get_next_id_next_id:$1:$date_now" openserctl: #line="$HA1:$OSERUSER:$OSERDOMAIN:$2::::$3:$date_now:$date_now::o:::$HA1:$HA1B:0::::" openserctl: line="$get_next_id_next_id:$OSERUSER:$OSERDOMAIN:$2:::$3:$date_now:$HA1:$HA1B:0:" openserctl: line="$get_next_id_next_id:$OSERUSER:$OSERDOMAIN:$OSERUSER:$date_now" openserctl: line2_update="$line1_keep1:$2:$line1_keep2:$date_now:$HA1:$HA1B:$line1_keep3" ---------------------------------------------------------------------- Comment By: Ovidiu Sas (osas) Date: 2007-10-01 20:25 Message: Logged In: YES user_id=1395524 Originator: YES Hi Henning, Just got back from AstriCon and started to poke around dbtext ... There are several issues with the dbtext: 1. subscriber table was heavily modified. I did some updates into teh openserctl script but it is still not working properly. Please allow null values for dbtext for first_name(str) last_name(str) and datetime_created(int) => first_name(str,null) last_name(str,null) datetime_created(int,null) 2. I will post a patch that will fix some files and fix the id field. 3. lcr will not load the dbtext because it will check for DB_STRING I used the following patch to circumvent this issue: Index: modules/lcr/lcr_mod.c =================================================================== --- modules/lcr/lcr_mod.c (revision 2836) +++ modules/lcr/lcr_mod.c (working copy) @@ -794,7 +794,8 @@ for (i = 0; i < RES_ROW_N(res); i++) { row = RES_ROWS(res) + i; - if (!((VAL_TYPE(ROW_VALUES(row)) == DB_STRING) && + //if (!((VAL_TYPE(ROW_VALUES(row)) == DB_STRING) && + if (!( !VAL_NULL(ROW_VALUES(row)) && inet_aton((char *)VAL_STRING(ROW_VALUES(row)), &ip_addr) != 0)) { LM_ERR("Invalid IP address of gw <%s>\n", proper DB_STRING support shall be added for dbtext. 4. lcr reload is still busted (there is a bug opened about this) And I'm pretty sure that there are lots of other issues waiting to be discovered. dbtext will require a lot of testing. I'm afraid that dbtext will end up like the pa module ... since nobody seems to care (given how busted it is right now). Regards, Ovidiu Sas File Added: dbtext.patch.gz ---------------------------------------------------------------------- Comment By: Henning Westerholt (henningw) Date: 2007-09-27 07:49 Message: Logged In: YES user_id=337916 Originator: NO Hello Ovidu, have you found some time to look at openserctl stuff for dbtext? The "int, auto" problem is still not solved, i think. The current openserctl will be not work for 1.3. Cheers, Henning ---------------------------------------------------------------------- Comment By: Ovidiu Sas (osas) Date: 2007-07-13 21:57 Message: Logged In: YES user_id=1395524 Originator: YES Hi Henning, Tested ok. The only remaining issue is the id(int,auto). Regards, Ovidiu ---------------------------------------------------------------------- Comment By: Henning Westerholt (henningw) Date: 2007-07-13 14:31 Message: Logged In: YES user_id=337916 Originator: NO Hi Ovidiu, the problems you mentioned in the comment from "2007-07-12 17:50" should be fixed. Perhaps you can give it another try. Regards, Henning ---------------------------------------------------------------------- Comment By: Ovidiu Sas (osas) Date: 2007-07-12 18:42 Message: Logged In: YES user_id=1395524 Originator: YES Hi Henning, Another thing that I noticed is that lots of tables are having the id(int,auto) field, but the openserctl script is not populating this script for DBTEXT. Regards, Ovidiu Sas ---------------------------------------------------------------------- Comment By: Ovidiu Sas (osas) Date: 2007-07-12 17:50 Message: Logged In: YES user_id=1395524 Originator: YES Hi Henning It seems that DBTEXT_PATH is ignored by openserdbctl when the dbtext database is created. Also, DBTEXT should be listed as a valid token inside the openserctlrc, along with the DBTEXT_PATH variable. Regards, Ovidiu Sas ---------------------------------------------------------------------- Comment By: Henning Westerholt (henningw) Date: 2007-07-10 11:27 Message: Logged In: YES user_id=337916 Originator: NO Hello Ovidiu, i've finished the integration of your patch. I've made a few small changes to some user output messages, and removed the dbtext creation function, as this should be handled from the openserdbctl script. Furthermore i have tried to use the common definitions from openserctl.base as much as possible. I've made some basic tests, but it would be nice if you could test the dbtext part a little bit more extensive. Thank you, Henning ---------------------------------------------------------------------- Comment By: Ovidiu Sas (osas) Date: 2007-07-05 13:10 Message: Logged In: YES user_id=1395524 Originator: YES Hi Henning, Yes, dbtext has this limitation. Pls. check with miconda about patch 1671120: https://sourceforge.net/tracker/index.php?func=detail&aid=1671120&group_id=139143&atid=743022 When this patch will be implemented, dbtext will perform properly. I would say that for now, print a warning from the script with a reference to patch 1671120. Regards, Ovidiu Sas ---------------------------------------------------------------------- Comment By: Henning Westerholt (henningw) Date: 2007-07-05 08:52 Message: Logged In: YES user_id=337916 Originator: NO Hello Ovidiu, i've some questions regarding your patch for openserctl: In the domain() part, you output the message "..trying to force OpenSER to reload it" but the necessary fifo_cmd domain_reload is not implemented. Should i remove this part of user information? Or perhaps we can use the same approach like the other engines in this part, output msg: "..use domain reload.."? Does the command "$CTLCMD domain_reload" work for dbtext? The same issue exist in the lcr() part of the patch. What do you think? Henning ---------------------------------------------------------------------- Comment By: Ovidiu Sas (osas) Date: 2007-05-24 14:48 Message: Logged In: YES user_id=1395524 Originator: YES Hi Henning, Please use the patch to update the openserctl. I forgot that I updated the openserctl in the pactch. ---------------------------------------------------------------------- Comment By: Henning Westerholt (henningw) Date: 2007-05-24 08:30 Message: Logged In: YES user_id=337916 Originator: NO Hello Osas, i have not looked into this database openserctl specific stuff yet, i think i can use at least parts of your patch. Perhaps Bogdan confuses this patch with your previous tracker entry "sc.dbtext is not up to date for location/alias", this is allready fixed by the new schema generation stuff. Henning ---------------------------------------------------------------------- Comment By: Ovidiu Sas (osas) Date: 2007-05-23 18:11 Message: Logged In: YES user_id=1395524 Originator: YES This patch is no longer needed (in light of Henning Westerholt effort to integrate all databases under the xml schema) ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=743022&aid=1707527&group_id=139143 _______________________________________________ Devel mailing list Devel@openser.org http://openser.org/cgi-bin/mailman/listinfo/devel