Abstract
We present a new method for automated index suggestion for MongoDB, based solely on the queries (called aggregation pipelines), without requiring data or usage information. The solution handles complex aggregations and is suitable for both cloud and standalone databases. We validated the algorithm on TPC-H and showed that all suggested indexes were used. We report on the performance and provide hints for further development of an automated method of index selection. Our algorithm is, to the best of our knowledge, the first query-based solution for automated indexing in MongoDB.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Similar content being viewed by others
References
pier4all AG (Ltd.): enablerr - the revolutionary business solution (2021). https://www.enablerr.ch/en/
Chaudhuri, S., Narasayya, V.: Index merging. In: ICDE, pp. 296–303. IEEE (1999)
de Espona Pernas, L., Pustulka, E.: Document versioning for MongoDB. In: Chiusano, S., et al. (eds.) New Trends in Database and Information Systems. Communications in Computer and Information Science, vol. 1652, pp. 512–524. Springer, Cham (2022). https://doi.org/10.1007/978-3-031-15743-1_47
de Espona Pernas, L., Pustulka, E.: MongoDB data versioning performance: local versus Atlas. In: DataPlat. CEUR-WS.org (2023)
Harrison, G., Harrison, M.: MongoDB Performance Tuning: Optimizing MongoDB Databases and their Applications. Apress Berkeley, New York (2021)
Kersten, M.L., Manegold, S.: Cracking the database store. In: CIDR 2005, pp. 213–224 (2005). https://www.cidrdb.org/
Kossmann J., Halfpap S., J.M.S.R.: Magic mirror in my hand, which is the best in the land? An experimental evaluation of index selection algorithms. In: Proceedings of the VLDB, pp. 2382–2395. ACM (2020). https://doi.org/10.14778/3407790.3407832
Kvet, M.: Database index balancing strategy. In: 29th Conference of Open Innovations Association (FRUCT), pp. 214–221 (2021)
Kvet, M.: Relational data index consolidation. In: 28th Conference of Open Innovations Association (FRUCT), pp. 215–221 (2021)
Li, G., et al.: openGauss: an autonomous database system. Proc. VLDB 14(12), 3028–3042 (2021)
Llano-Ríos, T.F., Khalefa, M., Badia, A.: Experimental comparison of relational and NoSQL document systems: the case of decision support. In: Nambiar, R., Poess, M. (eds.) TPCTC 2020. LNCS, vol. 12752, pp. 58–74. Springer, Cham (2021). https://doi.org/10.1007/978-3-030-84924-5_5
Lum, V.Y.: On the selection of secondary indexes. In: Proceedings of the 1974 Annual ACM Conference - Volume 2, ACM ’74, p. 736. ACM (1974)
MongoDB, I.: MongoDB (2021). https://www.mongodb.com
Poess, M., Floyd, C.: New TPC benchmarks for decision support and web commerce. SIGMOD Rec. 29(4), 64–71 (2000)
Pustulka, E., von Arx, S., de Espona, L.: Building a NoSQL ERP. In: Yang, X.S., Sherratt, S., Dey, N., Joshi, A. (eds.) Proceedings of Seventh International Congress on Information and Communication Technology. Lecture Notes in Networks and Systems, vol. 448, pp. 671–680. Springer, Singapore (2023). https://doi.org/10.1007/978-981-19-1610-6_59
TPC: TPC BenchmarkTM H Standard Specification Revision 3.0.0. TPC (2022). https://www.tpc.org/tpc_documents_current_versions/pdf/tpc-h_v3.0.0.pdf
Vitter, J.S.: External memory algorithms and data structures: dealing with massive data. ACM Comput. Surv. 33(2), 209–271 (2001)
Wang, J., Trummer, I., Basu, D.: Demonstrating udo: A unified approach for optimizing transaction code, physical design, and system parameters via reinforcement learning. In: Proceedings of the International Conference on Management of Data, pp. 2794–2797 (2021)
Zardbani, F., Afshani, P., Karras, P.: Revisiting the theory and practice of database cracking. In: EDBT 2020, pp. 415–418. OpenProceedings.org (2020)
Acknowledgements
We acknowledge funding from www.innosuisse.ch, Grant No. 44824.1 IP-ICT and support from project 030TUKE-4/2023 from the Cultural and Education Grant Agency of the Slovak Ministry of Education. We thank Saverio Damiani and Anton Lorvi for their work and Prof. Christian Dolfus (HSLU) for providing the server. We have no conflicts of interest to disclose.
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2023 The Author(s), under exclusive license to Springer Nature Switzerland AG
About this paper
Cite this paper
de Espona Pernas, L., Vichalkovski, A., Steingartner, W., Pustulka, E. (2023). Automatic Indexing for MongoDB. In: Abelló, A., et al. New Trends in Database and Information Systems. ADBIS 2023. Communications in Computer and Information Science, vol 1850. Springer, Cham. https://doi.org/10.1007/978-3-031-42941-5_46
Download citation
DOI: https://doi.org/10.1007/978-3-031-42941-5_46
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-031-42940-8
Online ISBN: 978-3-031-42941-5
eBook Packages: Computer ScienceComputer Science (R0)