Analisis Performa Web Service dengan Pendekatan Synchronous Programming dan Reactive Programming - Wong, Vinncent Alexander; Aminul Akbar, Muhammad; Tri Afirianto (Jurnal Sistem Informasi, Teknologi Informasi, dan Edukasi Sistem Informasi, 2025)
Web service berperan penting dalam memungkinkan komunikasi antar aplikasi. Pendekatan tradisional yang umum digunakan adalah Synchronous Programming, di mana setiap request ditangani oleh satu thread (Thread per Request). Namun, metode ini memiliki keterbatasan, terutama saat terjadi lonjakan request yang signifikan. Thread harus menunggu proses I/O selesai sebelum melanjutkan tugas lain, sehingga mengurangi efisiensi dan performa server. Sebagai alternatif, Reactive Programming hadir dengan pendekatan asynchronous dan non-blocking. Penelitian ini membandingkan kedua pendekatan dengan mengukur throughput, response time, CPU usage, dan memory usage melalui load testing menggunakan K6. Hasil penelitian menunjukkan bahwa pendekatan Reactive Programming memiliki keunggulan signifikan dalam hal throughput dan response time dibandingkan Synchronous Programming pada berbagai skenario uji. Pada skenario 600 virtual user, Reactive Programming menghasilkan throughput rata-rata 69,49 req/s dibandingkan 46,20 req/s pada Synchronous Programming, dan response time 5,31 detik dibandingkan 8,46 detik. Namun, CPU usage pada Reactive Programming mencapai 67,19% dibandingkan 36,91% pada Synchronous Programming, dan memory usage mencapai 1225,63 MB dibandingkan 181,79 MB. Uji beda yang dilakukan memperkuat temuan bahwa terdapat perbedaan signifikan pada setiap metrik di setiap skenario antara kedua pendekatan (p < 0,05 untuk semua metrik). Penelitian ini memberikan wawasan bagi pengembang dalam memilih pendekatan yang sesuai, mempertimbangkan kebutuhan performa serta efisiensi penggunaan resource dalam pengembangan web service.   Abstract Web services play an important role in enabling communication between applications. A commonly used traditional approach is Synchronous Programming, where each request is handled by a single thread (Thread per Request). However, this method has limitations, especially when there is a significant spike in requests. Threads must wait for I/O processes to finish before continuing to other tasks, thereby reducing server efficiency and performance. As an alternative, Reactive Programming offers an asynchronous and non-blocking approach. This study compares both approaches by measuring throughput, response time, CPU usage, and memory usage through load testing using K6. The results show that the Reactive Programming approach has significant advantages in throughput and response time compared to Synchronous Programming across various test scenarios. In the 600 virtual user scenario, Reactive Programming produced an average throughput of 69.49 req/s compared to 46.20 req/s for Synchronous Programming, and a response time of 5.31 second compared to 8.46 second. However, CPU usage in Reactive Programming reached 67.19% compared to 36.91% in Synchronous Programming, and memory usage reached 1225.63 MB compared to 181.79 MB. The statistical tests conducted reinforce the findings that there are significant differences in every metric across all scenarios between the two approaches (p < 0.05 for all metrics). This study provides insights for developers in choosing the appropriate approach by considering performance needs and resource efficiency in web service development.