Mu Server quick start

Logo

Mu Server: Java's modern web server

Quick Start

Add one dependency...

<dependency>
    <groupId>io.muserver</groupId>
    <artifactId>mu-server</artifactId>
    <version>1.0.5</version>
</dependency>

...and say hello:

import io.muserver.*;
public class Hello {
    public static void main(String[] args) {
        MuServer server = MuServerBuilder.httpServer()
            .addHandler(Method.GET, "/", (request, response, pathParams) -> {
                response.write("Hello, world");
            })
            .start();
        System.out.println("Started server at " + server.uri());
    }
}

Features

Each release is tested with Java 8, 11, 17 and 21.