Solon v2.8.6

Java “纯血国产”应用开发框架:更快、更小、更简单。

并发高 2~ 3 倍;内存省 50%;调试重启可快至 10 倍;打包最多缩小 90%;同时支持 java8 ~ java22, graalvm native image 运行时。
Java
Kotlin
Groovy
@Controller
public class App {
    public static void main(String[] args) {
        Solon.start(App.class, args, app -> {
            //手写模式
            app.get("/hello1", ctx -> ctx.output("Hello world!"));
        });
    }

    //注解模式
    @Get
    @Socket
    @Mapping("/hello2")
    public String hello2(String name) {
        return String.format("Hello %s!", name);
    }
}
@Controller
class App {
    static void main(String[] args){
        Solon.start(App.class, args, app->{
            //手写模式
            app.get("/hello1", ctx -> ctx.output("Hello world!"))
        })
    }
    
    //注解模式
    @Get
    @Socket
    @Mapping("/hello2")
    String hello(@Param(defaultValue = "world") String name) {
        return String.format("Hello %s!", name)
    }
}
@Controller
class App {
    //注解模式
    @Get
    @Socket
    @Mapping("/hello2")
    fun hello(@Param(defaultValue = "world") name: String): String {
        return String.format("Hello %s!", name)
    }
}

fun main(args: Array<String>) {
    Solon.start(App::class.java, args) { app ->
        //手写模式
        app.get("/hello1") { ctx -> ctx.output("Hello world!") }
    }
}

软件使用授权方案

社区版(免费授权) | 企业版(付费签约授权)

开源合作伙伴

开放原子开源基金会 | 中国信通院(可信开源社区共同体) | 开源之夏 | GitEE GVP