loading
Papers Papers/2022 Papers Papers/2022

Research.Publish.Connect.

Paper

Authors: Fernando Miguel Carvalho and Pedro Fialho

Affiliation: ISEL, Polytechnic Institute of Lisbon, Portugal

Keyword(s): Web Templates, Server-Side Rendering, Non-Blocking, Asynchronous, Concurrent.

Abstract: Naive server-side rendering (SSR) techniques require a dedicated server thread per HTTP request, thereby limiting the number of concurrent requests to the available server threads. Furthermore, this approach proves impractical for modern low-thread servers like WebFlux, VertX, and Express Node.js. To achieve progressive rendering, asynchronous data models provided by non-blocking APIs must be utilized. Nevertheless, this method can introduce undesirable interleaving between template view processing and data access, potentially resulting in malformed HTML documents. Some template engines offer partial remedies through specific templating dialects, but they encounter two limitations. Firstly, their compatibility is confined to specific types of asynchronous APIs, such as the reactive stream Publisher API. Secondly, they typically support only a single asynchronous data model at a time. In this research, we propose an alternative web templating approach that embraces any asynchronous AP I (e.g., Publisher, promises, suspend functions, flow, etc.) and allows for multiple asynchronous data sources. Our approach is implemented on top of HtmlFlow, a Java-based DSL for writing type-safe HTML. We evaluated against state-of-the-art reactive servers, specifically WebFlux, and compared it with popular templating idioms like Thymeleaf and KotlinX.html. Our proposal effectively overcomes the limitations of existing approaches. (More)

CC BY-NC-ND 4.0

Sign In Guest: Register as new SciTePress user now for free.

Sign In SciTePress user: please login.

PDF ImageMy Papers

You are not signed in, therefore limits apply to your IP address 3.237.34.21

In the current month:
Recent papers: 100 available of 100 total
2+ years older papers: 200 available of 200 total

Paper citation in several formats:
Miguel Carvalho, F. and Fialho, P. (2023). Enhancing SSR in Low-Thread Web Servers: A Comprehensive Approach for Progressive Server-Side Rendering with any Asynchronous API and Multiple Data Models. In Proceedings of the 19th International Conference on Web Information Systems and Technologies - WEBIST; ISBN 978-989-758-672-9; ISSN 2184-3252, SciTePress, pages 37-48. DOI: 10.5220/0012165300003584

@conference{webist23,
author={Fernando {Miguel Carvalho}. and Pedro Fialho.},
title={Enhancing SSR in Low-Thread Web Servers: A Comprehensive Approach for Progressive Server-Side Rendering with any Asynchronous API and Multiple Data Models},
booktitle={Proceedings of the 19th International Conference on Web Information Systems and Technologies - WEBIST},
year={2023},
pages={37-48},
publisher={SciTePress},
organization={INSTICC},
doi={10.5220/0012165300003584},
isbn={978-989-758-672-9},
issn={2184-3252},
}

TY - CONF

JO - Proceedings of the 19th International Conference on Web Information Systems and Technologies - WEBIST
TI - Enhancing SSR in Low-Thread Web Servers: A Comprehensive Approach for Progressive Server-Side Rendering with any Asynchronous API and Multiple Data Models
SN - 978-989-758-672-9
IS - 2184-3252
AU - Miguel Carvalho, F.
AU - Fialho, P.
PY - 2023
SP - 37
EP - 48
DO - 10.5220/0012165300003584
PB - SciTePress