This is an automated email from the ASF dual-hosted git repository. liujun pushed a commit to branch revert-1083-rest-20240318 in repository https://gitbox.apache.org/repos/asf/dubbo-samples.git
commit 397421c838c2836fb1207278c455d6b3325c5413 Author: Ken Liu <[email protected]> AuthorDate: Tue Mar 19 09:51:24 2024 +0800 Revert "Add triple rest example (#1083)" This reverts commit 0cf89cb4997b742201362b1ea635cc9166af8d96. --- .../dubbo-samples-triple-rest-jaxrs/README.md | 34 ------ .../case-configuration.yml | 45 -------- .../case-versions.conf | 25 ---- .../dubbo-samples-triple-rest-jaxrs/pom.xml | 79 ------------- .../org/apache/dubbo/rest/demo/DemoService.java | 31 ----- .../dubbo/rest/demo/JaxrsRestApplication.java | 31 ----- .../org/apache/dubbo/rest/demo/consumer/Task.java | 47 -------- .../dubbo/rest/demo/provider/DemoServiceImpl.java | 30 ----- .../src/main/resources/application.yml | 26 ----- .../dubbo/rest/demo/test/ConsumerApplication.java | 31 ----- .../apache/dubbo/rest/demo/test/ConsumerIT.java | 55 --------- .../dubbo-samples-triple-rest-springmvc/README.md | 34 ------ .../case-configuration.yml | 45 -------- .../case-versions.conf | 25 ---- .../dubbo-samples-triple-rest-springmvc/pom.xml | 81 ------------- .../org/apache/dubbo/rest/demo/DemoService.java | 30 ----- .../dubbo/rest/demo/SpringmvcRestApplication.java | 31 ----- .../org/apache/dubbo/rest/demo/consumer/Task.java | 47 -------- .../dubbo/rest/demo/provider/DemoServiceImpl.java | 30 ----- .../src/main/resources/application.yml | 26 ----- .../dubbo/rest/demo/test/ConsumerApplication.java | 31 ----- .../apache/dubbo/rest/demo/test/ConsumerIT.java | 57 --------- 2-advanced/dubbo-samples-triple-rest/pom.xml | 127 --------------------- 2-advanced/pom.xml | 2 - .../protocol}/dubbo-samples-dubbo/README.md | 0 .../dubbo-samples-dubbo-consumer/pom.xml | 0 .../dubbo/demo/consumer/ConsumerApplication.java | 0 .../dubbo/protocol/dubbo/demo/consumer/Task.java | 0 .../src/main/resources/application.yml | 0 .../dubbo-samples-dubbo-interface/pom.xml | 0 .../dubbo/protocol/dubbo/demo/DemoService.java | 0 .../dubbo-samples-dubbo-provider/pom.xml | 0 .../dubbo/demo/provider/DemoServiceImpl.java | 0 .../dubbo/demo/provider/ProviderApplication.java | 0 .../src/main/resources/application.yml | 0 .../protocol}/dubbo-samples-dubbo/pom.xml | 0 3-extensions/protocol/pom.xml | 1 + 37 files changed, 1 insertion(+), 1000 deletions(-) diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/README.md b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/README.md deleted file mode 100644 index 71b97068a..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/README.md +++ /dev/null @@ -1,34 +0,0 @@ -# Dubbo Triple Rest JAX-RS Example - -This example shows how to use Spring Web annotation to add rest-style access to triple protocol. - -# How to run - -## Start Zookeeper -This example replies on Zookeeper(3.8.0+) as service discovery registry center, so you need to run the Zookeeper server first, there are two ways to do so: -1. [Download zookeeper binary and start it directly](https://dubbo-next.staged.apache.org/zh-cn/overview/reference/integrations/zookeeper/#本地下载) -2. [Start zookeeper using docker](https://dubbo-next.staged.apache.org/zh-cn/overview/reference/integrations/zookeeper/#docker) - -## Install dependencies -Step into 'dubbo-samples-triple-rest' directory, run the following command: - -```shell -$ mvn clean install -``` - -## Start provider -Step into 'dubbo-samples-triple-rest-jaxrs' directory - -then, run the following command to start application: -```shell -$ mvn compile exec:java -Dexec.mainClass="org.apache.dubbo.rest.demo.JaxrsRestApplication" -``` - -Run the following command to see server works as expected: -```shell -curl \ - --header "Content-Type: application/json" \ - 'http://localhost:50052/demo/hello?name=world' -``` - -Or, you can visit the following link by using web browser: `http://localhost:50052/demo/hello?name=world` diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/case-configuration.yml b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/case-configuration.yml deleted file mode 100644 index 5352a8e45..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/case-configuration.yml +++ /dev/null @@ -1,45 +0,0 @@ -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -services: - zookeeper: - image: zookeeper:latest - - jaxrs-provider: - type: app - basedir: dubbo-samples-triple-rest-jaxrs - mainClass: org.apache.dubbo.rest.demo.SpringmvcRestApplication - systemProps: - - zookeeper.address=zookeeper - waitPortsBeforeRun: - - zookeeper:2181 - checkPorts: - - 50052 - checkLog: "Current Spring Boot Application is await..." - - test: - type: test - basedir: dubbo-samples-triple-rest-jaxrs - tests: - - "**/*IT.class" - systemProps: - - zookeeper.address=zookeeper - - dubbo.address=jaxrs-provider:50052 - waitPortsBeforeRun: - - zookeeper:2181 - - jaxrs-provider:50052 - depends_on: - - jaxrs-provider diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/case-versions.conf b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/case-versions.conf deleted file mode 100644 index b85ce1582..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/case-versions.conf +++ /dev/null @@ -1,25 +0,0 @@ -# -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You under the Apache License, Version 2.0 -# (the "License"); you may not use this file except in compliance with -# the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - - -# Supported component versions of the test case - -# Spring app -dubbo.version=3.3.0.* -spring.version=6.* -java.version= [>= 17] diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/pom.xml b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/pom.xml deleted file mode 100644 index ceae6d947..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/pom.xml +++ /dev/null @@ -1,79 +0,0 @@ -<!-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. - --> -<project xmlns="http://maven.apache.org/POM/4.0.0" - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> - <parent> - <artifactId>dubbo-samples-triple-rest</artifactId> - <groupId>org.apache.dubbo</groupId> - <version>1.0-SNAPSHOT</version> - <relativePath>../pom.xml</relativePath> - </parent> - <modelVersion>4.0.0</modelVersion> - - <artifactId>dubbo-samples-triple-rest-jaxrs</artifactId> - - <dependencies> - <!-- dubbo --> - <dependency> - <groupId>org.apache.dubbo</groupId> - <artifactId>dubbo-spring-boot-starter</artifactId> - </dependency> - <dependency> - <groupId>org.apache.dubbo</groupId> - <artifactId>dubbo-zookeeper-curator5-spring-boot-starter</artifactId> - </dependency> - - <!-- spring web annotation support --> - <dependency> - <groupId>javax.ws.rs</groupId> - <artifactId>javax.ws.rs-api</artifactId> - <version>2.1.1</version> - </dependency> - - <!-- spring boot starter --> - <dependency> - <groupId>org.springframework.boot</groupId> - <artifactId>spring-boot-starter</artifactId> - </dependency> - - <dependency> - <groupId>org.springframework.boot</groupId> - <artifactId>spring-boot-starter-log4j2</artifactId> - </dependency> - - <dependency> - <groupId>org.springframework.boot</groupId> - <artifactId>spring-boot-starter-test</artifactId> - <scope>test</scope> - </dependency> - <dependency> - <groupId>org.springframework</groupId> - <artifactId>spring-web</artifactId> - <scope>test</scope> - </dependency> - </dependencies> - - <build> - <plugins> - <plugin> - <groupId>org.springframework.boot</groupId> - <artifactId>spring-boot-maven-plugin</artifactId> - </plugin> - </plugins> - </build> -</project> diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/main/java/org/apache/dubbo/rest/demo/DemoService.java b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/main/java/org/apache/dubbo/rest/demo/DemoService.java deleted file mode 100644 index c2379472d..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/main/java/org/apache/dubbo/rest/demo/DemoService.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.dubbo.rest.demo; - -import javax.ws.rs.GET; -import javax.ws.rs.Path; -import javax.ws.rs.QueryParam; - -@Path("/demo") -public interface DemoService { - - @GET - @Path("/hello") - String sayHello(@QueryParam("name") String name); - - // add more methods -} diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/main/java/org/apache/dubbo/rest/demo/JaxrsRestApplication.java b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/main/java/org/apache/dubbo/rest/demo/JaxrsRestApplication.java deleted file mode 100644 index a4430cc9d..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/main/java/org/apache/dubbo/rest/demo/JaxrsRestApplication.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package org.apache.dubbo.rest.demo; - - -import org.apache.dubbo.config.spring.context.annotation.EnableDubbo; -import org.springframework.boot.SpringApplication; -import org.springframework.boot.autoconfigure.SpringBootApplication; - -@SpringBootApplication -@EnableDubbo -public class JaxrsRestApplication { - public static void main(String[] args) { - SpringApplication.run(JaxrsRestApplication.class, args); - } -} diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/main/java/org/apache/dubbo/rest/demo/consumer/Task.java b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/main/java/org/apache/dubbo/rest/demo/consumer/Task.java deleted file mode 100644 index e2bffb41d..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/main/java/org/apache/dubbo/rest/demo/consumer/Task.java +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.dubbo.rest.demo.consumer; - -import java.util.Date; - -import org.apache.dubbo.config.annotation.DubboReference; -import org.apache.dubbo.rest.demo.DemoService; -import org.springframework.boot.CommandLineRunner; -import org.springframework.stereotype.Component; - -@Component -public class Task implements CommandLineRunner { - @DubboReference - private DemoService demoService; - - @Override - public void run(String... args) throws Exception { - String result = demoService.sayHello("world"); - System.out.println("Receive result ======> " + result); - - - try { - Thread.sleep(1000); - System.out.println(new Date() + " Receive result ======> " + demoService.sayHello("world")); - } catch (InterruptedException e) { - e.printStackTrace(); - Thread.currentThread().interrupt(); - } - - - } -} diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/main/java/org/apache/dubbo/rest/demo/provider/DemoServiceImpl.java b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/main/java/org/apache/dubbo/rest/demo/provider/DemoServiceImpl.java deleted file mode 100644 index d90361577..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/main/java/org/apache/dubbo/rest/demo/provider/DemoServiceImpl.java +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.dubbo.rest.demo.provider; - -import org.apache.dubbo.config.annotation.DubboService; -import org.apache.dubbo.rest.demo.DemoService; - -@DubboService -public class DemoServiceImpl implements DemoService { - - @Override - public String sayHello(String name) { - return "Hello " + name; - } - -} diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/main/resources/application.yml b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/main/resources/application.yml deleted file mode 100644 index b10439d00..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/main/resources/application.yml +++ /dev/null @@ -1,26 +0,0 @@ -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -server: - port: 8081 -dubbo: - application: - name: dubbo-springboot-triple-rest-jaxrs - qos-port: 33333 - registry: - address: zookeeper://${zookeeper.address:127.0.0.1}:2181 - protocol: - name: tri - port: 50052 diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/test/java/org/apache/dubbo/rest/demo/test/ConsumerApplication.java b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/test/java/org/apache/dubbo/rest/demo/test/ConsumerApplication.java deleted file mode 100644 index 1a58d8415..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/test/java/org/apache/dubbo/rest/demo/test/ConsumerApplication.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package org.apache.dubbo.rest.demo.test; - -import org.apache.dubbo.config.spring.context.annotation.EnableDubbo; -import org.springframework.boot.SpringApplication; -import org.springframework.boot.autoconfigure.SpringBootApplication; - -@SpringBootApplication -@EnableDubbo -public class ConsumerApplication { - - public static void main(String[] args) { - SpringApplication.run(ConsumerApplication.class, args); - } -} diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/test/java/org/apache/dubbo/rest/demo/test/ConsumerIT.java b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/test/java/org/apache/dubbo/rest/demo/test/ConsumerIT.java deleted file mode 100644 index 1dcff3c0b..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-jaxrs/src/test/java/org/apache/dubbo/rest/demo/test/ConsumerIT.java +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.dubbo.rest.demo.test; - -import org.apache.dubbo.config.annotation.DubboReference; -import org.apache.dubbo.rest.demo.DemoService; -import org.junit.Assert; -import org.junit.Test; -import org.junit.runner.RunWith; -import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.http.ResponseEntity; -import org.springframework.test.context.junit4.SpringRunner; -import org.springframework.web.client.RestClient; - -@SpringBootTest -@RunWith(SpringRunner.class) -public class ConsumerIT { - - private static final String providerAddress = System.getProperty("dubbo.address", "localhost"); - - @DubboReference - private DemoService demoService; - - @Test - public void test() { - String result = demoService.sayHello("world"); - Assert.assertEquals("Hello world", result); - } - - @Test - public void testRest() { - RestClient defaultClient = RestClient.create(); - ResponseEntity<String> result = defaultClient.get() - .uri("http://" + providerAddress + ":50052/demo/hello?name=world") - .header("Content-type", "application/json") - .retrieve() - .toEntity(String.class); - // FIXME - Assert.assertEquals("\"Hello world\"", result.getBody()); - } -} diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/README.md b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/README.md deleted file mode 100644 index bec255d29..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/README.md +++ /dev/null @@ -1,34 +0,0 @@ -# Dubbo Triple Rest Spring Web Example - -This example shows how to use Spring Web annotation to add rest-style access to triple protocol. - -# How to run - -## Start Zookeeper -This example replies on Zookeeper(3.8.0+) as service discovery registry center, so you need to run the Zookeeper server first, there are two ways to do so: -1. [Download zookeeper binary and start it directly](https://dubbo-next.staged.apache.org/zh-cn/overview/reference/integrations/zookeeper/#本地下载) -2. [Start zookeeper using docker](https://dubbo-next.staged.apache.org/zh-cn/overview/reference/integrations/zookeeper/#docker) - -## Install dependencies -Step into 'dubbo-samples-triple-rest' directory, run the following command: - -```shell -$ mvn clean install -``` - -## Start provider -Step into 'dubbo-samples-triple-rest-springmvc' directory - -then, run the following command to start application: -```shell -$ mvn compile exec:java -Dexec.mainClass="org.apache.dubbo.rest.demo.SpringmvcRestApplication" -``` - -Run the following command to see server works as expected: -```shell -curl \ - --header "Content-Type: application/json" \ - 'http://localhost:50052/demo/hello?name=world' -``` - -Or, you can visit the following link by using web browser: `http://localhost:50052/demo/hello?name=world` diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/case-configuration.yml b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/case-configuration.yml deleted file mode 100644 index 34ff633e2..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/case-configuration.yml +++ /dev/null @@ -1,45 +0,0 @@ -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -services: - zookeeper: - image: zookeeper:latest - - springmvc-provider: - type: app - basedir: dubbo-samples-triple-rest-springmvc - mainClass: org.apache.dubbo.rest.demo.SpringmvcRestApplication - systemProps: - - zookeeper.address=zookeeper - waitPortsBeforeRun: - - zookeeper:2181 - checkPorts: - - 50052 - checkLog: "Current Spring Boot Application is await..." - - test: - type: test - basedir: dubbo-samples-triple-rest-springmvc - tests: - - "**/*IT.class" - systemProps: - - zookeeper.address=zookeeper - - dubbo.address=springmvc-provider - waitPortsBeforeRun: - - zookeeper:2181 - - springmvc-provider:50052 - depends_on: - - springmvc-provider diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/case-versions.conf b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/case-versions.conf deleted file mode 100644 index b85ce1582..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/case-versions.conf +++ /dev/null @@ -1,25 +0,0 @@ -# -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. -# The ASF licenses this file to You under the Apache License, Version 2.0 -# (the "License"); you may not use this file except in compliance with -# the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - - -# Supported component versions of the test case - -# Spring app -dubbo.version=3.3.0.* -spring.version=6.* -java.version= [>= 17] diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/pom.xml b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/pom.xml deleted file mode 100644 index 21eb16029..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/pom.xml +++ /dev/null @@ -1,81 +0,0 @@ -<!-- - Licensed to the Apache Software Foundation (ASF) under one or more - contributor license agreements. See the NOTICE file distributed with - this work for additional information regarding copyright ownership. - The ASF licenses this file to You under the Apache License, Version 2.0 - (the "License"); you may not use this file except in compliance with - the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, software - distributed under the License is distributed on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - See the License for the specific language governing permissions and - limitations under the License. - --> -<project xmlns="http://maven.apache.org/POM/4.0.0" - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> - <parent> - <artifactId>dubbo-samples-triple-rest</artifactId> - <groupId>org.apache.dubbo</groupId> - <version>1.0-SNAPSHOT</version> - <relativePath>../pom.xml</relativePath> - </parent> - <modelVersion>4.0.0</modelVersion> - - <artifactId>dubbo-samples-triple-rest-springmvc</artifactId> - - <dependencies> - <!-- dubbo --> - <dependency> - <groupId>org.apache.dubbo</groupId> - <artifactId>dubbo-spring-boot-starter</artifactId> - </dependency> - <dependency> - <groupId>org.apache.dubbo</groupId> - <artifactId>dubbo-zookeeper-curator5-spring-boot-starter</artifactId> - </dependency> - - <!-- spring web annotation support --> - <dependency> - <groupId>org.springframework</groupId> - <artifactId>spring-context</artifactId> - </dependency> - <dependency> - <groupId>org.springframework</groupId> - <artifactId>spring-web</artifactId> - </dependency> - <dependency> - <groupId>com.alibaba.spring</groupId> - <artifactId>spring-context-support</artifactId> - </dependency> - - <!-- spring boot starter --> - <dependency> - <groupId>org.springframework.boot</groupId> - <artifactId>spring-boot-starter</artifactId> - </dependency> - - <dependency> - <groupId>org.springframework.boot</groupId> - <artifactId>spring-boot-starter-log4j2</artifactId> - </dependency> - - <dependency> - <groupId>org.springframework.boot</groupId> - <artifactId>spring-boot-starter-test</artifactId> - <scope>test</scope> - </dependency> - </dependencies> - - <build> - <plugins> - <plugin> - <groupId>org.springframework.boot</groupId> - <artifactId>spring-boot-maven-plugin</artifactId> - </plugin> - </plugins> - </build> -</project> diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/main/java/org/apache/dubbo/rest/demo/DemoService.java b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/main/java/org/apache/dubbo/rest/demo/DemoService.java deleted file mode 100644 index ee849e9c2..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/main/java/org/apache/dubbo/rest/demo/DemoService.java +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.dubbo.rest.demo; - -import org.springframework.web.bind.annotation.RequestMapping; -import org.springframework.web.bind.annotation.RequestMethod; -import org.springframework.web.bind.annotation.RequestParam; - -@RequestMapping("/demo") -public interface DemoService { - - @RequestMapping(method = RequestMethod.GET, value = "/hello") - String sayHello(@RequestParam("name") String name); - - // add more methods -} diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/main/java/org/apache/dubbo/rest/demo/SpringmvcRestApplication.java b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/main/java/org/apache/dubbo/rest/demo/SpringmvcRestApplication.java deleted file mode 100644 index 154f569d5..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/main/java/org/apache/dubbo/rest/demo/SpringmvcRestApplication.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package org.apache.dubbo.rest.demo; - - -import org.apache.dubbo.config.spring.context.annotation.EnableDubbo; -import org.springframework.boot.SpringApplication; -import org.springframework.boot.autoconfigure.SpringBootApplication; - -@SpringBootApplication -@EnableDubbo -public class SpringmvcRestApplication { - public static void main(String[] args) { - SpringApplication.run(SpringmvcRestApplication.class, args); - } -} diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/main/java/org/apache/dubbo/rest/demo/consumer/Task.java b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/main/java/org/apache/dubbo/rest/demo/consumer/Task.java deleted file mode 100644 index e2bffb41d..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/main/java/org/apache/dubbo/rest/demo/consumer/Task.java +++ /dev/null @@ -1,47 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.dubbo.rest.demo.consumer; - -import java.util.Date; - -import org.apache.dubbo.config.annotation.DubboReference; -import org.apache.dubbo.rest.demo.DemoService; -import org.springframework.boot.CommandLineRunner; -import org.springframework.stereotype.Component; - -@Component -public class Task implements CommandLineRunner { - @DubboReference - private DemoService demoService; - - @Override - public void run(String... args) throws Exception { - String result = demoService.sayHello("world"); - System.out.println("Receive result ======> " + result); - - - try { - Thread.sleep(1000); - System.out.println(new Date() + " Receive result ======> " + demoService.sayHello("world")); - } catch (InterruptedException e) { - e.printStackTrace(); - Thread.currentThread().interrupt(); - } - - - } -} diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/main/java/org/apache/dubbo/rest/demo/provider/DemoServiceImpl.java b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/main/java/org/apache/dubbo/rest/demo/provider/DemoServiceImpl.java deleted file mode 100644 index d90361577..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/main/java/org/apache/dubbo/rest/demo/provider/DemoServiceImpl.java +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.dubbo.rest.demo.provider; - -import org.apache.dubbo.config.annotation.DubboService; -import org.apache.dubbo.rest.demo.DemoService; - -@DubboService -public class DemoServiceImpl implements DemoService { - - @Override - public String sayHello(String name) { - return "Hello " + name; - } - -} diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/main/resources/application.yml b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/main/resources/application.yml deleted file mode 100644 index 47b28603a..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/main/resources/application.yml +++ /dev/null @@ -1,26 +0,0 @@ -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -server: - port: 8081 -dubbo: - application: - name: dubbo-springboot-triple-rest-springmvc - qos-port: 33333 - registry: - address: zookeeper://${zookeeper.address:127.0.0.1}:2181 - protocol: - name: tri - port: 50052 diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/test/java/org/apache/dubbo/rest/demo/test/ConsumerApplication.java b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/test/java/org/apache/dubbo/rest/demo/test/ConsumerApplication.java deleted file mode 100644 index 1a58d8415..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/test/java/org/apache/dubbo/rest/demo/test/ConsumerApplication.java +++ /dev/null @@ -1,31 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package org.apache.dubbo.rest.demo.test; - -import org.apache.dubbo.config.spring.context.annotation.EnableDubbo; -import org.springframework.boot.SpringApplication; -import org.springframework.boot.autoconfigure.SpringBootApplication; - -@SpringBootApplication -@EnableDubbo -public class ConsumerApplication { - - public static void main(String[] args) { - SpringApplication.run(ConsumerApplication.class, args); - } -} diff --git a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/test/java/org/apache/dubbo/rest/demo/test/ConsumerIT.java b/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/test/java/org/apache/dubbo/rest/demo/test/ConsumerIT.java deleted file mode 100644 index 38646cabc..000000000 --- a/2-advanced/dubbo-samples-triple-rest/dubbo-samples-triple-rest-springmvc/src/test/java/org/apache/dubbo/rest/demo/test/ConsumerIT.java +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package org.apache.dubbo.rest.demo.test; - -import org.apache.dubbo.config.annotation.DubboReference; -import org.apache.dubbo.rest.demo.DemoService; -import org.junit.Assert; -import org.junit.Test; -import org.junit.runner.RunWith; -import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.http.ResponseEntity; -import org.springframework.test.context.junit4.SpringRunner; -import org.springframework.web.client.RestClient; -import org.springframework.web.client.RestTemplate; - -import static org.springframework.http.MediaType.APPLICATION_JSON; - -@SpringBootTest -@RunWith(SpringRunner.class) -public class ConsumerIT { - private static final String providerAddress = System.getProperty("dubbo.address", "localhost"); - - @DubboReference - private DemoService demoService; - - @Test - public void test() { - String result = demoService.sayHello("world"); - Assert.assertEquals("Hello world", result); - } - - @Test - public void testRest() { - RestClient defaultClient = RestClient.create(); - ResponseEntity<String> result = defaultClient.get() - .uri("http://" + providerAddress + ":50052/demo/hello?name=world") - .header("Content-type", "application/json") - .retrieve() - .toEntity(String.class); - // FIXME - Assert.assertEquals("\"Hello world\"", result.getBody()); - } -} diff --git a/2-advanced/dubbo-samples-triple-rest/pom.xml b/2-advanced/dubbo-samples-triple-rest/pom.xml deleted file mode 100644 index 98c04a3ec..000000000 --- a/2-advanced/dubbo-samples-triple-rest/pom.xml +++ /dev/null @@ -1,127 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<!-- - ~ Licensed to the Apache Software Foundation (ASF) under one or more - ~ contributor license agreements. See the NOTICE file distributed with - ~ this work for additional information regarding copyright ownership. - ~ The ASF licenses this file to You under the Apache License, Version 2.0 - ~ (the "License"); you may not use this file except in compliance with - ~ the License. You may obtain a copy of the License at - ~ - ~ http://www.apache.org/licenses/LICENSE-2.0 - ~ - ~ Unless required by applicable law or agreed to in writing, software - ~ distributed under the License is distributed on an "AS IS" BASIS, - ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - ~ See the License for the specific language governing permissions and - ~ limitations under the License. - --> - -<project xmlns="http://maven.apache.org/POM/4.0.0" - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> - <parent> - <groupId>org.apache</groupId> - <artifactId>apache</artifactId> - <version>31</version> - <relativePath/> - </parent> - <modelVersion>4.0.0</modelVersion> - - <groupId>org.apache.dubbo</groupId> - <artifactId>dubbo-samples-triple-rest</artifactId> - <version>1.0-SNAPSHOT</version> - <packaging>pom</packaging> - - <name>Dubbo Samples Triple Rest</name> - <description>Dubbo Samples Triple Rest</description> - - <properties> - <maven.compiler.source>17</maven.compiler.source> - <maven.compiler.target>17</maven.compiler.target> - <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> - - <dubbo.version>3.3.0-beta.2-SNAPSHOT</dubbo.version> - <spring-boot.version>3.2.3</spring-boot.version> - <spring.version>6.1.5</spring.version> - </properties> - - <modules> - <module>dubbo-samples-triple-rest-springmvc</module> - <module>dubbo-samples-triple-rest-jaxrs</module> - </modules> - - <dependencyManagement> - <dependencies> - <dependency> - <groupId>org.springframework</groupId> - <artifactId>spring-framework-bom</artifactId> - <version>${spring.version}</version> - <type>pom</type> - <scope>import</scope> - </dependency> - <dependency> - <groupId>org.springframework.boot</groupId> - <artifactId>spring-boot-dependencies</artifactId> - <version>${spring-boot.version}</version> - <type>pom</type> - <scope>import</scope> - </dependency> - <dependency> - <groupId>org.springframework.boot</groupId> - <artifactId>spring-boot-starter</artifactId> - <version>${spring-boot.version}</version> - <exclusions> - <exclusion> - <artifactId>spring-boot-starter-logging</artifactId> - <groupId>org.springframework.boot</groupId> - </exclusion> - </exclusions> - </dependency> - <dependency> - <groupId>org.apache.dubbo</groupId> - <artifactId>dubbo-bom</artifactId> - <version>${dubbo.version}</version> - <type>pom</type> - <scope>import</scope> - </dependency> - </dependencies> - </dependencyManagement> - - <dependencies> - <dependency> - <groupId>junit</groupId> - <artifactId>junit</artifactId> - <scope>test</scope> - </dependency> - </dependencies> - - <build> - <plugins> - <plugin> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-compiler-plugin</artifactId> - <configuration> - <compilerArgs> - <compilerArg>-proc:none</compilerArg> - </compilerArgs> - </configuration> - </plugin> - </plugins> - <pluginManagement> - <plugins> - <plugin> - <groupId>org.springframework.boot</groupId> - <artifactId>spring-boot-maven-plugin</artifactId> - <version>${spring-boot.version}</version> - <executions> - <execution> - <goals> - <goal>repackage</goal> - </goals> - </execution> - </executions> - </plugin> - </plugins> - </pluginManagement> - </build> -</project> diff --git a/2-advanced/pom.xml b/2-advanced/pom.xml index cdd0c993a..80b20ae46 100644 --- a/2-advanced/pom.xml +++ b/2-advanced/pom.xml @@ -65,7 +65,5 @@ <module>dubbo-samples-annotation</module> <module>dubbo-samples-spring-xml</module> <module>dubbo-samples-api-with-registry</module> - <module>dubbo-samples-dubbo</module> - <module>dubbo-samples-triple-rest</module> </modules> </project> diff --git a/2-advanced/dubbo-samples-dubbo/README.md b/3-extensions/protocol/dubbo-samples-dubbo/README.md similarity index 100% rename from 2-advanced/dubbo-samples-dubbo/README.md rename to 3-extensions/protocol/dubbo-samples-dubbo/README.md diff --git a/2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-consumer/pom.xml b/3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-consumer/pom.xml similarity index 100% rename from 2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-consumer/pom.xml rename to 3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-consumer/pom.xml diff --git a/2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-consumer/src/main/java/org/apache/dubbo/protocol/dubbo/demo/consumer/ConsumerApplication.java b/3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-consumer/src/main/java/org/apache/dubbo/protocol/dubbo/demo/consumer/ConsumerApplication.java similarity index 100% rename from 2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-consumer/src/main/java/org/apache/dubbo/protocol/dubbo/demo/consumer/ConsumerApplication.java rename to 3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-consumer/src/main/java/org/apache/dubbo/protocol/dubbo/demo/consumer/ConsumerApplication.java diff --git a/2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-consumer/src/main/java/org/apache/dubbo/protocol/dubbo/demo/consumer/Task.java b/3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-consumer/src/main/java/org/apache/dubbo/protocol/dubbo/demo/consumer/Task.java similarity index 100% rename from 2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-consumer/src/main/java/org/apache/dubbo/protocol/dubbo/demo/consumer/Task.java rename to 3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-consumer/src/main/java/org/apache/dubbo/protocol/dubbo/demo/consumer/Task.java diff --git a/2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-consumer/src/main/resources/application.yml b/3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-consumer/src/main/resources/application.yml similarity index 100% rename from 2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-consumer/src/main/resources/application.yml rename to 3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-consumer/src/main/resources/application.yml diff --git a/2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-interface/pom.xml b/3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-interface/pom.xml similarity index 100% rename from 2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-interface/pom.xml rename to 3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-interface/pom.xml diff --git a/2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-interface/src/main/java/org/apache/dubbo/protocol/dubbo/demo/DemoService.java b/3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-interface/src/main/java/org/apache/dubbo/protocol/dubbo/demo/DemoService.java similarity index 100% rename from 2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-interface/src/main/java/org/apache/dubbo/protocol/dubbo/demo/DemoService.java rename to 3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-interface/src/main/java/org/apache/dubbo/protocol/dubbo/demo/DemoService.java diff --git a/2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-provider/pom.xml b/3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-provider/pom.xml similarity index 100% rename from 2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-provider/pom.xml rename to 3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-provider/pom.xml diff --git a/2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-provider/src/main/java/org/apache/dubbo/protocol/dubbo/demo/provider/DemoServiceImpl.java b/3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-provider/src/main/java/org/apache/dubbo/protocol/dubbo/demo/provider/DemoServiceImpl.java similarity index 100% rename from 2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-provider/src/main/java/org/apache/dubbo/protocol/dubbo/demo/provider/DemoServiceImpl.java rename to 3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-provider/src/main/java/org/apache/dubbo/protocol/dubbo/demo/provider/DemoServiceImpl.java diff --git a/2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-provider/src/main/java/org/apache/dubbo/protocol/dubbo/demo/provider/ProviderApplication.java b/3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-provider/src/main/java/org/apache/dubbo/protocol/dubbo/demo/provider/ProviderApplication.java similarity index 100% rename from 2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-provider/src/main/java/org/apache/dubbo/protocol/dubbo/demo/provider/ProviderApplication.java rename to 3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-provider/src/main/java/org/apache/dubbo/protocol/dubbo/demo/provider/ProviderApplication.java diff --git a/2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-provider/src/main/resources/application.yml b/3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-provider/src/main/resources/application.yml similarity index 100% rename from 2-advanced/dubbo-samples-dubbo/dubbo-samples-dubbo-provider/src/main/resources/application.yml rename to 3-extensions/protocol/dubbo-samples-dubbo/dubbo-samples-dubbo-provider/src/main/resources/application.yml diff --git a/2-advanced/dubbo-samples-dubbo/pom.xml b/3-extensions/protocol/dubbo-samples-dubbo/pom.xml similarity index 100% rename from 2-advanced/dubbo-samples-dubbo/pom.xml rename to 3-extensions/protocol/dubbo-samples-dubbo/pom.xml diff --git a/3-extensions/protocol/pom.xml b/3-extensions/protocol/pom.xml index 55a951fd0..fb6e4e37a 100644 --- a/3-extensions/protocol/pom.xml +++ b/3-extensions/protocol/pom.xml @@ -27,6 +27,7 @@ <description>Dubbo Protocol Samples</description> <modules> + <module>dubbo-samples-dubbo</module> <module>dubbo-samples-http</module> <module>dubbo-samples-jetty</module> <module>dubbo-samples-port-unification</module> --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
