Abstract
Tree-shaped data often occur in business applications, e.g. a corporate hierarchy or a categorization of products. A natural class of analytic queries posed to such data consists of aggregate queries over subtrees. Evaluation of such queries in large data sets requires significant amount of time. In this paper we focus on dedicated data structures that materialize partial results of such queries in a form of well-known segment trees. In a multiprogramming environment such data structures require careful implementation. A naive design is going to suffer from synchronization problems. The root of such a structure will be updated by each transaction that changes anything down its subtree. We propose ring updates that allow using the presented data structure with multiple execution threads. Our implementation is designed to work with object-relational mapping systems. If an application uses stored hierarchical data, its designer can add annotations to augment mapped database objects with materialization of partial aggregations over subtrees. Mapping generators create all necessary storage objects and triggers. We describe our proof-of-concept prototype implementation of this feature in Hibernate. We also present an experimental evaluation of this prototype's performance. The results confirm that the proposed materializations notably boost the evaluation of analytical queries over hierarchies.
Talk to us
Join us for a 30 min session where you can share your feedback and ask us any queries you have
Disclaimer: All third-party content on this website/platform is and will remain the property of their respective owners and is provided on "as is" basis without any warranties, express or implied. Use of third-party content does not indicate any affiliation, sponsorship with or endorsement by them. Any references to third-party content is to identify the corresponding services and shall be considered fair use under The CopyrightLaw.