• Journal of Internet Computing and Services
    ISSN 2287 - 1136 (Online) / ISSN 1598 - 0170 (Print)
    https://jics.or.kr/

SPA ViewModel Transformation for RESTful API


Dong-il Cho, Journal of Internet Computing and Services, Vol. 24, No. 1, pp. 9-15, Feb. 2023
10.7472/jksii.2023.24.1.9, Full Text:
Keywords: RESTful APIs, Single-Page Application, ViewModel, Model Mapping

Abstract

Single-Page Application(SPA) requires data transformation for communication with RESTful API. The Backend for Frontend(BFF) pattern handles this transformation in the server, but there is some problem that increases the number of communication and makes development and distribution difficult. In this study, we propose an architecture that maps the ViewModel of SPA and the model of RESTful API directly in SPA. The proposed architecture automatically generates a mapping model between the RESTful API model and the ViewModel using the OpenAPI specification, which is the document model of the RESTful API. The data transfer component of SPA automatically converts RESTful API data and ViewModel using the created model. As a result of comparison with the existing BFF method through case study, the proposed architecture showed higher development productivity than BFF, and as a result of load tests, it recorded about 6% lower server CPU occupancy compared to BFF.


Statistics
Show / Hide Statistics

Statistics (Cumulative Counts from November 1st, 2017)
Multiple requests among the same browser session are counted as one view.
If you mouse over a chart, the values of data points will be shown.


Cite this article
[APA Style]
Cho, D. (2023). SPA ViewModel Transformation for RESTful API. Journal of Internet Computing and Services, 24(1), 9-15. DOI: 10.7472/jksii.2023.24.1.9.

[IEEE Style]
D. Cho, "SPA ViewModel Transformation for RESTful API," Journal of Internet Computing and Services, vol. 24, no. 1, pp. 9-15, 2023. DOI: 10.7472/jksii.2023.24.1.9.

[ACM Style]
Dong-il Cho. 2023. SPA ViewModel Transformation for RESTful API. Journal of Internet Computing and Services, 24, 1, (2023), 9-15. DOI: 10.7472/jksii.2023.24.1.9.