├── README.md ├── .gitignore ├── dubbo-demo-api ├── src │ └── main │ │ └── java │ │ └── com │ │ └── github │ │ └── loafer │ │ └── demo │ │ └── dubbo │ │ └── api │ │ └── hello │ │ └── HelloService.java └── pom.xml ├── dubbo-demo-provider ├── src │ └── main │ │ ├── resources │ │ ├── applicationContext.xml │ │ ├── springrest-protocol.xml │ │ ├── provider-token.xml │ │ ├── cluster │ │ │ ├── hello-provider-20880.xml │ │ │ ├── hello-provider-20881.xml │ │ │ └── hello-provider-20882.xml │ │ ├── provider-multicast.xml │ │ └── provider-zookeeper.xml │ │ ├── java │ │ └── com │ │ │ └── github │ │ │ └── loafer │ │ │ └── demo │ │ │ └── dubbo │ │ │ └── hello │ │ │ ├── TokenProvider.java │ │ │ ├── controller │ │ │ └── HelloController.java │ │ │ ├── SpringRestProvider.java │ │ │ ├── MulticastProvider.java │ │ │ ├── ZookeeperProvider.java │ │ │ ├── cluster │ │ │ ├── Provider1.java │ │ │ ├── Provider2.java │ │ │ └── Provider3.java │ │ │ ├── support │ │ │ └── HelloServiceImpl.java │ │ │ └── AbstractProvider.java │ │ └── webapp │ │ └── WEB-INF │ │ ├── dubbo-demo-provider.xml │ │ └── web.xml └── pom.xml ├── dubbo-demo-consumer ├── src │ └── main │ │ ├── java │ │ └── com │ │ │ └── github │ │ │ └── loafer │ │ │ └── demo │ │ │ └── dubbo │ │ │ └── hello │ │ │ ├── TokenConsumer.java │ │ │ ├── ClusterConsumer.java │ │ │ ├── ZookeeperConsumer.java │ │ │ ├── MulticastConsumer.java │ │ │ ├── StartCheckApplication.java │ │ │ ├── DirectConnectionConsumer.java │ │ │ └── AbstractHelloConsumer.java │ │ └── resources │ │ ├── consumer-multicast.xml │ │ ├── consumer-token.xml │ │ ├── consumer-start-check.xml │ │ ├── cluster-consumer.xml │ │ ├── direct-connect-20882-consumer.xml │ │ └── consumer-zookeeper.xml └── pom.xml └── pom.xml /README.md: -------------------------------------------------------------------------------- 1 | # dubbo-tutorials 2 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | *.iml 2 | *.ipr 3 | *.iws 4 | .idea/ 5 | target/ 6 | pom.xml.tag 7 | pom.xml.releaseBackup 8 | pom.xml.versionsBackup 9 | pom.xml.next 10 | release.properties 11 | -------------------------------------------------------------------------------- /dubbo-demo-api/src/main/java/com/github/loafer/demo/dubbo/api/hello/HelloService.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.api.hello; 2 | 3 | /** 4 | * @author zhaojh. 5 | */ 6 | public interface HelloService { 7 | String sayHello(String name); 8 | } 9 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/resources/applicationContext.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 9 | -------------------------------------------------------------------------------- /dubbo-demo-consumer/src/main/java/com/github/loafer/demo/dubbo/hello/TokenConsumer.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello; 2 | 3 | import org.springframework.beans.factory.annotation.Configurable; 4 | import org.springframework.boot.SpringApplication; 5 | import org.springframework.context.annotation.ImportResource; 6 | 7 | /** 8 | * @author zhaojh. 9 | */ 10 | @Configurable 11 | @ImportResource({"consumer-token.xml"}) 12 | public class TokenConsumer extends AbstractHelloConsumer { 13 | public static void main(String[] args){ 14 | SpringApplication.run(TokenConsumer.class); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /dubbo-demo-consumer/src/main/java/com/github/loafer/demo/dubbo/hello/ClusterConsumer.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello; 2 | 3 | import org.springframework.boot.SpringApplication; 4 | import org.springframework.context.annotation.Configuration; 5 | import org.springframework.context.annotation.ImportResource; 6 | 7 | /** 8 | * @author zhaojh. 9 | */ 10 | @Configuration 11 | @ImportResource({"cluster-consumer.xml"}) 12 | public class ClusterConsumer extends AbstractHelloConsumer { 13 | 14 | public static void main(String[] args){ 15 | SpringApplication.run(ClusterConsumer.class); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /dubbo-demo-consumer/src/main/java/com/github/loafer/demo/dubbo/hello/ZookeeperConsumer.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello; 2 | 3 | import org.springframework.boot.SpringApplication; 4 | import org.springframework.context.annotation.Configuration; 5 | import org.springframework.context.annotation.ImportResource; 6 | 7 | /** 8 | * @author zhaojh. 9 | */ 10 | @Configuration 11 | @ImportResource({"consumer-zookeeper.xml"}) 12 | public class ZookeeperConsumer extends AbstractHelloConsumer { 13 | public static void main(String[] args){ 14 | SpringApplication.run(ZookeeperConsumer.class); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /dubbo-demo-api/pom.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 4.0.0 6 | 7 | dubbo-demo-api 8 | jar 9 | 10 | 11 | dubbo-tutorials 12 | com.github.loafer 13 | 0.0.1-SNAPSHOT 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/java/com/github/loafer/demo/dubbo/hello/TokenProvider.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello; 2 | 3 | import org.springframework.beans.factory.annotation.Configurable; 4 | import org.springframework.boot.SpringApplication; 5 | import org.springframework.context.annotation.ImportResource; 6 | 7 | /** 8 | * @author zhaojh. 9 | */ 10 | @Configurable 11 | @ImportResource({"applicationContext.xml","provider-token.xml"}) 12 | public class TokenProvider extends AbstractProvider { 13 | public static void main(String[] args){ 14 | SpringApplication.run(TokenProvider.class); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /dubbo-demo-consumer/src/main/java/com/github/loafer/demo/dubbo/hello/MulticastConsumer.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello; 2 | 3 | import org.springframework.boot.SpringApplication; 4 | import org.springframework.boot.autoconfigure.SpringBootApplication; 5 | import org.springframework.context.annotation.ImportResource; 6 | 7 | /** 8 | * @author zhaojh. 9 | */ 10 | @SpringBootApplication 11 | @ImportResource({"consumer-multicast.xml"}) 12 | public class MulticastConsumer extends AbstractHelloConsumer { 13 | public static void main(String[] args){ 14 | SpringApplication.run(MulticastConsumer.class); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/java/com/github/loafer/demo/dubbo/hello/controller/HelloController.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello.controller; 2 | 3 | import com.github.loafer.demo.dubbo.api.hello.HelloService; 4 | import org.springframework.web.bind.annotation.RequestMapping; 5 | import org.springframework.web.bind.annotation.RestController; 6 | 7 | /** 8 | * @author zhaojh. 9 | */ 10 | @RestController 11 | public class HelloController implements HelloService { 12 | 13 | @Override 14 | @RequestMapping(value = "hello") 15 | public String sayHello(String name) { 16 | return "Hello, " + name; 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /dubbo-demo-consumer/src/main/java/com/github/loafer/demo/dubbo/hello/StartCheckApplication.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello; 2 | 3 | import org.springframework.boot.SpringApplication; 4 | import org.springframework.context.annotation.Configuration; 5 | import org.springframework.context.annotation.ImportResource; 6 | 7 | 8 | /** 9 | * @author zhaojh. 10 | */ 11 | @Configuration 12 | @ImportResource({"consumer-start-check.xml"}) 13 | public class StartCheckApplication extends AbstractHelloConsumer { 14 | public static void main(String[] args){ 15 | SpringApplication.run(StartCheckApplication.class); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/java/com/github/loafer/demo/dubbo/hello/SpringRestProvider.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello; 2 | 3 | import org.springframework.beans.factory.annotation.Configurable; 4 | import org.springframework.boot.SpringApplication; 5 | import org.springframework.context.annotation.ImportResource; 6 | 7 | /** 8 | * @author zhaojh. 9 | */ 10 | @Configurable 11 | @ImportResource({"applicationContext.xml","springrest-protocol.xml"}) 12 | public class SpringRestProvider extends AbstractProvider { 13 | public static void main(String[] args){ 14 | SpringApplication.run(SpringRestProvider.class); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /dubbo-demo-consumer/src/main/java/com/github/loafer/demo/dubbo/hello/DirectConnectionConsumer.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello; 2 | 3 | import org.springframework.boot.SpringApplication; 4 | import org.springframework.context.annotation.Configuration; 5 | import org.springframework.context.annotation.ImportResource; 6 | 7 | /** 8 | * @author zhaojh. 9 | * 演示直连提供者(演示时请启动provider集群) 10 | */ 11 | @Configuration 12 | @ImportResource({"direct-connect-20882-consumer.xml"}) 13 | public class DirectConnectionConsumer extends AbstractHelloConsumer { 14 | public static void main(String[] args){ 15 | SpringApplication.run(DirectConnectionConsumer.class); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/java/com/github/loafer/demo/dubbo/hello/MulticastProvider.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello; 2 | 3 | import org.springframework.boot.SpringApplication; 4 | import org.springframework.boot.autoconfigure.SpringBootApplication; 5 | import org.springframework.context.annotation.ImportResource; 6 | 7 | /** 8 | * @author zhaojh. 9 | */ 10 | @SpringBootApplication(exclude = ZookeeperProvider.class) 11 | @ImportResource({"applicationContext.xml", "provider-multicast.xml"}) 12 | public class MulticastProvider extends AbstractProvider{ 13 | public static void main(String[] args){ 14 | SpringApplication.run(MulticastProvider.class); 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/java/com/github/loafer/demo/dubbo/hello/ZookeeperProvider.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello; 2 | 3 | import org.springframework.boot.SpringApplication; 4 | import org.springframework.context.annotation.Configuration; 5 | import org.springframework.context.annotation.ImportResource; 6 | 7 | /** 8 | * @author zhaojh. 9 | */ 10 | //@SpringBootApplication(exclude = MulticastProvider.class) 11 | @Configuration 12 | @ImportResource({"applicationContext.xml","provider-zookeeper.xml"}) 13 | public class ZookeeperProvider extends AbstractProvider{ 14 | 15 | public static void main(String[] args){ 16 | SpringApplication.run(ZookeeperProvider.class, args); 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/java/com/github/loafer/demo/dubbo/hello/cluster/Provider1.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello.cluster; 2 | 3 | import com.github.loafer.demo.dubbo.hello.AbstractProvider; 4 | import org.springframework.boot.SpringApplication; 5 | import org.springframework.context.annotation.Configuration; 6 | import org.springframework.context.annotation.ImportResource; 7 | 8 | /** 9 | * @author zhaojh. 10 | */ 11 | @Configuration 12 | @ImportResource({"applicationContext.xml", "cluster/hello-provider-20880.xml"}) 13 | public class Provider1 extends AbstractProvider { 14 | public static void main(String[] args){ 15 | SpringApplication.run(Provider1.class, "20880"); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/java/com/github/loafer/demo/dubbo/hello/cluster/Provider2.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello.cluster; 2 | 3 | import com.github.loafer.demo.dubbo.hello.AbstractProvider; 4 | import org.springframework.boot.SpringApplication; 5 | import org.springframework.context.annotation.Configuration; 6 | import org.springframework.context.annotation.ImportResource; 7 | 8 | /** 9 | * @author zhaojh. 10 | */ 11 | @Configuration 12 | @ImportResource({"applicationContext.xml", "cluster/hello-provider-20881.xml"}) 13 | public class Provider2 extends AbstractProvider{ 14 | public static void main(String[] args){ 15 | SpringApplication.run(Provider2.class, "20881"); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/java/com/github/loafer/demo/dubbo/hello/cluster/Provider3.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello.cluster; 2 | 3 | import com.github.loafer.demo.dubbo.hello.AbstractProvider; 4 | import org.springframework.boot.SpringApplication; 5 | import org.springframework.context.annotation.Configuration; 6 | import org.springframework.context.annotation.ImportResource; 7 | 8 | /** 9 | * @author zhaojh. 10 | */ 11 | @Configuration 12 | @ImportResource({"applicationContext.xml", "cluster/hello-provider-20882.xml"}) 13 | public class Provider3 extends AbstractProvider { 14 | public static void main(String[] args){ 15 | SpringApplication.run(Provider3.class, "20882"); 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /dubbo-demo-consumer/src/main/resources/consumer-multicast.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /dubbo-demo-consumer/src/main/resources/consumer-token.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 7 | 8 | 9 | 10 | 12 | -------------------------------------------------------------------------------- /dubbo-demo-consumer/src/main/resources/consumer-start-check.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 7 | 8 | 9 | 10 | 13 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/resources/springrest-protocol.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 14 | -------------------------------------------------------------------------------- /dubbo-demo-consumer/src/main/resources/cluster-consumer.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 11 | 12 | 13 | 14 | 16 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/java/com/github/loafer/demo/dubbo/hello/support/HelloServiceImpl.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello.support; 2 | 3 | import com.alibaba.dubbo.rpc.RpcContext; 4 | import com.github.loafer.demo.dubbo.api.hello.HelloService; 5 | import org.apache.commons.lang3.StringUtils; 6 | import org.slf4j.Logger; 7 | import org.slf4j.LoggerFactory; 8 | 9 | /** 10 | * @author zhaojh. 11 | */ 12 | public class HelloServiceImpl implements HelloService { 13 | private final Logger logger = LoggerFactory.getLogger(this.getClass()); 14 | 15 | @Override 16 | public String sayHello(String name) { 17 | logger.info("receive from {} remote call.", RpcContext.getContext().getRemoteAddressString()); 18 | return StringUtils.isNotBlank(name) ? "Hello, " + name + '!':"Hello, World!"; 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/resources/provider-token.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 14 | -------------------------------------------------------------------------------- /dubbo-demo-consumer/src/main/resources/direct-connect-20882-consumer.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 7 | 8 | 9 | 10 | 13 | -------------------------------------------------------------------------------- /dubbo-demo-consumer/src/main/resources/consumer-zookeeper.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 13 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/resources/cluster/hello-provider-20880.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 18 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/resources/cluster/hello-provider-20881.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 18 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/resources/cluster/hello-provider-20882.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 18 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/resources/provider-multicast.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 13 | 14 | 15 | 16 | 17 | 19 | 20 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/webapp/WEB-INF/dubbo-demo-provider.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 14 | 15 | 16 | -------------------------------------------------------------------------------- /dubbo-demo-consumer/pom.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 4.0.0 7 | 8 | dubbo-demo-consumer 9 | jar 10 | 11 | 12 | dubbo-tutorials 13 | com.github.loafer 14 | 0.0.1-SNAPSHOT 15 | 16 | 17 | 18 | 19 | org.springframework.boot 20 | spring-boot-starter 21 | 22 | 23 | 24 | com.github.loafer 25 | dubbo-demo-api 26 | 27 | 28 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/resources/provider-zookeeper.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 6 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 18 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/java/com/github/loafer/demo/dubbo/hello/AbstractProvider.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello; 2 | 3 | import org.slf4j.Logger; 4 | import org.slf4j.LoggerFactory; 5 | import org.springframework.boot.CommandLineRunner; 6 | 7 | import java.util.Scanner; 8 | 9 | /** 10 | * @author zhaojh. 11 | */ 12 | public abstract class AbstractProvider implements CommandLineRunner { 13 | private final Logger logger = LoggerFactory.getLogger(this.getClass()); 14 | 15 | @Override 16 | public void run(String... strings) throws Exception { 17 | logger.info("服务已启动。"); 18 | 19 | if(strings.length==1){ 20 | logger.info("监听端口:{}", strings[0]); 21 | } 22 | 23 | logger.info("输入 [quit] or [q] 退出程序."); 24 | Scanner scanner = new Scanner(System.in); 25 | String read = scanner.nextLine(); 26 | 27 | while (true){ 28 | if(read.equalsIgnoreCase("quit") || read.equalsIgnoreCase("q")){ 29 | System.exit(0); 30 | } 31 | 32 | read = scanner.nextLine(); 33 | } 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /dubbo-demo-provider/src/main/webapp/WEB-INF/web.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 9 | contextConfigLocation 10 | /WEB-INF/dubbo-demo-provider.xml 11 | 12 | 13 | 14 | com.alibaba.dubbo.remoting.http.servlet.BootstrapListener 15 | 16 | 17 | 18 | org.springframework.web.context.ContextLoaderListener 19 | 20 | 21 | 22 | dispatcher 23 | com.alibaba.dubbo.remoting.http.servlet.DispatcherServlet 24 | 1 25 | 26 | 27 | 28 | dispatcher 29 | /services/* 30 | 31 | 32 | -------------------------------------------------------------------------------- /dubbo-demo-consumer/src/main/java/com/github/loafer/demo/dubbo/hello/AbstractHelloConsumer.java: -------------------------------------------------------------------------------- 1 | package com.github.loafer.demo.dubbo.hello; 2 | 3 | import com.alibaba.dubbo.rpc.RpcContext; 4 | import com.github.loafer.demo.dubbo.api.hello.HelloService; 5 | import org.slf4j.Logger; 6 | import org.slf4j.LoggerFactory; 7 | import org.springframework.boot.CommandLineRunner; 8 | 9 | import javax.annotation.Resource; 10 | import java.util.Scanner; 11 | 12 | /** 13 | * @author zhaojh. 14 | */ 15 | public abstract class AbstractHelloConsumer implements CommandLineRunner { 16 | protected final Logger logger = LoggerFactory.getLogger(this.getClass()); 17 | 18 | @Resource 19 | private HelloService helloService; 20 | 21 | @Override 22 | public void run(String... strings) throws Exception { 23 | logger.info("输入 [quit] or [q] 退出应用."); 24 | logger.info("输入 [run] or [r] 启动服务调用."); 25 | 26 | Scanner scanner = new Scanner(System.in); 27 | String read = scanner.nextLine(); 28 | while (true){ 29 | if(read.equalsIgnoreCase("quit")||read.equalsIgnoreCase("q")){ 30 | System.exit(0); 31 | } 32 | 33 | if(read.equalsIgnoreCase("run") || read.equalsIgnoreCase("r")){ 34 | logger.info(helloService.sayHello("Dubbo")); 35 | logger.info("invoke remote service: " + RpcContext.getContext().getRemoteAddressString()); 36 | } 37 | 38 | read = scanner.nextLine(); 39 | } 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /dubbo-demo-provider/pom.xml: -------------------------------------------------------------------------------- 1 | 2 | 5 | 4.0.0 6 | 7 | dubbo-demo-provider 8 | jar 9 | 10 | 11 | dubbo-tutorials 12 | com.github.loafer 13 | 0.0.1-SNAPSHOT 14 | 15 | 16 | 17 | 18 | org.springframework.boot 19 | spring-boot-starter 20 | 21 | 22 | 23 | com.github.loafer 24 | dubbo-demo-api 25 | 26 | 27 | 28 | com.github.loafer 29 | dubbo-rpc-springrest 30 | 0.0.1-SNAPSHOT 31 | 32 | 33 | 34 | javax.servlet 35 | javax.servlet-api 36 | 37 | 38 | 39 | 40 | 41 | 42 | org.springframework.boot 43 | spring-boot-maven-plugin 44 | 45 | 46 | 47 | -------------------------------------------------------------------------------- /pom.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 4.0.0 5 | 6 | com.github.loafer 7 | dubbo-tutorials 8 | 0.0.1-SNAPSHOT 9 | pom 10 | 11 | 12 | dubbo-demo-api 13 | dubbo-demo-provider 14 | dubbo-demo-consumer 15 | dubbo-rpc-springrest 16 | 17 | 18 | 19 | org.springframework.boot 20 | spring-boot-starter-parent 21 | 1.2.5.RELEASE 22 | 23 | 24 | 25 | 2.8.4 26 | 3.1.0 27 | 1.2.5.RELEASE 28 | 0.1 29 | 0.0.1-SNAPSHOT 30 | 3.1 31 | 2.5.0 32 | 33 | 34 | 35 | 36 | 37 | com.alibaba 38 | dubbo 39 | 40 | 41 | 42 | org.apache.curator 43 | curator-framework 44 | 45 | 46 | 47 | com.github.sgroschupf 48 | zkclient 49 | 50 | 51 | 52 | org.apache.commons 53 | commons-lang3 54 | 55 | 56 | 57 | javax.servlet 58 | javax.servlet-api 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | org.springframework.boot 67 | spring-boot-starter 68 | ${spring.boot.version} 69 | 70 | 71 | 72 | com.alibaba 73 | dubbo 74 | ${dubbo.version} 75 | 76 | 77 | 78 | javax.servlet 79 | javax.servlet-api 80 | ${servlet.version} 81 | 82 | 83 | 84 | com.github.sgroschupf 85 | zkclient 86 | ${zkclient.version} 87 | 88 | 89 | 90 | org.apache.curator 91 | curator-framework 92 | ${curator_version} 93 | 94 | 95 | 96 | com.github.loafer 97 | dubbo-demo-api 98 | ${dubbo.demo.version} 99 | 100 | 101 | 102 | com.github.loafer 103 | dubbo-demo-consumer 104 | ${dubbo.demo.version} 105 | 106 | 107 | 108 | com.github.loafer 109 | dubbo-demo-provider 110 | ${dubbo.demo.version} 111 | 112 | 113 | 114 | org.apache.commons 115 | commons-lang3 116 | ${commons.lang3.version} 117 | 118 | 119 | 120 | 121 | --------------------------------------------------------------------------------