Data Storage Database PostgreSQL and JSON File Format in Golang Using Gin-Gonic and Gin-Gonic with GORM
Abstract
Proficient data management and storage are imperative. Among the various programming languages and frameworks available, Golang Gin-Gonic and Golang Gin-Gonic with GORM are widely favored by developers for their speed and concurrent processing efficiency. Golang Gin-Gonic is especially valued for creating high-performance applications, while GORM extends Golang’s capabilities with a powerful GORM for database operations. Prior studies have emphasized Golang's effectiveness in data exchange and its superior response speed and resource efficiency compared to Java and Python. This study aims to analyze the performance of Golang Gin-Gonic and Golang Gin-Gonic with GORM concerning data storage, focusing on PostgreSQL databases and JSON file formats. PostgreSQL was selected for its robustness as an open-source RDBMS, while JSON was chosen for its lightweight and readable format. The research assesses the execution speed and concurrency performance of both frameworks during data storage tasks involving PostgreSQL and JSON. The study investigates the performance of Gin-Gonic and Gin-Gonic with GORM in handling concurrent data storage operations in PostgreSQL and JSON formats. Performance tests measured the duration and anomalies in data storage across three dummy data sizes, 1000, 2000, and 3000. The results indicated that, for basic Golang Gin-Gonic, JSON processing was generally faster than PostgreSQL, with a growing performance gap as data size increased. Specifically, JSON processing was 53.63% quicker for 1000 dummy data, 24.14% quicker for 2000 dummy data, and 43.76% quicker for 3000 dummy data. Conversely, Golang Gin-Gonic with GORM showed superior performance with PostgreSQL, being 21% faster for 1000 dummy data, 20.54% faster for 2000 dummy data, and 33.2% faster for 3000 dummy data compared to JSON processing. These findings imply that while JSON is more suitable for simpler configurations with basic Golang Gin-Gonic, PostgreSQL integrated with GORM offers enhanced performance for handling larger and more intricate data sets. This research provides valuable guidance for software developers in choosing the appropriate framework based on their specific requirements, considering factors such as speed, concurrency, and data storage type.
Keywords, Golang, Gin-Gonic, GORM, Data Storage, Performance analysis
Full Text:
PDFReferences
Andersson, T., & Brenden, C. (2018). Parallelism in Go and Java. Digitala Vetenskapliga Arkivet.
Badalyan, D., & Borisenko, O. (2022). Ansible execution control in Python and Golang for cloud orchestration. SoftwareX.
Dymora, P., & Paszkiewicz, A. (2020). Performance Analysis of Selected Programming Languages in the Context of Supporting Decision-Making Processes for Industry 4.0. MDPI, 1-17.
Galih Wiseso, L., Imrona, M., & Alamsyah, A. (2020). Analisis Performa Neo4j, MongoDB, dan PostgreSQL sebagai Database Manajemen Big. e-Proceeding of Engineering, 9690.
Suwarno, & Yulandi, A. P. (2023). Analisis Performa Backend Framework: Studi Komparasi Framework Golang dan Node.js. Jurnal Riset Sistem Informasi Dan Teknik Informatika (JURASIK), 155-168.
Vanura, J., & Kriz, P. (2018). Perfomance evaluation of Java, JavaScript and PHP serialization libraries for XML, JSON and binary formats. Lecture Notes in Computer Science (including subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics), 166-175.
Whitney, J. G. (2019). Distributed execution of communicating sequential process-style concurrency: Golang case study.
Wiji, S., & Wiwin, S. (2020). Implementasi Web Service dengan Metode REST Berbasis Golang pada Layanan Google Cloud Platform di PT Sumber Alfaria Trijaya, Tbk. Universitas Kristen Satya Wacana Salatiga.
Refbacks
- There are currently no refbacks.
Address:
Industrial Technology Faculty
4th Building 1rd Floor Institut Teknologi Nasional Bandung Campus
PHH. Mustapa Street 23 Bandung 40124
Tlp. 022-7272215, Fax. 022-7202892,
e-mail: isj@itenas.ac.id