Daikon is a simple and minimal framework for creating web applications in Kotlin with minimal effort. The main goals are:
- Use a framework easy to test
- Build a simple web application in less then 5 minutes
- Can run multiple instances of HTTP server at the same time
- Deploy application in container, with server start time less than 100ms
- Add JitPack in your root build.gradle at the end of repositories:
repositories {
...
maven { url 'https://jitpack.io' }
}
- Add the dependency
implementation 'com.github.DaikonWeb:daikon:1.9.0'
- Add the JitPack repository to your build file
<repositories>
<repository>
<id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
</repositories>
- Add the dependency
<dependency>
<groupId>com.github.DaikonWeb</groupId>
<artifactId>daikon</artifactId>
<version>1.9.0</version>
</dependency>
HttpServer()
.get("/foo") { _, res -> res.write("Hello foo") }
.post("/bar") { _, res -> res.write("Bye bar") }
.start().use {
assertThat(get("/foo").text).isEqualTo("Hello foo")
assertThat(post("/bar").text).isEqualTo("Bye bar")
}
- Documentation: https://daikonweb.github.io
- Examples: https://github.com/DaikonWeb/daikon-examples
This project is licensed under the Apache License 2.0 - see the LICENSE file for details