Table of Contents
Fetching ...

MV4PG: Materialized Views for Property Graphs

Chaijun Xu, Xingdi Wei, Yu Zhang, Kaiwei Li, Xiaowei Zhu, Ke Huang, Tao Wang, Shipeng Qi

TL;DR

MV4PG tackles slow query performance in graph databases by introducing materialized views for property graphs with a focus on variable-length edges. It combines three components—view creation, templated view maintenance, and query optimization using views—coupled with a VF2-like view matcher to integrate precomputed patterns into execution plans. The approach is validated on TuGraph and Neo4j with substantial gains: up to $28.71\times$ overall workload speedups and near $100\times$ for some single queries, while keeping maintenance overhead reasonable. The work demonstrates a practical pathway to speed up complex graph workloads and outlines concrete directions for automatic view selection and optimized maintenance strategies.

Abstract

Graph databases are getting more and more attention in the highly interconnected data domain, and the demand for efficient querying of big data is increasing. We noticed that there are duplicate patterns in graph database queries, and the results of these patterns can be stored as materialized views first, which can speed up the query rate. So we propose materialized views on property graphs, including three parts: view creation, view maintenance, and query optimization using views, and we propose for the first time an efficient templated view maintenance method for containing variable-length edges, which can be applied to multiple graph databases. In order to verify the effect of materialized views, we prototype on TuGraph and experiment on both TuGraph and Neo4j. The experiment results show that our query optimization on read statements is much higher than the additional view maintenance cost brought by write statements. The speedup ratio of the whole workload reaches up to 28.71x, and the speedup ratio of a single query reaches up to nearly 100x.

MV4PG: Materialized Views for Property Graphs

TL;DR

MV4PG tackles slow query performance in graph databases by introducing materialized views for property graphs with a focus on variable-length edges. It combines three components—view creation, templated view maintenance, and query optimization using views—coupled with a VF2-like view matcher to integrate precomputed patterns into execution plans. The approach is validated on TuGraph and Neo4j with substantial gains: up to overall workload speedups and near for some single queries, while keeping maintenance overhead reasonable. The work demonstrates a practical pathway to speed up complex graph workloads and outlines concrete directions for automatic view selection and optimized maintenance strategies.

Abstract

Graph databases are getting more and more attention in the highly interconnected data domain, and the demand for efficient querying of big data is increasing. We noticed that there are duplicate patterns in graph database queries, and the results of these patterns can be stored as materialized views first, which can speed up the query rate. So we propose materialized views on property graphs, including three parts: view creation, view maintenance, and query optimization using views, and we propose for the first time an efficient templated view maintenance method for containing variable-length edges, which can be applied to multiple graph databases. In order to verify the effect of materialized views, we prototype on TuGraph and experiment on both TuGraph and Neo4j. The experiment results show that our query optimization on read statements is much higher than the additional view maintenance cost brought by write statements. The speedup ratio of the whole workload reaches up to 28.71x, and the speedup ratio of a single query reaches up to nearly 100x.

Paper Structure

This paper contains 14 sections, 2 equations, 15 figures, 2 tables, 4 algorithms.

Figures (15)

  • Figure 1: Example of View Creation
  • Figure 2: Example of View Maintenance
  • Figure 3: Example of Query Optimization Using Views
  • Figure 4: Overview of MV4PG
  • Figure 5: Syntax of View Creation
  • ...and 10 more figures

Theorems & Definitions (2)

  • Definition 1
  • Definition 2