Java-Chassis 1.0.0-m1 Release
SCB-434 add @GET sample code and update readme

Signed-off-by: zhengyangyong <yangyong.zheng@huawei.com>
4 files changed
tree: 35ac9772ae9de8c82453bb007f1d53c2cfdb8f2a
  1. .github/
  2. common/
  3. core/
  4. coverage-reports/
  5. demo/
  6. dynamic-config/
  7. edge/
  8. etc/
  9. foundations/
  10. handlers/
  11. integration-tests/
  12. java-chassis-dependencies/
  13. java-chassis-distribution/
  14. metrics/
  15. parent/
  16. providers/
  17. samples/
  18. scripts/
  19. service-registry/
  20. spring-boot-starter/
  21. swagger/
  22. tracing/
  23. transports/
  24. .gitignore
  25. .travis.settings.xml
  26. .travis.yml
  27. DISCLAIMER
  28. gpg-sec.tar.enc
  29. LICENSE
  30. NOTICE
  31. pom.xml
  32. README.md
README.md

Java Chassis

Build Status Coverage Status Maven Central License

Apache ServiceComb (incubating) Java Chassis is a Software Development Kit (SDK) for rapid development of microservices in Java, providing service registration, service discovery, dynamic routing, and service management features

Quick Start

Provider service:

import org.apache.servicecomb.*;
@RpcSchema(schemaId = "helloworld")
public class HelloWorldProvider implements HelloWorld {
    public String sayHello(String name) {
        return "Hello " + name;
    }
}

Consumer service:

import org.apache.servicecomb.*;
@Component
public class HelloWorldConsumer  {
	@RpcReference(microserviceName = "pojo", schemaId = "helloworld")
	private static HelloWorld helloWorld;

	public static void main(String[] args) {
		helloWorld.sayHello("Tank");
	}
}

Documentation

Project documentation is available on the ServiceComb website.

Building

You don’t need to build from source to use Java Chassis (binaries in apache nexus ), but if you want to try out the latest and greatest, Java Chassis can be easily built with the maven. You also need JDK 1.8.

  mvn clean install 

If you want to build the release kits from the source

  mvn clean install  -Prelease,distribution

The first build may take a longer than expected as Maven downloads all the dependencies.

Automated Testing

To build the docker image and run the integration tests with docker, you can use maven docker profile

  mvn clean install -Pdocker -Pit

If you are using docker machine, please use the following command

  mvn clean install -Pdocker -Pit -Pdocker-machine

Contact

Bugs: issues

mailing list: subscribe dev

Contributing

See CONTRIBUTING for details on submitting patches and the contribution workflow.

Reporting Issues

See reporting bugs for details about reporting any issues.