You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@servicecomb.apache.org by ni...@apache.org on 2018/03/26 13:08:22 UTC

[incubator-servicecomb-java-chassis] branch pre-1.0 updated (9240244 -> b60bf88)

This is an automated email from the ASF dual-hosted git repository.

ningjiang pushed a change to branch pre-1.0
in repository https://gitbox.apache.org/repos/asf/incubator-servicecomb-java-chassis.git.


    from 9240244  Excluded the google style file from src release kit
     new c7a4ccc  SCB-431 Clean up the Rat setting and updated the header of RedisSession java
     new 48ce38b  SCB-431 Updated the license header of bmi application.yaml
     new 17ad0d4  SCB-434 fix jaxrs-provider sample dependency
     new b60bf88  SCB-434 add @GET sample code and update readme

The 4 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../apache/servicecomb/demo/perf/RedisSession.java | 13 +++++----
 pom.xml                                            | 11 ++++----
 .../bmi/webapp/src/main/resources/application.yaml | 33 +++++++++++-----------
 samples/jaxrs-sample/README.md                     |  3 +-
 samples/jaxrs-sample/jaxrs-consumer/pom.xml        |  4 +++
 .../samples/jaxrs/consumer/JaxrsConsumerMain.java  |  6 ++++
 samples/jaxrs-sample/jaxrs-provider/pom.xml        |  2 +-
 .../samples/jaxrs/provider/JaxrsHelloImpl.java     |  8 ++++++
 8 files changed, 51 insertions(+), 29 deletions(-)

-- 
To stop receiving notification emails like this one, please contact
ningjiang@apache.org.

[incubator-servicecomb-java-chassis] 01/04: SCB-431 Clean up the Rat setting and updated the header of RedisSession java

Posted by ni...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

ningjiang pushed a commit to branch pre-1.0
in repository https://gitbox.apache.org/repos/asf/incubator-servicecomb-java-chassis.git

commit c7a4ccc2dbe39849af9c531fcf4f44f8c36638e7
Author: Willem Jiang <ji...@huawei.com>
AuthorDate: Mon Mar 26 10:20:59 2018 +0800

    SCB-431 Clean up the Rat setting and updated the header of RedisSession java
---
 .../java/org/apache/servicecomb/demo/perf/RedisSession.java | 13 +++++++------
 pom.xml                                                     | 11 ++++++-----
 2 files changed, 13 insertions(+), 11 deletions(-)

diff --git a/demo/perf/src/main/java/org/apache/servicecomb/demo/perf/RedisSession.java b/demo/perf/src/main/java/org/apache/servicecomb/demo/perf/RedisSession.java
index 5f6b896..f9d657f 100644
--- a/demo/perf/src/main/java/org/apache/servicecomb/demo/perf/RedisSession.java
+++ b/demo/perf/src/main/java/org/apache/servicecomb/demo/perf/RedisSession.java
@@ -1,11 +1,12 @@
 /*
- * Copyright 2017 Huawei Technologies Co., Ltd
+ * 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
  *
- * Licensed 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
+ *     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,
diff --git a/pom.xml b/pom.xml
index 3b57897..9f2710b 100644
--- a/pom.xml
+++ b/pom.xml
@@ -209,15 +209,16 @@
             <exclude>**/*.md</exclude>
             <excldue>**/*.MD</excldue>
             <exclude>**/target/*</exclude>
+            <!-- Skip the code style configuration file -->
+            <exclude>**/etc/eclipse-java-google-style.xml</exclude>
+            <exclude>**/etc/intellij-java-google-style.xml</exclude>
             <!-- Skip the ssl configuration files -->
             <exculde>**/resources/ssl/**</exculde>
-            <!-- Skip the protobuf files -->
-            <exclude>**/*.proto</exclude>
-            <!-- Skip the idl files -->
-            <exclude>**/*.idl</exclude>
+            <!-- SKip the licenses files -->
+            <exclude>**/src/release/licenses/**</exclude>
             <!-- Skip the demo log files -->
             <exclude>**/logs/**.log</exclude>
-            <!-- Skip the source files which are copied from vertx -->
+            <!-- Skip the source files which are forked from vertx -->
             <exclude>**/io/vertx/ext/web/impl/MimeTypesUtils.java</exclude>
             <exclude>**/java/org/apache/servicecomb/transport/rest/vertx/RestBodyHandler.java</exclude>
           </excludes>

-- 
To stop receiving notification emails like this one, please contact
ningjiang@apache.org.

[incubator-servicecomb-java-chassis] 03/04: SCB-434 fix jaxrs-provider sample dependency

Posted by ni...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

ningjiang pushed a commit to branch pre-1.0
in repository https://gitbox.apache.org/repos/asf/incubator-servicecomb-java-chassis.git

commit 17ad0d48a63e57d8aaf9d44e65460586e03ecf78
Author: zhengyangyong <ya...@huawei.com>
AuthorDate: Mon Mar 26 15:55:26 2018 +0800

    SCB-434 fix jaxrs-provider sample dependency
    
    Signed-off-by: zhengyangyong <ya...@huawei.com>
---
 samples/jaxrs-sample/jaxrs-provider/pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/samples/jaxrs-sample/jaxrs-provider/pom.xml b/samples/jaxrs-sample/jaxrs-provider/pom.xml
index 5425903..add653f 100644
--- a/samples/jaxrs-sample/jaxrs-provider/pom.xml
+++ b/samples/jaxrs-sample/jaxrs-provider/pom.xml
@@ -48,7 +48,7 @@
         </dependency>
         <dependency>
             <groupId>org.apache.servicecomb</groupId>
-            <artifactId>provider-rest-common</artifactId>
+            <artifactId>provider-jaxrs</artifactId>
         </dependency>
         <dependency>
             <groupId>org.slf4j</groupId>

-- 
To stop receiving notification emails like this one, please contact
ningjiang@apache.org.

[incubator-servicecomb-java-chassis] 04/04: SCB-434 add @GET sample code and update readme

Posted by ni...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

ningjiang pushed a commit to branch pre-1.0
in repository https://gitbox.apache.org/repos/asf/incubator-servicecomb-java-chassis.git

commit b60bf88c053e9ffa63b671a6639195be5179cf90
Author: zhengyangyong <ya...@huawei.com>
AuthorDate: Mon Mar 26 19:02:34 2018 +0800

    SCB-434 add @GET sample code and update readme
    
    Signed-off-by: zhengyangyong <ya...@huawei.com>
---
 samples/jaxrs-sample/README.md                                    | 3 ++-
 samples/jaxrs-sample/jaxrs-consumer/pom.xml                       | 4 ++++
 .../servicecomb/samples/jaxrs/consumer/JaxrsConsumerMain.java     | 6 ++++++
 .../apache/servicecomb/samples/jaxrs/provider/JaxrsHelloImpl.java | 8 ++++++++
 4 files changed, 20 insertions(+), 1 deletion(-)

diff --git a/samples/jaxrs-sample/README.md b/samples/jaxrs-sample/README.md
index f804277..25dad6c 100644
--- a/samples/jaxrs-sample/README.md
+++ b/samples/jaxrs-sample/README.md
@@ -64,4 +64,5 @@ To consume a provider-service, only need to decalare a member of a service API t
    
    On the consumer side, you can see the following outputs if the consumer can invoke the producer:
    1. *'Hello Java Chassis'* means the consumer calls sayhi by RpcReference successfully
-   2. *'Hello person ServiceComb/Java Chassis'* means the consumer calls sayhello by RpcReference successfully
\ No newline at end of file
+   2. *'Hello person ServiceComb/Java Chassis'* means the consumer calls sayhello by RpcReference successfully
+   3. *'Bye !'* means the consumer calls saybye by RestTemplate successfully
\ No newline at end of file
diff --git a/samples/jaxrs-sample/jaxrs-consumer/pom.xml b/samples/jaxrs-sample/jaxrs-consumer/pom.xml
index ec2a170..efd34c6 100644
--- a/samples/jaxrs-sample/jaxrs-consumer/pom.xml
+++ b/samples/jaxrs-sample/jaxrs-consumer/pom.xml
@@ -51,6 +51,10 @@
             <artifactId>provider-pojo</artifactId>
         </dependency>
         <dependency>
+            <groupId>org.apache.servicecomb</groupId>
+            <artifactId>provider-springmvc</artifactId>
+        </dependency>
+        <dependency>
             <groupId>org.slf4j</groupId>
             <artifactId>slf4j-log4j12</artifactId>
         </dependency>
diff --git a/samples/jaxrs-sample/jaxrs-consumer/src/main/java/org/apache/servicecomb/samples/jaxrs/consumer/JaxrsConsumerMain.java b/samples/jaxrs-sample/jaxrs-consumer/src/main/java/org/apache/servicecomb/samples/jaxrs/consumer/JaxrsConsumerMain.java
index 7fa2ed4..67bcab5 100644
--- a/samples/jaxrs-sample/jaxrs-consumer/src/main/java/org/apache/servicecomb/samples/jaxrs/consumer/JaxrsConsumerMain.java
+++ b/samples/jaxrs-sample/jaxrs-consumer/src/main/java/org/apache/servicecomb/samples/jaxrs/consumer/JaxrsConsumerMain.java
@@ -19,9 +19,11 @@ package org.apache.servicecomb.samples.jaxrs.consumer;
 import org.apache.servicecomb.foundation.common.utils.BeanUtils;
 import org.apache.servicecomb.foundation.common.utils.Log4jUtils;
 import org.apache.servicecomb.provider.pojo.RpcReference;
+import org.apache.servicecomb.provider.springmvc.reference.RestTemplateBuilder;
 import org.apache.servicecomb.samples.common.schema.Hello;
 import org.apache.servicecomb.samples.common.schema.models.Person;
 import org.springframework.stereotype.Component;
+import org.springframework.web.client.RestTemplate;
 
 @Component
 public class JaxrsConsumerMain {
@@ -35,6 +37,10 @@ public class JaxrsConsumerMain {
     Person person = new Person();
     person.setName("ServiceComb/Java Chassis");
     System.out.println(hello.sayHello(person));
+
+    RestTemplate restTemplate = RestTemplateBuilder.create();
+    String result = restTemplate.getForObject("cse://jaxrs/jaxrshello/saybye", String.class);
+    System.out.println(result);
   }
 
   public static void init() throws Exception {
diff --git a/samples/jaxrs-sample/jaxrs-provider/src/main/java/org/apache/servicecomb/samples/jaxrs/provider/JaxrsHelloImpl.java b/samples/jaxrs-sample/jaxrs-provider/src/main/java/org/apache/servicecomb/samples/jaxrs/provider/JaxrsHelloImpl.java
index 3bb0e5a..f2cf332 100644
--- a/samples/jaxrs-sample/jaxrs-provider/src/main/java/org/apache/servicecomb/samples/jaxrs/provider/JaxrsHelloImpl.java
+++ b/samples/jaxrs-sample/jaxrs-provider/src/main/java/org/apache/servicecomb/samples/jaxrs/provider/JaxrsHelloImpl.java
@@ -18,6 +18,7 @@
 package org.apache.servicecomb.samples.jaxrs.provider;
 
 
+import javax.ws.rs.GET;
 import javax.ws.rs.POST;
 import javax.ws.rs.Path;
 import javax.ws.rs.Produces;
@@ -45,4 +46,11 @@ public class JaxrsHelloImpl implements Hello {
   public String sayHello(Person person) {
     return "Hello person " + person.getName();
   }
+
+  @Path("/saybye")
+  @GET
+  public String sayBye() {
+    return "Bye !";
+  }
+
 }

-- 
To stop receiving notification emails like this one, please contact
ningjiang@apache.org.

[incubator-servicecomb-java-chassis] 02/04: SCB-431 Updated the license header of bmi application.yaml

Posted by ni...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

ningjiang pushed a commit to branch pre-1.0
in repository https://gitbox.apache.org/repos/asf/incubator-servicecomb-java-chassis.git

commit 48ce38bad565a03e4e7982af0ad209aa89c96299
Author: Willem Jiang <ji...@huawei.com>
AuthorDate: Mon Mar 26 12:47:17 2018 +0800

    SCB-431 Updated the license header of bmi application.yaml
---
 .../bmi/webapp/src/main/resources/application.yaml | 33 +++++++++++-----------
 1 file changed, 17 insertions(+), 16 deletions(-)

diff --git a/samples/bmi/webapp/src/main/resources/application.yaml b/samples/bmi/webapp/src/main/resources/application.yaml
index a1a82bb..0c901dc 100644
--- a/samples/bmi/webapp/src/main/resources/application.yaml
+++ b/samples/bmi/webapp/src/main/resources/application.yaml
@@ -1,18 +1,19 @@
-#
-#  Copyright 2017 Huawei Technologies Co., Ltd
-#
-#  Licensed 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.
-#
+## ---------------------------------------------------------------------------
+## 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.
+## ---------------------------------------------------------------------------
 
 zuul:
   routes:
@@ -28,4 +29,4 @@ server:
 
 servicecomb:
   tracing:
-    enabled: false
\ No newline at end of file
+    enabled: false

-- 
To stop receiving notification emails like this one, please contact
ningjiang@apache.org.