切换主题
易用、高性能、可扩展。基于 Kotlin Multiplatform + KSP,编译为原生二进制,零反射、毫秒级启动。
Neton.run(args) { http { port = 8080 } routing { get("/") { "Hello Neton!" } } }
编译为原生二进制,启动 ~3ms,内存占用 ~20MB,无 JVM 开销。适合边缘计算和资源受限环境。
参数绑定自动推断(Path / Query / Body),90% 场景零注解。路由按目录约定分组。
Authenticator + Guard 双层架构,支持 JWT / Session / Mock 认证,注解驱动授权。
http / routing / security / redis / cache / database / logging,install 即用,按需组合。
统一 Logger API,JSON 输出,内建 traceId / spanId 传播,自动脱敏,便于对接日志采集系统。
Controller 路由、参数绑定、Config SPI 均由 KSP 在编译期完成,零反射、零运行时扫描。