[Asterisk-code-review] astdb: Improve prefix searches in astdb (asterisk[13])

Sean Bright asteriskteam at digium.com
Fri Dec 8 14:54:17 CST 2017


Hello Jenkins2, Corey Farrell, 

I'd like you to reexamine a change. Please visit

    https://gerrit.asterisk.org/7475

to look at the new patch set (#4).

Change subject: astdb: Improve prefix searches in astdb
......................................................................

astdb: Improve prefix searches in astdb

Using the LIKE operator requires a full table scan of 'astdb', whereas a
comparison operation is able to use the primary key index.

This patch adds a new function to the AstDB API for quick prefix matches
and updates res_sorcery_astdb to utilize it. This showed substantial
performance improvement in my test environment.

Related to ASTERISK~26806, but does not completely resolve it.

Change-Id: I7d37f9ba2aea139dabf2ca72d31fbe34bd9b2fa1
---
M include/asterisk/astdb.h
M main/db.c
M res/res_sorcery_astdb.c
3 files changed, 102 insertions(+), 30 deletions(-)


  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/75/7475/4
-- 
To view, visit https://gerrit.asterisk.org/7475
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: 13
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I7d37f9ba2aea139dabf2ca72d31fbe34bd9b2fa1
Gerrit-Change-Number: 7475
Gerrit-PatchSet: 4
Gerrit-Owner: Sean Bright <sean.bright at gmail.com>
Gerrit-Reviewer: Corey Farrell <git at cfware.com>
Gerrit-Reviewer: Jenkins2
Gerrit-Reviewer: Sean Bright <sean.bright at gmail.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20171208/bdf8344c/attachment.html>


More information about the asterisk-code-review mailing list