MSF4J will Support JAX-RS Sub-Resource and Running Multiple Microservice Runners
JAX-RS Sub-Resource
You can try out the sub-resources with the latest MSF4J snapshot version. https://github.com/wso2/msf4j/tree/master/samples/subresource is the MSF4J Sub resource sample that demonstrate how to use sub-resource with MSF4J.
Running Multiple MicroservicesRunners
In previous MSF4J versions we only support running a single MicroservicesRunner in a single JVM. With the next release you can run several MicroservicesRunners in a single JVM.
Following code segment shows a simple sample of the usage.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class Application { | |
public static void main(String[] args) { | |
new MicroservicesRunner() | |
.deploy(new HelloService()) | |
.start(); | |
new MicroservicesRunner(8081) | |
.deploy(new CalculationService()) | |
.start(); | |
} | |
} |
No comments:
Post a Comment