Improving Microinterface Performance by Executing C Code in Javascript Execution Environments Using Bun

2025;
: pp. 272 - 283
1
Lviv Polytechnic National University, Ukraine
2
Lviv Politechnic National University, Ukraine

This paper explores a new feature introduced in Bun that allows for direct compilation and execution of native C code from JavaScript, opening up new horizons for integrating system libraries and improving the performance of JavaScript applications. We analyze the limitations of existing methods such as N-API and WebAssembly, focusing on their complexity and performance impact, especially in the context of using microinterfaces. Bun’s approach, based on direct compilation and the use of a lightweight wrapper, is seen as a potentially more efficient alternative. Although detailed information on the performance of Bun’s C is not yet available, we propose a comprehensive research plan that will cover various usage scenarios, including microinterface performance analysis, data transfer, and integration with popular C libraries. This research will allow us to evaluate the effectiveness of Bun’s C and its potential for developing JavaScript applications on both the server side (Node.js) and, possibly, the client side. Special attention will be paid to the ability to create highly efficient and safe microinterfaces between JavaScript and C using Bun, which opens up new possibilities for developing modular and flexible applications.

  1. Blinowski G., Ojdowska A., Przybylek A. Monolithic vs. Microservice Architecture: A performance and scalability evaluation. IEEE Access. 2022. 10. 20357–20374. Doi: https://doi.org/10.1109/access.2022.3152803.
  2. Terdal S. Microservices enabled e-commerce web application. International Journal of Research in Applied Science and Engineering Technology. 2022. 10(7). 3548–3555. Doi: https://doi.org/10.22214/ ijraset.2022.45791.
  3. Zhou J., Yang L., Wu J. Micro-frontend architecture base. In Proceedings of the Sixth International Conference on Computer Information Science and Application Technology (CISAT). 2023. Doi: https:// doi.org/ 10.1117/12.3003818.
  4. Pontarolli R. P., Bigheti J. A., de Sá L. B. R., Godoy E. P. L. Microservice-Oriented Architecture for Industry 4.0. Engineering. 2023. 4. 1179–1197. Doi: https://doi.org/10.3390/eng4020069.
  5. Perlin R., Ebling D., Maran V., Descovi G., Machado A. An approach to follow microservices principles in frontend. In Proceedings of the IEEE 17th International Conference on Application Information and Communication Technology (AICT). 2023. Doi: https://doi.org/10.1109/aict59525.2023.10313208.
  6. Auer F., Lenarduzzi V., Felderer M., Taibi D. From Monolithic Systems to Microservices: An assessment framework. Information and Software Technology. 2021. 137, 106600. Doi: https://doi.org/10.1016/ j.infsof. 2021.106600.
  7. Marco V., Farias K. Exploring the technologies and architectures used to develop micro-frontend applications: A systematic mapping and emerging perspectives. SSRN Electronic Journal. 2024. Doi: https://doi.org/10.2139/ssrn.475066.
  8. Abdellatif M., Shatnawi A., Mili H., Moha N., Boussaidi G. E., Hecht G., Privat J., Guéhéneuc Y.-G. A taxonomy of Service Identification Approaches for Legacy Software Systems Modernization. Journal of Systems and Software. 2021. 173, 110868. Doi: https://doi.org/10.1016/j.jss.2020.110868.
  9. Nikulina O., Khatsko K. Method of converting the monolithic architecture of a front-end application to microfrontends. Bulletin of National Technical University KhPI Series System Analysis Control Information Technologies. 2023. 2(10). 79–84. Doi: https://doi.org/10.20998/2079-0023.2023.02.12.
  10. Stepanov O., Klym H. Features of the implementation of micro-interfaces in information systems. Advances in Cyber-Physical Systems (ACPS). 2024. 9(1). 54–60. Doi: https://doi.org/10.23939/acps2024.01.054.
  11. Stepanov O., Klym H. Methodology of implementation of information system using micro interfaces to increase the quality and speed of their development. Computer Systems and Networks (CSN). 2024. 6(2). 222–231. Doi:    https://doi.org/10.23939/csn2024.02.222.