The amaya-server implementation is based on Apache Tomcat.
To install it, you will need:
- Java 11+
- Maven/Gradle
- Full implementation of amaya-server
- Convenient interfaces for http request handling
- Full access to tomcat configuration
- Ready-to-use default configuration
dependencies {
implementation group: 'io.github.amayaframework', name: 'amaya-tomcat', version: '3.3.3-10.1.46'
// For websocket support (optionally)
implementation group: 'io.github.amayaframework', name: 'tomcat-embed-websocket', version: '10.1.46'
}<dependencies>
<dependency>
<groupId>io.github.amayaframework</groupId>
<artifactId>amaya-tomcat</artifactId>
<version>3.3.3-10.1.46</version>
</dependency>
<!-- For Websocket support (optionally) -->
<dependency>
<groupId>io.github.amayaframework</groupId>
<artifactId>tomcat-embed-websocket</artifactId>
<version>10.1.46</version>
</dependency>
import com.github.romanqed.juni.UniRunnable1;
import io.github.amayaframework.tomcat.TomcatServerFactory;
public final class Main {
public static void main(String[] args) throws Throwable {
var factory = new TomcatServerFactory();
var server = factory.create();
server.bind(8080);
server.handler(UniRunnable1.of(ctx -> {
ctx.response().writer().println("Hello from Amaya (Tomcat 10)");
}));
server.start();
}
}- Gradle - Dependency management
- Tomcat 10 - Http server implementation
- jfunc - Basic functional interfaces
- amaya-context - Universal http context api
- amaya-server - Universal server api
- RomanQed - Main work
See also the list of contributors who participated in this project.
This project is licensed under the Apache License 2.0 - see the LICENSE file for details