Java 微服務框架,Microserver v0.80 發布
Microserver 是一個零配置、基于標準的身經百戰的庫,用來運行 Java REST 微服務,通過 Java 標準 main 類執行。從 2014 年開始就一直在 AOL 生產環境中使用。
Microserver v0.80 發布,更新如下:
New in Microserver v0.80
A spring-based platform for plugin based Microservices development.
新插件
micro-spring-boot
The micro-spring-boot plugin allows full-stack integration with Spring Boot (in contrast to the pre-existing Spring Boot plugin which supports only Spring Boot backends). With micro-spring-boot you can run Spring Boot managed servers with Microserver Jersey configuration and plugins.
An example Spring Boot Jersey App with Microserver
@MicroSpringBoot //configure this package as the base for autoscan
//optionally use @Microserver here for more configuration options
public class SimpleExample {
RestClient rest = new RestClient(10_000,1_000);
public static void main (String[] args){
new MicroserverApp(()-> "simple-app"); //note unlike traditional microserver apps, there is no need to call start or run here
assertThat(rest.get("http://localhost:8080/simple-app/status/ping"),equalTo("ok"));
}
}
@Rest
@Path("/status")
public class SimpleResource{
@GET
@Produces("text/plain")
@Path("/ping")
public String ping() {
return "ok";
}
} 特性跟蹤
S3 plugin should allow users to specify a region for S3 client enhancement #151 opened 7 days ago by kewangie
micro-hibernate shouldn't depend on micro-hikaricp bug #146 opened 14 days ago by kewangie
micro-boot integration - Allow micro-boot apps to use Spring Boot severs and front ends enhancement #128 opened on Dec 14, 2015 by johnmcclean-aol
下載頁面:0.80
框架結構:

來自: http://www.oschina.net//news/70101/microserver-0-80