The proliferation of RDF datasets has resulted in studies focusing on optimizing SPARQL query processing. Most existing work focuses on basic graph patterns (BGPs) and ignores other vital operators in SPARQL, such as UNION and OPTIONAL. SPARQL queries with these operators, which we abbreviate as SPARQL-UO, pose serious query plan generation challenges. In this paper, we propose techniques for executing SPARQL-UO queries using BGP execution as a building block, based on a novel BGP-based Evaluation (BE)-Tree representation of query plans. On top of this, we propose a series of cost-driven BE-tree transformations to generate more efficient plans by reducing the search space and intermediate result sizes, and a candidate pruning technique that further enhances efficiency at query time. Experiments confirm that our method outperforms the state-of-the-art by orders of magnitude.
翻译:RDF数据集的激增促使相关研究聚焦于SPARQL查询处理的优化。现有工作主要关注基本图模式(BGP),而忽略了SPARQL中其他重要操作符,如UNION和OPTIONAL。包含这些操作符的SPARQL查询(简称SPARQL-UO)给查询计划生成带来了严峻挑战。本文提出了一种基于BGP执行的SPARQL-UO查询执行技术,以BGP执行作为基础构件,并采用新型的基于BGP评估(BE)的树形查询计划表示。在此基础上,我们提出了一系列成本驱动的BE树变换方法,通过减少搜索空间和中间结果规模来生成更高效的查询计划,并引入候选剪枝技术以进一步提升查询时的执行效率。实验结果表明,我们的方法在性能上超出现有最优技术数个数量级。