US2016070759A1PendingUtilityA1

System And Method For Integrating Real-Time Query Engine And Database Platform

Assignee: PALO ALTO RES CT INCPriority: Sep 4, 2014Filed: Sep 4, 2014Published: Mar 10, 2016
Est. expirySep 4, 2034(~8.1 yrs left)· nominal 20-yr term from priority
Inventors:Eric Huang
G06F 17/30324G06F 17/30516G06F 16/24568G06F 16/9024G06F 16/258G06F 16/2458G06F 16/24532
46
PatentIndex Score
0
Cited by
0
References
0
Claims

Abstract

Real-time responsiveness to queries regarding data in a relational database can be improved by performing in parallel continuous construction of a graph model of the data and answering the queries based on the graph model. Two processing threads are ran in parallel. The main thread receives user queries regarding data in a database and answers the queries based on a graph data structure stored as a graph model of the data. The main thread also starts a graph update thread, which continuously updates the graph model by requesting a server managing the database to build a description of a graph representative of the data, receiving the description, and storing the description in an initialized graph data structure. The graph data structure previously stored as the graph model is swapped for a more recently completed data structure that represents the data at a later point of time.

Claims

exact text as granted — not AI-modified
What is claimed is: 
     
         1 . A system for integrating real-time query engine and database platform, comprising:
 a memory configured to store a graph data structure and a graph model comprising another graph data structure;   one or more servers connected to the memory and configured to execute code, comprising:
 a query engine configured to process queries regarding data in a database, the query engine comprising:
 an input module configured to receive an input stream comprising one or more of the queries; and 
 an answering module configured to answer the one or more queries based on the graph model; and 
 
 a graph update engine configured to continuously update the graph data structure and the graph model while the query stream remains open, comprising:
 an initialization module configured to initialize the graph data structure; 
 a request module configured to request a description of a graph representative of the data from at least one server managing the database, to receive the description from the at least one server, and to store the description in the initialized graph data structure; and 
 a swap module to swap the data structure with the stored description and the another graph data structure comprised in the graph model, wherein the graph model comprises the graph data structure with the stored description after the swap. 
 
   
     
     
         2 . A system according to  claim 1 , further comprising:
 a signal module configured to receive a signal that the swap has occurred,   wherein the answering module begins answering the queries upon the signal being received.   
     
     
         3 . A system according to  claim 2 , further comprising:
 a preprocessing module configured to preprocess the graph model after each time the swap occurs;   an identifier module configured to associate an identifier with the graph data structure after each time the graph data structure is initialized; and   a recording module configured to record the identifier associated with the graph data structure comprised in the graph model each time the graph model is preprocessed.   
     
     
         4 . A system according to  claim 3 , further comprising:
 a checking module configured to check whether the graph data structure comprised in the graph model has been preprocessed, comprising:
 a read module configured to read the identifier of the one data structure comprised in the graph model; 
 a comparison module configured to compare the read identifier to the recorded identifiers; and 
 a determination module configured to determine whether the graph data structure comprised within the graph model has been preprocessed based on the comparison. 
   
     
     
         5 . A system according to  claim 1 , further comprising:
 a locking module comprised in the graph update engine configured to lock a mutex on the graph model upon storing the description in the graph data structure; and   an unlocking module comprised in the graph update engine configured to unlock the mutex after the swap is performed,   wherein answering the queries by the query engine is paused while the mutex is locked by the locking module.   
     
     
         6 . A system according to  claim 5 , comprising at least one of:
 a query locking module comprised in the query engine configured to lock the mutex on the graph model prior to answering the queries; and   a query unlocking module comprised in the graph engine configured to unlock the mutex upon answering a predefined number of the queries,   wherein the swapping by the graph update engine is paused while the mutex is locked by the query engine.   
     
     
         7 . A system according to  claim 6 , further comprising:
 an extraction module configured to extract the queries from the input stream; and   a combining module configured to combine the extracted queries into one or more batches,   wherein the predefined number equals the number of the queries in one of the batches.   
     
     
         8 . A system according to  claim 1 , wherein the swap is a pointer-based swap. 
     
     
         9 . A system according to  claim 1 , wherein the description is received from the at least one server over a network. 
     
     
         10 . A system according to  claim 1 , further comprising:
 a deallocation module configured to deallocate the graph data structure after the swap and the graph model after the input stream is closed.   
     
     
         11 . A method for integrating real-time query engine and database platform, comprising:
 maintaining in a memory a graph data structure and a graph model comprising another graph data structure;   processing queries regarding data in a database by a query engine comprised in one or more servers connected to the memory, comprising:
 receiving an input stream comprising one or more of the queries; and 
 answering the one or more queries based on the graph model; and 
   continuously updating the graph data structure and the graph model while the query stream remains open by a graph update engine comprised in the one or more servers, comprising:
 initializing the graph data structure; 
 requesting a description of a graph representative of the data from at least one server managing the database, receiving the description from the at least one server, and storing the description in the initialized graph data structure; and 
 swapping the data structure with the stored description and the another graph data structure comprised in the graph model, wherein the graph model comprises the graph data structure with the stored description after the swap. 
   
     
     
         12 . A method according to  claim 11 , further comprising:
 receiving a signal that the swap has occurred,   wherein the queries are answered upon the signal being received.   
     
     
         13 . A method according to  claim 12 , further comprising:
 preprocessing the graph model after each time the swap occurs;   associating an identifier with the graph data structure after each time the graph data structure is initialized; and   recording the identifier associated with the graph data structure comprised in the graph model each time the graph model is preprocessed.   
     
     
         14 . A method according to  claim 13 , further comprising:
 checking whether the graph data structure comprised in the graph model has been preprocessed, comprising:
 reading the identifier of the one data structure comprised in the graph model; 
 comparing the read identifier to the recorded identifiers; and 
 determining whether the graph data structure comprised in the graph model has been preprocessed based on the comparison. 
   
     
     
         15 . A method according to  claim 11 , further comprising:
 locking a mutex on the graph model by the graph update engine upon storing the description in the graph data structure; and   unlocking the mutex by the graph update engine after the swap is performed,   wherein answering the queries by the query engine is paused while the mutex is locked by the graph update engine.   
     
     
         16 . A method according to  claim 15 , comprising at least one of:
 locking the mutex on the graph model by the query engine prior to answering the queries; and   unlocking the mutex upon answering a predefined number of the queries,   wherein the swapping by the graph update engine is paused while the mutex is locked by the query engine.   
     
     
         17 . A method according to  claim 16 , further comprising:
 extracting the queries from the input stream; and   combining the extracted queries into one or more batches,   wherein the predefined number equals the number of the queries in one of the batches.   
     
     
         18 . A method according to  claim 11 , wherein the swap is a pointer-based swap. 
     
     
         19 . A method according to  claim 11 , wherein the description is received from the at least one server over a network. 
     
     
         20 . A method according to  claim 11 , further comprising:
 deallocating the graph data structure after the swap; and   deallocating the graph model after the input stream is closed.

Join the waitlist — get patent alerts

Track US2016070759A1 — get alerts on status changes and closely related new filings.

We store only your email — no account needed. See our privacy policy.