Abstract
NoSQL databases do not enforce a fixed and explicit schema, and thus offer a high level of flexibility in designing a database schema. However, how data is structured has a significant impact on the query and update performance. Selecting an appropriate schema depends not only on the application's conceptual data model but also on data characteristics and workload information. The challenge is to determine the most effective data modeling strategy - referencing or denormalization - to improve the overall workload performance. To this end, we provide an automated temporal schema optimization for NoSQL wide-column stores that improves workload performance by making a good trade-off between denormalization and referencing. Using data characteristics and workload information, we propose a two-step transformation from a temporal conceptual model into a model for the Cassandra wide-column store: (i) mapping a temporal UML class model to a schema design graph (SDG) and (ii) mapping the SDG to a Cassandra schema. In the two mappings, we adopt a cost model to optimize schema design via a trade-off between read and write costs. An experimental evaluation demonstrates that our approach generates schemas that lead to significant performance improvements while remaining workload sensitive. For the most expensive cases, our schema reduces the workload latency by up to three orders of magnitude.