weeks of bullshit

This commit is contained in:
Relism
2026-04-17 08:18:11 +02:00
parent b5d4481502
commit 9efbe38c0c
157 changed files with 5171 additions and 1273 deletions
@@ -13,7 +13,16 @@ import java.util.concurrent.CompletableFuture;
*/
public interface ServerHandle {
CompletableFuture<Void> start();
/** Starts the accept loop on a background platform thread. Returns immediately. */
void start();
/**
* Starts the accept loop and blocks the calling thread until the server is stopped.
* Suitable for use in {@code main()} when no other work is needed after startup.
*/
void startAndBlock();
/** Gracefully stops the server, draining active connections. */
CompletableFuture<Void> stop();
static ServerHandle create(FlashConfiguration config, AbstractRouter router) throws IOException {