Selective Data Structure Operations for Graph Path Queries

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Path queries in distributed graph databases are computationally expensive due to the need for creating multiple interrelated tables and enforcing path consistency rules, which increases processing time and resource usage.

Innovation Solution

The solution involves selectively omitting or deferring certain operations on the in-memory data structure, such as path consistency checking and table creation, based on conditions like single row variables and non-selective operations, to streamline query execution and reduce overhead.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If path consistency checking and table creation operations are performed for all path queries, then query result correctness is ensured, but processing time and computational resources increase significantly

Engineering Contradiction:
Improvequery result correctnessVSAvoidquery processing speed
Core Design Contradiction:
ReliabilityVSProductivity

Solution Approach 1:

The patent changes the operational parameters of the query execution system by introducing selective operation modes. Based on query characteristics (such as whether the query is a path query or non-path query), the system dynamically adjusts which operations are performed (full path consistency checking vs. simplified execution). This parameter-based adaptation allows the system to maintain correctness for queries that need it while skipping unnecessary operations for queries that don't require full consistency checking, thereby resolving the contradiction between reliability and productivity.

Inventive Principle:
Principle #35Parameter changes

Solution Approach 2:

The patent applies partial action by performing only the necessary subset of operations for each query type. For path queries, full path consistency checking is performed; for non-path queries, the checking is omitted or deferred. This selective application of operations ensures that the system performs exactly the right amount of work needed for each query type, avoiding the excessive action of always performing full consistency checking on all queries, thus improving processing speed while maintaining correctness where required.

Inventive Principle:
Principle #16Partial or excessive action

2Reliability

If multiple interrelated tables are created in memory for path query evaluation, then comprehensive query results are obtained, but memory usage and computational overhead increase

Engineering Contradiction:
Improvequery result completenessVSAvoidmemory resources
Core Design Contradiction:
ReliabilityVSQuantity of substance

Solution Approach 1:

The system dynamically changes the memory allocation parameter based on query type. For path queries, the system allocates memory for multiple interrelated tables to ensure complete query results. For non-path queries, the system reduces memory allocation by omitting table creation. This parameter-based memory management allows the system to maintain result completeness for queries that need it while reducing memory consumption for queries that don't require extensive memory resources.

Inventive Principle:
Principle #35Parameter changes

Solution Approach 2:

The patent applies partial action by creating only the necessary tables in memory for each query type. For path queries, full table creation is performed to ensure comprehensive results. For non-path queries, table creation is omitted or deferred, using only the minimal memory structures needed. This selective table creation ensures result completeness where required while minimizing memory resource consumption where full table creation is unnecessary.

Inventive Principle:
Principle #16Partial or excessive action

3Reliability

If path consistency rules are enforced during query execution, then data integrity is maintained, but query execution time increases

Engineering Contradiction:
Improvedata integrityVSAvoidquery execution time
Core Design Contradiction:
ReliabilityVSLoss of time

Solution Approach 1:

The patent changes the execution parameter of path consistency enforcement based on query characteristics. For path queries, the system enables path consistency checking to maintain data integrity. For non-path queries, the system disables or defers path consistency checking, allowing faster execution. This conditional parameter adjustment resolves the contradiction by ensuring data integrity only when necessary, thereby reducing unnecessary execution time overhead.

Inventive Principle:
Principle #35Parameter changes

Solution Approach 2:

The patent applies partial action by performing path consistency checking only for queries that require it (path queries) and omitting it for queries that don't need full consistency verification (non-path queries). This selective enforcement of path consistency rules maintains data integrity for critical queries while avoiding the time penalty of enforcing consistency rules on all queries, thus resolving the contradiction between data integrity and execution time.

Inventive Principle:
Principle #16Partial or excessive action

Data Source

PatentUS11704309B2Selective use of data structure operations for path query evaluation
Publication Date: 2023.07.18 MICROSOFT TECHNOLOGY LICENSING LLC
  • US11704309B2 patent drawing
  • US11704309B2 patent drawing
  • US11704309B2 patent drawing

AI summary

The disclosed technologies are capable of selectively using data structure operations for path query evaluation. One technique involves reading a query that traverses at least two nodes and at least one edge of a graph in a graph database; compiling the query into a set of variables and a set of constraints, where the set of variables and the set of constraints correspond to the two nodes and the one edge of the graph; creating an in-memory data structure that comprises a table; using the set of variables and the set of constraints to determine an operation that is performable using the in-memory data structure; checking for an existence of a condition relating to the in-memory data structure or the operation; skipping the operation if the condition exists or executing the operation if the condition does not exist; and storing a set of intermediate query results in the table.