[sr-dev] git:lazedo/kazoo: proposed change for dbtext query results.

Daniel-Constantin Mierla miconda at gmail.com
Sat Sep 13 10:25:57 CEST 2014


I commented on the issue you thought it get solved by this patch on the 
other email sent to sr-dev.

Some remarks about this patch.

First, regarding the commit message -- it should strictly summarize what 
are the changes done.

If it is a proposed change, then don't write that in the commit message, 
you send and email to sr-dev with the link to commit to say it is a 
proposed change and discuss it.

We have quite clean and technical commit messages history and want it to 
keep it so, because it is easier to review later.

Then, for clarification, regarding your:

"if it takes more then 6 secs to complete, the next run will override the
results internal structure pointer maintained in the connection level."


This cannot happen, because the query is in the same process, so if it 
takes more than 6 seconds to execute, the next query is not executed 
before because the process itself is still at the current query. The 
next query will be executed with delay, after the current one is finished.

Cheers,
Daniel

On 10/09/14 16:24, Luis Azedo wrote:
> Module: sip-router
> Branch: lazedo/kazoo
> Commit: dae74e974a028082a3250805da83223220123c10
> URL:    http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=dae74e974a028082a3250805da83223220123c10
>
> Author: Luis Azedo <luis at 2600hz.com>
> Committer: Luis Azedo <luis at 2600hz.com>
> Date:   Wed Sep 10 15:23:45 2014 +0100
>
> proposed change for dbtext query results.
> this behaviour was observed by interacting with module presence.
>
> presentity clean runs from timer every 6 secs.
> if the first run returns a large set of rows, it iterates all rows doing
> some notifications and deleting the presentity.
> if it takes more then 6 secs to complete, the next run will override the
> results internal structure pointer maintained in the connection level.
>
> the proposed patch, maintains the query result internal structure within
> the result, using the ptr field for that.
>
> ---
>
>   modules/db_text/dbt_api.c  |   86 ++++++++++++++++++++-----------------------
>   modules/db_text/dbt_api.h  |    3 +-
>   modules/db_text/dbt_base.c |   27 +++++++-------
>   modules/db_text/dbt_res.c  |    4 ++-
>   modules/db_text/dbt_res.h  |    6 ---
>   5 files changed, 59 insertions(+), 67 deletions(-)
>
> Diff:   http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commitdiff;h=dae74e974a028082a3250805da83223220123c10
>
> _______________________________________________
> sr-dev mailing list
> sr-dev at lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev

-- 
Daniel-Constantin Mierla
http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
Next Kamailio Advanced Trainings 2014 - http://www.asipto.com
Sep 22-25, Berlin, Germany




More information about the sr-dev mailing list