Forráskód Böngészése

lib/srdb1/schema: Updated indices for rls_presentity and rls_watchers tables

- The rls_watchers table indices are now correct for DB-only mode
Peter Dunkley 13 éve
szülő
commit
1cdab1b92c
2 módosított fájl, 31 hozzáadás és 4 törlés
  1. 9 0
      lib/srdb1/schema/rls_presentity.xml
  2. 22 4
      lib/srdb1/schema/rls_watchers.xml

+ 9 - 0
lib/srdb1/schema/rls_presentity.xml

@@ -88,9 +88,18 @@
         <unique/>
     </index>
 
+    <index>
+        <name>rlsubs_idx</name>
+        <colref linkend="rlsubs_did"/>
+    </index>
+
     <index>
         <name>updated_idx</name>
         <colref linkend="updated"/>
     </index>
 
+    <index>
+        <name>expires_idx</name>
+        <colref linkend="expires"/>
+    </index>
 </table>

+ 22 - 4
lib/srdb1/schema/rls_watchers.xml

@@ -48,7 +48,7 @@
         <description>To domain</description>
     </column>
 
-    <column>
+    <column id="watcher_username">
         <name>watcher_username</name>
         <type>string</type>
         <size>&user_len;</size>
@@ -56,7 +56,7 @@
         <natural/>
     </column>
 
-    <column>
+    <column id="watcher_domain">
         <name>watcher_domain</name>
         <type>string</type>
         <size>&domain_len;</size>
@@ -64,7 +64,7 @@
         <natural/>
     </column>
 
-    <column>
+    <column id="event">
         <name>event</name>
         <type>string</type>
         <size>&user_len;</size>
@@ -129,7 +129,7 @@
         <description>Record route</description>
     </column>
 
-    <column>
+    <column id="expires">
         <name>expires</name>
         <type>int</type>
         <size>&expires_len;</size>
@@ -181,4 +181,22 @@
         <unique/>
     </index>
 
+    <index>
+        <name>rls_watchers_delete</name>
+        <colref linkend="callid"/>
+        <colref linkend="to_tag"/>
+    </index>
+
+    <index>
+        <name>rls_watchers_update</name>
+        <colref linkend="watcher_username"/>
+        <colref linkend="watcher_domain"/>
+        <colref linkend="event"/>
+    </index>
+
+    <index>
+        <name>rls_watchers_expires</name>
+        <colref linkend="expires"/>
+    </index>
+
 </table>