|
2 years ago | |
---|---|---|
.. | ||
gradle | 2 years ago | |
src | 2 years ago | |
.gitattributes | 2 years ago | |
README.md | 2 years ago | |
benchmark_config.json | 2 years ago | |
build.gradle.kts | 2 years ago | |
gradle.properties | 2 years ago | |
gradlew | 2 years ago | |
gradlew.bat | 2 years ago | |
settings.gradle.kts | 2 years ago | |
vertx-web-kotlinx-postgresql.dockerfile | 2 years ago | |
vertx-web-kotlinx.dockerfile | 2 years ago |
Vert.x-Web in Kotlin with request handling implemented as much with official kotlinx libraries as possible.
Code is written from scratch to be as concise as possible with common code extracted into common (possibly inline) functions. SQL client implementation details and JVM Options are adapted referring to the vertx-web portion and the vertx portion. All requests are handled in coroutines and suspend await
s are used instead of future compositions. Compared to the vertx-web-kotlin-coroutines portion, besides adopting the Kotlinx libraries, this project simplifies the code by using more built-in Coroutine functions and avoids mutability as much as possible. JSON serialization is implemented with kotlinx.serialization and Fortunes with kotlinx.html. The benchmark is run on the latest LTS version of JVM, 17.
implemented with kotlinx.serialization
implemented with kotlinx.html
The tests were run with:
http://localhost:8080/plaintext
http://localhost:8080/query?queries=
http://localhost:8080/cached_query?queries=
http://localhost:8080/update?queries=