[GitHub] [servicecomb-service-center] DFSOrange commented on pull request #765: SCB-2094 the mongo collections should not be fixed

2020-11-26 Thread GitBox


DFSOrange commented on pull request #765:
URL: 
https://github.com/apache/servicecomb-service-center/pull/765#issuecomment-734690958


   @little-cui 



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] tianxiaoliang commented on a change in pull request #755: Incremental synchronization of sc: sync between sc and syncer

2020-11-26 Thread GitBox


tianxiaoliang commented on a change in pull request #755:
URL: 
https://github.com/apache/servicecomb-service-center/pull/755#discussion_r531423076



##
File path: syncer/server/server.go
##
@@ -253,3 +266,34 @@ func (s *Server) configureCluster() error {
 
return s.etcd.AddOptions(ops...)
 }
+func (s *Server) watchInstance() error {
+   cli := client.NewWatchClient(s.conf.Registry.Address)
+
+   err := cli.WatchInstances(s.addToQueue)
+
+   if err != nil {
+   return err
+   }
+
+   cli.WatchInstanceHeartbeat(s.addToQueue)
+
+   return nil
+}
+
+func (s *Server) addToQueue(event *dump.WatchInstanceChangedEvent) {
+   mapping := s.servicecenter.GetSyncMapping()
+   for _, m := range mapping {
+   if event.Instance.Value.InstanceId == m.CurInstanceID {

Review comment:
   能否看看卫语句是否能把嵌套简化





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] GuoYL123 opened a new pull request #766: [SCD-2133] governance northbound Interface / abstract access layer

2020-11-26 Thread GitBox


GuoYL123 opened a new pull request #766:
URL: https://github.com/apache/servicecomb-service-center/pull/766


   Follow this checklist to help us incorporate your contribution quickly and 
easily:
   
- [ ] Make sure there is a [JIRA 
issue](https://issues.apache.org/jira/browse/SCB) filed for the change (usually 
before you start working on it).  Trivial changes like typos do not require a 
JIRA issue.  Your pull request should address just this issue, without pulling 
in other changes.
- [ ] Each commit in the pull request should have a meaningful subject line 
and body.
- [ ] Format the pull request title like `[SCB-XXX] Fixes bug in 
ApproximateQuantiles`, where you replace `SCB-XXX` with the appropriate JIRA 
issue.
- [ ] Write a pull request description that is detailed enough to 
understand what the pull request does, how, and why.
- [ ] Run `go build` `go test` `go fmt` `go vet` to make sure basic checks 
pass. A more thorough check will be performed on your pull request 
automatically.
- [ ] If this contribution is large, please file an Apache [Individual 
Contributor License Agreement](https://www.apache.org/licenses/icla.pdf).
   
   ---
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] tianxiaoliang commented on a change in pull request #755: Incremental synchronization of sc: sync between sc and syncer

2020-11-26 Thread GitBox


tianxiaoliang commented on a change in pull request #755:
URL: 
https://github.com/apache/servicecomb-service-center/pull/755#discussion_r531421824



##
File path: server/rest/syncer/syncer_controller.go
##
@@ -0,0 +1,47 @@
+/*
+ * 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 syncer
+
+import (
+   "github.com/apache/servicecomb-service-center/pkg/log"
+   "github.com/apache/servicecomb-service-center/server/config"
+   "net/http"
+
+   "github.com/apache/servicecomb-service-center/pkg/rest"
+)
+
+// Syncer 有关的接口
+type SyncerController struct {
+}
+
+// URLPatterns 路由
+func (ctrl *SyncerController) URLPatterns() []rest.Route {
+   return []rest.Route{
+   {Method: http.MethodGet, Path: "/v4/:project/syncer/watch", 
Func: ctrl.WatchInstance},
+   }
+}
+
+func (ctrl *SyncerController) WatchInstance(w http.ResponseWriter, r 
*http.Request) {
+   syncerEnabled := config.GetBool("syncer.enabled", false)
+   if syncerEnabled {
+   ServiceAPI.WatchInstance(w, r)
+   } else {
+   log.Warnf("syncer cannot watch instance because the config 
syncer.enabled is false, ")

Review comment:
   参考RBAC实现,既然没有开启,就别注册这个router





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] tianxiaoliang commented on pull request #755: Incremental synchronization of sc: sync between sc and syncer

2020-11-26 Thread GitBox


tianxiaoliang commented on pull request #755:
URL: 
https://github.com/apache/servicecomb-service-center/pull/755#issuecomment-734687049


   修改的点resolve,没改的comment为何不需要改



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] tianxiaoliang commented on a change in pull request #755: Incremental synchronization of sc: sync between sc and syncer

2020-11-26 Thread GitBox


tianxiaoliang commented on a change in pull request #755:
URL: 
https://github.com/apache/servicecomb-service-center/pull/755#discussion_r531420804



##
File path: server/rest/syncer/syncer_controller.go
##
@@ -0,0 +1,47 @@
+/*
+ * 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 syncer
+
+import (
+   "github.com/apache/servicecomb-service-center/pkg/log"
+   "github.com/apache/servicecomb-service-center/server/config"
+   "net/http"
+
+   "github.com/apache/servicecomb-service-center/pkg/rest"
+)
+
+// Syncer 有关的接口
+type SyncerController struct {
+}
+
+// URLPatterns 路由
+func (ctrl *SyncerController) URLPatterns() []rest.Route {
+   return []rest.Route{
+   {Method: http.MethodGet, Path: "/v4/:project/syncer/watch", 
Func: ctrl.WatchInstance},

Review comment:
   既然project没在用,就把project干掉,因为这明显是全局接口





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] DFSOrange opened a new pull request #765: SCB-2094 the mongo collections should not be fixed

2020-11-26 Thread GitBox


DFSOrange opened a new pull request #765:
URL: https://github.com/apache/servicecomb-service-center/pull/765


   1. remove mongo collections init operation
   2. change docexist from count to findone
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] yuzhouzhouba edited a comment on issue #2072: 您好,在传递大文件的时候,遇到的网络延时问题

2020-11-26 Thread GitBox


yuzhouzhouba edited a comment on issue #2072:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2072#issuecomment-734685132


   我理解应该是每次读一点(1M),然后就返回,所以读文件流读第一个1M就应该返回,那么就应该很快
   
   demo如何准备那种带文件的? 其实我的代码就是这样(Spring boot 集成的 service Comb)
   
   Resource resource = new InputStreamResource(ret.getObjectContent()); // 
这个就是一个比较大的文件流
   
return ResponseEntity.ok()
   
.contentType(org.springframework.http.MediaType.parseMediaType(contentType))
   .header(HttpHeaders.CONTENT_DISPOSITION, "attachment; 
filename=\"" + ret.getObjectKey() + "\"")
   .body(resource);
   
   当调用这个的时候,我期待是立马返回,但是实际了隔了比较久的时间才返回。(用浏览器或者postman都有这种问题)



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] yuzhouzhouba edited a comment on issue #2072: 您好,在传递大文件的时候,遇到的网络延时问题

2020-11-26 Thread GitBox


yuzhouzhouba edited a comment on issue #2072:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2072#issuecomment-734685132


   我理解应该是每次读一点(1M),然后就返回,所以读文件流读第一个1M就应该返回,那么就应该很快
   
   demo如何准备那种带文件的? 其实我的代码就是这样
   
   Resource resource = new InputStreamResource(ret.getObjectContent()); // 
这个就是一个比较大的文件流
   
return ResponseEntity.ok()
   
.contentType(org.springframework.http.MediaType.parseMediaType(contentType))
   .header(HttpHeaders.CONTENT_DISPOSITION, "attachment; 
filename=\"" + ret.getObjectKey() + "\"")
   .body(resource);
   
   当调用这个的时候,我期待是立马返回,但是实际了隔了比较久的时间才返回。(用浏览器或者postman都有这种问题)



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] yuzhouzhouba commented on issue #2072: 您好,在传递大文件的时候,遇到的网络延时问题

2020-11-26 Thread GitBox


yuzhouzhouba commented on issue #2072:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2072#issuecomment-734685132


   
   我理解应该是每次读一点(1M),然后就返回,所以第一个就读了1M就应该返回,那么就应该很快
   
   demo如何准备那种带文件的? 其实我的代码就是这样
   
   Resource resource = new InputStreamResource(ret.getObjectContent()); // 
这个就是一个比较大的文件流
   
return ResponseEntity.ok()
   
.contentType(org.springframework.http.MediaType.parseMediaType(contentType))
   .header(HttpHeaders.CONTENT_DISPOSITION, "attachment; 
filename=\"" + ret.getObjectKey() + "\"")
   .body(resource);
   
   当调用这个的时候,我期待是立马返回,但是实际了隔了比较久的时间才返回。(用浏览器或者postman都有这种问题)



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] yuzhouzhouba edited a comment on issue #2072: 您好,在传递大文件的时候,遇到的网络延时问题

2020-11-26 Thread GitBox


yuzhouzhouba edited a comment on issue #2072:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2072#issuecomment-734685132


   我理解应该是每次读一点(1M),然后就返回,所以第一个就读了1M就应该返回,那么就应该很快
   
   demo如何准备那种带文件的? 其实我的代码就是这样
   
   Resource resource = new InputStreamResource(ret.getObjectContent()); // 
这个就是一个比较大的文件流
   
return ResponseEntity.ok()
   
.contentType(org.springframework.http.MediaType.parseMediaType(contentType))
   .header(HttpHeaders.CONTENT_DISPOSITION, "attachment; 
filename=\"" + ret.getObjectKey() + "\"")
   .body(resource);
   
   当调用这个的时候,我期待是立马返回,但是实际了隔了比较久的时间才返回。(用浏览器或者postman都有这种问题)



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] luozuyi commented on issue #2071: 碰到一个问题后端接口在一分钟没有返回的时候出现Error: socket hang up

2020-11-26 Thread GitBox


luozuyi commented on issue #2071:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2071#issuecomment-734678385


   > 你要返回一个流, 后台开启一个任务(线程),从数据库读取数据,将数据写到流里面去。 相当于你读的过程就一直在写,这样浏览器不会超时。 
我给你发的例子里面就是使用 PipedStream 实现了这种处理。
   
   
![image](https://user-images.githubusercontent.com/29859621/100420093-c7ddfb80-30c0-11eb-8d5d-5580e173bd9c.png)
   
![image](https://user-images.githubusercontent.com/29859621/100420144-e04e1600-30c0-11eb-94b9-1b6aa2db4357.png)
   例子里面还是一样在一分钟的时候socket hand up



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-docs] liubao68 merged pull request #208: [SCB-2073]create documents to integrate logger for java-chassis

2020-11-26 Thread GitBox


liubao68 merged pull request #208:
URL: https://github.com/apache/servicecomb-docs/pull/208


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[servicecomb-docs] branch master updated: [SCB-2073]create documents to integrate logger for java-chassis (#208)

2020-11-26 Thread liubao
This is an automated email from the ASF dual-hosted git repository.

liubao pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/servicecomb-docs.git


The following commit(s) were added to refs/heads/master by this push:
 new f5b6729  [SCB-2073]create documents to integrate logger for 
java-chassis (#208)
f5b6729 is described below

commit f5b67296e722ea0c4d65b67cf3e8b86ec1717747
Author: bao liu 
AuthorDate: Fri Nov 27 14:58:01 2020 +0800

[SCB-2073]create documents to integrate logger for java-chassis (#208)
---
 .../docs/build-consumer/using-AsyncRestTemplate.md |  2 +-
 .../en_US/docs/catalog/build-consumer.md   |  2 +-
 java-chassis-reference/en_US/mkdocs.yml|  2 +-
 .../zh_CN/docs/build-consumer/catalog.md   |  2 +-
 .../docs/build-consumer/using-AsyncRestTemplate.md | 20 ++-
 .../zh_CN/docs/catalog/build-consumer.md   |  2 +-
 .../zh_CN/docs/general-development/CORS.md |  2 +-
 .../zh_CN/docs/general-development/catalog.md  |  5 ++-
 .../zh_CN/docs/general-development/config-logs.md  | 41 ++
 java-chassis-reference/zh_CN/docs/toc.md   |  5 +--
 10 files changed, 71 insertions(+), 12 deletions(-)

diff --git 
a/java-chassis-reference/en_US/docs/build-consumer/using-AsyncRestTemplate.md 
b/java-chassis-reference/en_US/docs/build-consumer/using-AsyncRestTemplate.md
index 3f42da5..1c5676a 100644
--- 
a/java-chassis-reference/en_US/docs/build-consumer/using-AsyncRestTemplate.md
+++ 
b/java-chassis-reference/en_US/docs/build-consumer/using-AsyncRestTemplate.md
@@ -1,4 +1,4 @@
-# Develop consumer with AsynRestTemplate
+# Develop consumer with AsyncRestTemplate
 
 ## Concepts
 
diff --git a/java-chassis-reference/en_US/docs/catalog/build-consumer.md 
b/java-chassis-reference/en_US/docs/catalog/build-consumer.md
index 2533943..44ae168 100644
--- a/java-chassis-reference/en_US/docs/catalog/build-consumer.md
+++ b/java-chassis-reference/en_US/docs/catalog/build-consumer.md
@@ -1,7 +1,7 @@
 ## Develop consumer with Rest Template
 RestTemplate is a RESTful API provided by the Spring framework.  ServiceComb 
provides the implementation class for service calling
 
-## Develop consumer with AsynRestTemplate
+## Develop consumer with AsyncRestTemplate
 AsyncRestTemplate allows users to make asynchronous service calls. The logic 
is similar to restTemplate, except that the service is called asynchronously.
 
 ## Develop consumer with transparent RPC
diff --git a/java-chassis-reference/en_US/mkdocs.yml 
b/java-chassis-reference/en_US/mkdocs.yml
index e020477..7a14320 100644
--- a/java-chassis-reference/en_US/mkdocs.yml
+++ b/java-chassis-reference/en_US/mkdocs.yml
@@ -27,7 +27,7 @@ nav:
 - Writing Service Consumer: 
 - Consumer common configuration: build-consumer/common-configuration.md
 - Using Rest Template: build-consumer/using-resttemplate.md
-- Using AsynRestTemplate: build-consumer/using-AsyncRestTemplate.md
+- Using AsyncRestTemplate: build-consumer/using-AsyncRestTemplate.md
 - Using with RPC: build-consumer/develop-consumer-using-rpc.md
 - Contract: build-consumer/with-contract.md
 - Invoke control: 
diff --git a/java-chassis-reference/zh_CN/docs/build-consumer/catalog.md 
b/java-chassis-reference/zh_CN/docs/build-consumer/catalog.md
index 6897227..adb9bf5 100644
--- a/java-chassis-reference/zh_CN/docs/build-consumer/catalog.md
+++ b/java-chassis-reference/zh_CN/docs/build-consumer/catalog.md
@@ -2,7 +2,7 @@
 
 * [消费者通用配置项](common-configuration.md)
 * [使用RestTemplate开发服务消费者](using-resttemplate.md)
-* [使用AsynRestTemplate开发服务消费者](using-AsyncRestTemplate.md)
+* [使用AsyncRestTemplate开发服务消费者](using-AsyncRestTemplate.md)
 * [使用RPC方式开发服务消费者](develop-consumer-using-rpc.md)
 * [泛化调用](../featured-topics/features/invoker.md)
 * [使用服务契约](with-contract.md)
diff --git 
a/java-chassis-reference/zh_CN/docs/build-consumer/using-AsyncRestTemplate.md 
b/java-chassis-reference/zh_CN/docs/build-consumer/using-AsyncRestTemplate.md
index d86ee7b..a5816f8 100644
--- 
a/java-chassis-reference/zh_CN/docs/build-consumer/using-AsyncRestTemplate.md
+++ 
b/java-chassis-reference/zh_CN/docs/build-consumer/using-AsyncRestTemplate.md
@@ -1,4 +1,22 @@
-# 使用AsynRestTemplate开发服务消费者
+# 使用AsyncRestTemplate开发服务消费者
+
+***注意***: AsyncRestTemplate 接口在新版本的 Spring 接口中已经废弃。 建议使用异步 RPC 接口访问, 例如:
+
+```
+interface Hello {
+  CompletableFuture sayHi(String name);
+}
+
+@Component
+public class SomeBean {
+  ..
+
+  @RpcReference(microserviceName = "helloService", schemaId = "helloSchema")
+  private Hello hello;
+
+  ..
+}
+```
 
 ## 概念阐述
 
diff --git a/java-chassis-reference/zh_CN/docs/catalog/build-consumer.md 
b/java-chassis-reference/zh_CN/docs/catalog/build-consumer.md
index de4b46b..c3f5fb8 100644
--- a/java-chassis-reference/zh_CN/docs/catalog/build-consumer.md
+++ b/java-chassis-reference/zh_CN/docs/catalog/build-consumer.md
@@ -1,7 +1,7 @@
 ## 使用RestTemplate开发服务消费者
 

[GitHub] [servicecomb-java-chassis] liubao68 merged pull request #2089: fix typo and test case assert not correct in higher version of JDK

2020-11-26 Thread GitBox


liubao68 merged pull request #2089:
URL: https://github.com/apache/servicecomb-java-chassis/pull/2089


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[servicecomb-java-chassis] branch master updated: fix typo and test case assert not correct in higher version of JDK (#2089)

2020-11-26 Thread liubao
This is an automated email from the ASF dual-hosted git repository.

liubao pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/servicecomb-java-chassis.git


The following commit(s) were added to refs/heads/master by this push:
 new b7a9cb4  fix typo and test case assert not correct in higher version 
of JDK (#2089)
b7a9cb4 is described below

commit b7a9cb4bc86d770a9c4c304071324384e5081408
Author: bao liu 
AuthorDate: Fri Nov 27 14:56:46 2020 +0800

fix typo and test case assert not correct in higher version of JDK (#2089)
---
 .../servicecomb/foundation/ssl/SSLManager.java |  2 +-
 .../servicecomb/foundation/ssl/SSLManagerTest.java | 32 --
 .../foundation/vertx/VertxTLSBuilder.java  |  2 +-
 3 files changed, 19 insertions(+), 17 deletions(-)

diff --git 
a/foundations/foundation-ssl/src/main/java/org/apache/servicecomb/foundation/ssl/SSLManager.java
 
b/foundations/foundation-ssl/src/main/java/org/apache/servicecomb/foundation/ssl/SSLManager.java
index a505973..0b28c5b 100644
--- 
a/foundations/foundation-ssl/src/main/java/org/apache/servicecomb/foundation/ssl/SSLManager.java
+++ 
b/foundations/foundation-ssl/src/main/java/org/apache/servicecomb/foundation/ssl/SSLManager.java
@@ -189,7 +189,7 @@ public final class SSLManager {
 return r;
   }
 
-  public static String[] getEnalbedCiphers(String enabledCiphers) {
+  public static String[] getEnabledCiphers(String enabledCiphers) {
 SSLOption option = new SSLOption();
 option.setProtocols("TLSv1.2");
 option.setCiphers(enabledCiphers);
diff --git 
a/foundations/foundation-ssl/src/test/java/org/apache/servicecomb/foundation/ssl/SSLManagerTest.java
 
b/foundations/foundation-ssl/src/test/java/org/apache/servicecomb/foundation/ssl/SSLManagerTest.java
index d1b1476..3121367 100644
--- 
a/foundations/foundation-ssl/src/test/java/org/apache/servicecomb/foundation/ssl/SSLManagerTest.java
+++ 
b/foundations/foundation-ssl/src/test/java/org/apache/servicecomb/foundation/ssl/SSLManagerTest.java
@@ -199,7 +199,8 @@ public class SSLManagerTest {
 };
 
 SSLEngine aSSLEngine = SSLManager.createSSLEngine(option, custom);
-Assert.assertEquals(false, aSSLEngine.getUseClientMode());
+// if client mode may not decided at initialization. Different JDK is 
different, do not check it.
+// Assert.assertEquals(false, aSSLEngine.getUseClientMode());
 Assert.assertNotNull(aSSLEngine);
   }
 
@@ -222,7 +223,7 @@ public class SSLManagerTest {
 String peerHost = "host1";
 SSLEngine aSSLEngine = SSLManager.createSSLEngine(option, custom, 
peerHost, port);
 Assert.assertNotNull(aSSLEngine);
-Assert.assertEquals("host1", aSSLEngine.getPeerHost().toString());
+Assert.assertEquals("host1", aSSLEngine.getPeerHost());
   }
 
   @Test
@@ -249,8 +250,8 @@ public class SSLManagerTest {
 };
 
 try {
-  SSLContext context = SSLManager.createSSLContext(option, custom);
-  Assert.assertNotNull(context);
+  SSLManager.createSSLContext(option, custom);
+  Assert.assertNotNull(null);
 } catch (Exception e) {
   Assert.assertEquals("java.lang.IllegalArgumentException", 
e.getClass().getName());
 }
@@ -280,8 +281,8 @@ public class SSLManagerTest {
 };
 
 try {
-  SSLContext context = SSLManager.createSSLContext(option, custom);
-  Assert.assertNotNull(context);
+  SSLManager.createSSLContext(option, custom);
+  Assert.assertNotNull(null);
 } catch (Exception e) {
   Assert.assertEquals("java.lang.IllegalArgumentException", 
e.getClass().getName());
 }
@@ -311,9 +312,9 @@ public class SSLManagerTest {
 };
 
 try {
-  SSLServerSocket context = SSLManager.createSSLServerSocket(option, 
custom);
+  SSLManager.createSSLServerSocket(option, custom);
 
-  Assert.assertNotNull(context);
+  Assert.assertNotNull(null);
 } catch (Exception e) {
   Assert.assertEquals("java.lang.IllegalArgumentException", 
e.getClass().getName());
 }
@@ -343,8 +344,8 @@ public class SSLManagerTest {
 };
 
 try {
-  SSLServerSocket context = SSLManager.createSSLServerSocket(option, 
custom);
-  Assert.assertNotNull(context);
+  SSLManager.createSSLServerSocket(option, custom);
+  Assert.assertNotNull(null);
 } catch (Exception e) {
   Assert.assertEquals("java.lang.IllegalArgumentException", 
e.getClass().getName());
 }
@@ -374,8 +375,8 @@ public class SSLManagerTest {
 };
 
 try {
-  SSLSocket context = SSLManager.createSSLSocket(option, custom);
-  Assert.assertNotNull(context);
+  SSLManager.createSSLSocket(option, custom);
+  Assert.assertNotNull(null);
 } catch (Exception e) {
   Assert.assertEquals("java.lang.IllegalArgumentException", 
e.getClass().getName());
 }
@@ -405,8 +406,8 @@ public class SSLManagerTest {
 };
 
 try {
-  SSLSocket context = SSLManager.createSSLSocket(option, custom);
-  

[GitHub] [servicecomb-java-chassis] liubao68 commented on a change in pull request #2089: fix typo and test case assert not correct in higher version of JDK

2020-11-26 Thread GitBox


liubao68 commented on a change in pull request #2089:
URL: 
https://github.com/apache/servicecomb-java-chassis/pull/2089#discussion_r531412742



##
File path: 
foundations/foundation-ssl/src/test/java/org/apache/servicecomb/foundation/ssl/SSLManagerTest.java
##
@@ -249,8 +250,8 @@ public final SSLContext getInstance(String type) throws 
NoSuchAlgorithmException
 };
 
 try {
-  SSLContext context = SSLManager.createSSLContext(option, custom);
-  Assert.assertNotNull(context);
+  SSLManager.createSSLContext(option, custom);
+  Assert.assertNotNull(null);
 } catch (Exception e) {
   Assert.assertEquals("java.lang.IllegalArgumentException", 
e.getClass().getName());
 }

Review comment:
   OK . Will try that in the future. 





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-docs] liubao68 opened a new pull request #208: [SCB-2073]create documents to integrate logger for java-chassis

2020-11-26 Thread GitBox


liubao68 opened a new pull request #208:
URL: https://github.com/apache/servicecomb-docs/pull/208


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[servicecomb-docs] branch master updated (dc49501 -> 7550180)

2020-11-26 Thread liubao
This is an automated email from the ASF dual-hosted git repository.

liubao pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/servicecomb-docs.git.


from dc49501  3rdparty registry and service center docs improvement (#206)
 add 7550180  [SCB-1885] fix router doc bug (#207)

No new revisions were added by this update.

Summary of changes:
 java-chassis-reference/zh_CN/docs/references-handlers/router.md | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)



[GitHub] [servicecomb-docs] liubao68 merged pull request #207: [SCB-1885] fix router doc bug

2020-11-26 Thread GitBox


liubao68 merged pull request #207:
URL: https://github.com/apache/servicecomb-docs/pull/207


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-docs] GuoYL123 opened a new pull request #207: [SCB-1885] fix router doc bug

2020-11-26 Thread GitBox


GuoYL123 opened a new pull request #207:
URL: https://github.com/apache/servicecomb-docs/pull/207


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-docs] liubao68 merged pull request #206: 3rdparty registry and service center docs improvement

2020-11-26 Thread GitBox


liubao68 merged pull request #206:
URL: https://github.com/apache/servicecomb-docs/pull/206


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[servicecomb-docs] branch master updated: 3rdparty registry and service center docs improvement (#206)

2020-11-26 Thread liubao
This is an automated email from the ASF dual-hosted git repository.

liubao pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/servicecomb-docs.git


The following commit(s) were added to refs/heads/master by this push:
 new dc49501  3rdparty registry and service center docs improvement (#206)
dc49501 is described below

commit dc49501f4f0e1ef8d2127e6905e75bc9efb055e3
Author: bao liu 
AuthorDate: Fri Nov 27 14:29:58 2020 +0800

3rdparty registry and service center docs improvement (#206)
---
 .../build-consumer/3rd-party-service-invoke.md |  55 +++
 .../zh_CN/docs/registry/introduction.md|  21 ---
 .../zh_CN/docs/registry/multi-registries.md|  35 -
 .../zh_CN/docs/registry/service-center.md  | 172 +
 java-chassis-reference/zh_CN/docs/security/rbac.md |  71 -
 java-chassis-reference/zh_CN/docs/toc.md   |   5 +-
 java-chassis-reference/zh_CN/mkdocs.yml|   2 +-
 7 files changed, 198 insertions(+), 163 deletions(-)

diff --git 
a/java-chassis-reference/zh_CN/docs/build-consumer/3rd-party-service-invoke.md 
b/java-chassis-reference/zh_CN/docs/build-consumer/3rd-party-service-invoke.md
index f8508eb..90fcf75 100644
--- 
a/java-chassis-reference/zh_CN/docs/build-consumer/3rd-party-service-invoke.md
+++ 
b/java-chassis-reference/zh_CN/docs/build-consumer/3rd-party-service-invoke.md
@@ -2,9 +2,11 @@
 
 ## 概念阐述
 
-ServiceComb允许用户注册第三方REST服务的endpoint、接口契约等信息,使用户可以以调用ServiceComb 
provider服务相同的方式编写调用第三方服务的代码。
+第三方服务没有在服务中心注册,不存契约信息,Java Chassis 提供一种透明的方式访问第三方服务。 
 使用该功能调用第三方服务时,发往第三方服务的请求会经过consumer端handler链、HttpClientFilter的处理,
-即该功能支持对第三方服务调用的治理功能,并且也支持ServiceComb既有的用户自定义扩展处理机制。
+即该功能支持对第三方服务调用的治理功能,并且也支持ServiceComb既有的用户自定义扩展处理机制。 
+
+另外开发者也可以使用 [本地注册发现](../registry/local-registry.md) 实现第三方调用, 两种方式实现的效果是一致的。 
 
 ## 示例代码
 
@@ -51,40 +53,30 @@ ServiceComb允许用户注册第三方REST服务的endpoint、接口契约等信
 }
 ```
 
-3. 在consumer服务中调用ServiceComb提供的方法将其进行注册:
+3. 通过实现 `ThirdServiceWithInvokerRegister` 注册第三方服务信息。 可以注册多个 schema。 
 
 ```java
-String endpoint = "rest://127.0.0.1:8080";
-
RegistryUtils.getServiceRegistry().registerMicroserviceMappingByEndpoints(
-  // 3rd party rest service name, you can specify the name on your 
need as long as you obey the microservice naming rule
-  "thirdPartyService",
-  // service version
-  "0.0.1",
-  // list of endpoints
-  Collections.singletonList(endpoint),
-  // java interface class to generate swagger schema
-  ThirdPartyRestServiceInterface.class
-);
+@Configuration
+public class ThirdSvc extends ThirdServiceWithInvokerRegister {
+  public ThirdSvc() {
+super("3rd-svc");
+
+addSchema("schema-1", VertxServerIntf.class);
+  }
+}
 ```
 
+***注意:*** java chassis 2.1.3 以上版本才支持 ThirdServiceWithInvokerRegister。 
+
 4. 调用第三方服务,声明和调用方式与调用ServiceComb provider服务相同,此处以RPC调用方式为例。
 
 ```java
-// declare rpc reference to 3rd party rest service, schemaId is the 
same as microservice name
-@RpcReference(microserviceName = "thirdPartyService", schemaId = 
"thirdPartyService")
-ThirdPartyRestServiceInterface thirdPartyRestService;
-
-@RequestMapping(path = "/{pathVar}", method = RequestMethod.GET)
-public String testInvoke(@PathVariable(name = "pathVar") String 
pathVar) {
-LOGGER.info("testInvoke() is called, pathVar = [{}]", pathVar);
-// invoke 3rd party rest service
-String response = thirdPartyRestService.testPathVar(pathVar);
-LOGGER.info("testInvoke() response = [{}]", response);
-return response;
-}
+VertxServerIntf client = 
BeanUtils.getContext().getBean(VertxServerIntf.class);
+client.testPathVar(pathVar);
 ```
 
-5. 
使用治理功能。使用治理功能的方法与普通的consumer调用provider场景类似。以限流策略为例,在consumer服务的microservice.yaml文件中进行如下配置:
+5. 使用治理功能。使用治理功能的方法与普通的consumer调用provider场景类似。以限流策略为例,在consumer
+  服务的microservice.yaml文件中进行如下配置:
 
 ```yaml
 servicecomb:
@@ -99,9 +91,8 @@ ServiceComb允许用户注册第三方REST服务的endpoint、接口契约等信
 
此时即将consumer调用名为`thirdPartyService`的第三方REST服务的QPS设置为1。当consumer调用`thirdPartyService`的流量高于1QPS时,
 将会得到`429 Too Many Requests`的`InvocationException`异常。
 
-> ***注意:***
-- endpoint信息是以`rest`开头的,而非`http`,可以参照ServiceComb微服务注册到服务中心的endpoint样式进行编写。
-- 当第三方服务有多个实例(地址)时,可以在endpoint 
list中指定多个地址,ServiceComb支持对多个地址进行负载均衡处理,处理方式和对待ServiceComb
- provider服务相同。
-- 当前仅支持一次性注册第三方服务及其实例信息,不支持增加、删除和修改操作。
+6. 配置第三分服务的实例信息
 
+3rd-svc:
+  urls:
+- http://localhost:8080
diff --git a/java-chassis-reference/zh_CN/docs/registry/introduction.md 
b/java-chassis-reference/zh_CN/docs/registry/introduction.md
index 0df7a3b..8b2dbaf 100644
--- a/java-chassis-reference/zh_CN/docs/registry/introduction.md
+++ 

[GitHub] [servicecomb-java-chassis] wujimin commented on a change in pull request #2089: fix typo and test case assert not correct in higher version of JDK

2020-11-26 Thread GitBox


wujimin commented on a change in pull request #2089:
URL: 
https://github.com/apache/servicecomb-java-chassis/pull/2089#discussion_r531404647



##
File path: 
foundations/foundation-ssl/src/test/java/org/apache/servicecomb/foundation/ssl/SSLManagerTest.java
##
@@ -249,8 +250,8 @@ public final SSLContext getInstance(String type) throws 
NoSuchAlgorithmException
 };
 
 try {
-  SSLContext context = SSLManager.createSSLContext(option, custom);
-  Assert.assertNotNull(context);
+  SSLManager.createSSLContext(option, custom);
+  Assert.assertNotNull(null);
 } catch (Exception e) {
   Assert.assertEquals("java.lang.IllegalArgumentException", 
e.getClass().getName());
 }

Review comment:
   ```java
   Throwable throwable = 
Assertions.catchThrowable(()->SSLManager.createSSLContext(option, custom));
   assertThat(throwable).isInstanceOf(IllegalArgumentException.class);
   ```
   
   异常的assert场景,用assertJ会简单清晰得多





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] liubao68 opened a new pull request #2089: fix typo and test case assert not correct in higher version of JDK

2020-11-26 Thread GitBox


liubao68 opened a new pull request #2089:
URL: https://github.com/apache/servicecomb-java-chassis/pull/2089


   Follow this checklist to help us incorporate your contribution quickly and 
easily:
   
- [ ] Make sure there is a [JIRA 
issue](https://issues.apache.org/jira/browse/SCB) filed for the change (usually 
before you start working on it).  Trivial changes like typos do not require a 
JIRA issue.  Your pull request should address just this issue, without pulling 
in other changes.
- [ ] Each commit in the pull request should have a meaningful subject line 
and body.
- [ ] Format the pull request title like `[SCB-XXX] Fixes bug in 
ApproximateQuantiles`, where you replace `SCB-XXX` with the appropriate JIRA 
issue.
- [ ] Write a pull request description that is detailed enough to 
understand what the pull request does, how, and why.
- [ ] Run `mvn clean install -Pit` to make sure basic checks pass. A more 
thorough check will be performed on your pull request automatically.
- [ ] If this contribution is large, please file an Apache [Individual 
Contributor License Agreement](https://www.apache.org/licenses/icla.pdf).
   
   ---
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[servicecomb-java-chassis] branch master updated: release of 2.1.3 (#2088)

2020-11-26 Thread liubao
This is an automated email from the ASF dual-hosted git repository.

liubao pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/servicecomb-java-chassis.git


The following commit(s) were added to refs/heads/master by this push:
 new cbd4c57  release of 2.1.3 (#2088)
cbd4c57 is described below

commit cbd4c577a01221e1421f8e7c6a2ba04aa3c4e6bd
Author: bao liu 
AuthorDate: Fri Nov 27 11:40:04 2020 +0800

release of 2.1.3 (#2088)
---
 archetypes/business-service-jaxrs/pom.xml   | 2 +-
 archetypes/business-service-pojo/pom.xml| 2 +-
 archetypes/business-service-spring-boot2-starter/pom.xml| 2 +-
 archetypes/business-service-springmvc/pom.xml   | 2 +-
 archetypes/pom.xml  | 2 +-
 clients/config-center-client/pom.xml| 2 +-
 clients/http-client-common/pom.xml  | 2 +-
 clients/kie-client/pom.xml  | 2 +-
 clients/pom.xml | 2 +-
 clients/service-center-client/pom.xml   | 2 +-
 common/common-access-log/pom.xml| 2 +-
 common/common-protobuf/pom.xml  | 2 +-
 common/common-rest/pom.xml  | 2 +-
 common/pom.xml  | 2 +-
 core/pom.xml| 2 +-
 coverage-reports/pom.xml| 2 +-
 demo/demo-crossapp/crossapp-client/pom.xml  | 2 +-
 demo/demo-crossapp/crossapp-server/pom.xml  | 2 +-
 demo/demo-crossapp/pom.xml  | 2 +-
 demo/demo-edge/authentication/pom.xml   | 2 +-
 demo/demo-edge/business-1-1-0/pom.xml   | 2 +-
 demo/demo-edge/business-1.0.0/pom.xml   | 2 +-
 demo/demo-edge/business-2.0.0/pom.xml   | 2 +-
 demo/demo-edge/consumer/pom.xml | 2 +-
 demo/demo-edge/edge-service/pom.xml | 2 +-
 demo/demo-edge/model/pom.xml| 2 +-
 demo/demo-edge/pom.xml  | 2 +-
 demo/demo-jaxrs/jaxrs-client/pom.xml| 2 +-
 demo/demo-jaxrs/jaxrs-server/pom.xml| 2 +-
 demo/demo-jaxrs/pom.xml | 2 +-
 demo/demo-local-registry/demo-local-registry-client/pom.xml | 2 +-
 demo/demo-local-registry/demo-local-registry-server/pom.xml | 2 +-
 demo/demo-local-registry/pom.xml| 2 +-
 demo/demo-multi-registries/demo-multi-registries-client/pom.xml | 2 +-
 demo/demo-multi-registries/demo-multi-registries-server/pom.xml | 2 +-
 demo/demo-multi-registries/pom.xml  | 2 +-
 .../demo-multi-service-center-client/pom.xml| 2 +-
 .../demo-multi-service-center-serverA/pom.xml   | 2 +-
 .../demo-multi-service-center-serverB/pom.xml   | 2 +-
 demo/demo-multi-service-center/pom.xml  | 2 +-
 demo/demo-multiple/a-client/pom.xml | 2 +-
 demo/demo-multiple/a-server/pom.xml | 2 +-
 demo/demo-multiple/b-client/pom.xml | 2 +-
 demo/demo-multiple/b-server/pom.xml | 2 +-
 demo/demo-multiple/multiple-client/pom.xml  | 2 +-
 demo/demo-multiple/multiple-server/pom.xml  | 2 +-
 demo/demo-multiple/pom.xml  | 2 +-
 demo/demo-pojo/pojo-client/pom.xml  | 2 +-
 demo/demo-pojo/pojo-server/pom.xml  | 2 +-
 demo/demo-pojo/pom.xml  | 2 +-
 .../demo-register-url-prefix-client/pom.xml | 2 +-
 .../demo-register-url-prefix-server/pom.xml | 2 +-
 demo/demo-register-url-prefix/pom.xml   | 2 +-
 demo/demo-schema/pom.xml| 2 +-
 demo/demo-signature/pom.xml | 2 +-
 .../demo-spring-boot-provider/demo-spring-boot-jaxrs-client/pom.xml | 2 +-
 .../demo-spring-boot-provider/demo-spring-boot-jaxrs-server/pom.xml | 2 +-
 .../demo-spring-boot-springmvc-client/pom.xml   | 2 +-
 .../demo-spring-boot-springmvc-server/pom.xml   | 2 +-
 demo/demo-spring-boot-provider/pom.xml   

[GitHub] [servicecomb-java-chassis] liubao68 merged pull request #2088: release of 2.1.3

2020-11-26 Thread GitBox


liubao68 merged pull request #2088:
URL: https://github.com/apache/servicecomb-java-chassis/pull/2088


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-docs] liubao68 opened a new pull request #206: 3rdparty registry and service center docs improvement

2020-11-26 Thread GitBox


liubao68 opened a new pull request #206:
URL: https://github.com/apache/servicecomb-docs/pull/206


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] codecov-io commented on pull request #2088: release of 2.1.3

2020-11-26 Thread GitBox


codecov-io commented on pull request #2088:
URL: 
https://github.com/apache/servicecomb-java-chassis/pull/2088#issuecomment-734606343


   # 
[Codecov](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2088?src=pr=h1)
 Report
   > Merging 
[#2088](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2088?src=pr=desc)
 (ecb577f) into 
[master](https://codecov.io/gh/apache/servicecomb-java-chassis/commit/f33483f6ceea68ae36faeb15da9b18f48f2f2b06?el=desc)
 (f33483f) will **increase** coverage by `0.00%`.
   > The diff coverage is `n/a`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2088/graphs/tree.svg?width=650=150=pr=KXfDcr9rX2)](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2088?src=pr=tree)
   
   ```diff
   @@Coverage Diff@@
   ## master#2088   +/-   ##
   =
 Coverage 81.55%   81.56%   
 Complexity 1327 1327   
   =
 Files  1442 1442   
 Lines 3950139501   
 Branches   3353 3353   
   =
   + Hits  3221632219+3 
   + Misses 5823 5820-3 
 Partials   1462 1462   
   ```
   
   
   | [Impacted 
Files](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2088?src=pr=tree)
 | Coverage Δ | Complexity Δ | |
   |---|---|---|---|
   | 
[...ecomb/provider/pojo/PojoConsumerMetaRefresher.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2088/diff?src=pr=tree#diff-cHJvdmlkZXJzL3Byb3ZpZGVyLXBvam8vc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NlcnZpY2Vjb21iL3Byb3ZpZGVyL3Bvam8vUG9qb0NvbnN1bWVyTWV0YVJlZnJlc2hlci5qYXZh)
 | `75.60% <0.00%> (-2.44%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...omb/codec/protobuf/definition/ProtobufManager.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2088/diff?src=pr=tree#diff-Y29tbW9uL2NvbW1vbi1wcm90b2J1Zi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvY29kZWMvcHJvdG9idWYvZGVmaW5pdGlvbi9Qcm90b2J1Zk1hbmFnZXIuamF2YQ==)
 | `70.73% <0.00%> (-2.44%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...egistry/client/http/ServiceRegistryClientImpl.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2088/diff?src=pr=tree#diff-c2VydmljZS1yZWdpc3RyeS9yZWdpc3RyeS1zZXJ2aWNlLWNlbnRlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvc2VydmljZXJlZ2lzdHJ5L2NsaWVudC9odHRwL1NlcnZpY2VSZWdpc3RyeUNsaWVudEltcGwuamF2YQ==)
 | `70.48% <0.00%> (+0.19%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...in/java/org/apache/servicecomb/core/SCBEngine.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2088/diff?src=pr=tree#diff-Y29yZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvY29yZS9TQ0JFbmdpbmUuamF2YQ==)
 | `78.86% <0.00%> (+1.21%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...ache/servicecomb/foundation/common/net/IpPort.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2088/diff?src=pr=tree#diff-Zm91bmRhdGlvbnMvZm91bmRhdGlvbi1jb21tb24vc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NlcnZpY2Vjb21iL2ZvdW5kYXRpb24vY29tbW9uL25ldC9JcFBvcnQuamF2YQ==)
 | `93.33% <0.00%> (+3.33%)` | `0.00% <0.00%> (ø%)` | |
   
   --
   
   [Continue to review full report at 
Codecov](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2088?src=pr=continue).
   > **Legend** - [Click here to learn 
more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute  (impact)`, `ø = not affected`, `? = missing data`
   > Powered by 
[Codecov](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2088?src=pr=footer).
 Last update 
[f33483f...ecb577f](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2088?src=pr=lastupdated).
 Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] liubao68 opened a new pull request #2088: release of 2.1.3

2020-11-26 Thread GitBox


liubao68 opened a new pull request #2088:
URL: https://github.com/apache/servicecomb-java-chassis/pull/2088


   Follow this checklist to help us incorporate your contribution quickly and 
easily:
   
- [ ] Make sure there is a [JIRA 
issue](https://issues.apache.org/jira/browse/SCB) filed for the change (usually 
before you start working on it).  Trivial changes like typos do not require a 
JIRA issue.  Your pull request should address just this issue, without pulling 
in other changes.
- [ ] Each commit in the pull request should have a meaningful subject line 
and body.
- [ ] Format the pull request title like `[SCB-XXX] Fixes bug in 
ApproximateQuantiles`, where you replace `SCB-XXX` with the appropriate JIRA 
issue.
- [ ] Write a pull request description that is detailed enough to 
understand what the pull request does, how, and why.
- [ ] Run `mvn clean install -Pit` to make sure basic checks pass. A more 
thorough check will be performed on your pull request automatically.
- [ ] If this contribution is large, please file an Apache [Individual 
Contributor License Agreement](https://www.apache.org/licenses/icla.pdf).
   
   ---
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] wujimin merged pull request #2086: [#2081]add a test case for query with List

2020-11-26 Thread GitBox


wujimin merged pull request #2086:
URL: https://github.com/apache/servicecomb-java-chassis/pull/2086


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[servicecomb-java-chassis] 01/03: [#2081]add a test case for query with List

2020-11-26 Thread wujimin
This is an automated email from the ASF dual-hosted git repository.

wujimin pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/servicecomb-java-chassis.git

commit 96afde535ff4acd6f224a40a636f15dddbd4baf6
Author: liubao 
AuthorDate: Thu Nov 26 18:02:31 2020 +0800

[#2081]add a test case for query with List
---
 .../jaxrs/client/TestQueryParamWithListSchema.java | 154 +
 .../jaxrs/server/QueryParamWithListSchema.java |  62 +
 2 files changed, 216 insertions(+)

diff --git 
a/demo/demo-jaxrs/jaxrs-client/src/main/java/org/apache/servicecomb/demo/jaxrs/client/TestQueryParamWithListSchema.java
 
b/demo/demo-jaxrs/jaxrs-client/src/main/java/org/apache/servicecomb/demo/jaxrs/client/TestQueryParamWithListSchema.java
new file mode 100644
index 000..84ab80a
--- /dev/null
+++ 
b/demo/demo-jaxrs/jaxrs-client/src/main/java/org/apache/servicecomb/demo/jaxrs/client/TestQueryParamWithListSchema.java
@@ -0,0 +1,154 @@
+/*
+ * 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.servicecomb.demo.jaxrs.client;
+
+import org.apache.servicecomb.demo.CategorizedTestCase;
+import org.apache.servicecomb.demo.TestMgr;
+import org.apache.servicecomb.provider.springmvc.reference.RestTemplateBuilder;
+import org.springframework.stereotype.Component;
+import org.springframework.web.client.RestTemplate;
+
+@Component
+public class TestQueryParamWithListSchema implements CategorizedTestCase {
+  private RestTemplate restTemplate = RestTemplateBuilder.create();
+
+  @Override
+  public void testAllTransport() throws Exception {
+testMulti();
+testCSV();
+testSSV();
+testTSV();
+testPipes();
+  }
+
+  @Override
+  public void testRestTransport() throws Exception {
+testMultiRest();
+testCSVRest();
+testSSVRest();
+testTSVRest();
+testPipesRest();
+  }
+
+  @Override
+  // highway do not handle empty/default/null
+  public void testHighwayTransport() throws Exception {
+testMultiHighway();
+testCSVHighway();
+testSSVHighway();
+testTSVHighway();
+testPipesHighway();
+  }
+
+  private void testCSVHighway() {
+TestMgr.check("null",
+restTemplate.getForObject("cse://jaxrs/queryList/queryListCSV?", 
String.class));
+  }
+
+  private void testCSVRest() {
+TestMgr.check("[]",
+restTemplate.getForObject("cse://jaxrs/queryList/queryListCSV?", 
String.class));
+  }
+
+  private void testSSV() {
+TestMgr.check("[1, 2]",
+
restTemplate.getForObject("cse://jaxrs/queryList/queryListSSV?queryList=1%202", 
String.class));
+TestMgr.check("[, ]",
+
restTemplate.getForObject("cse://jaxrs/queryList/queryListSSV?queryList=%20", 
String.class));
+TestMgr.check("[]",
+
restTemplate.getForObject("cse://jaxrs/queryList/queryListSSV?queryList=", 
String.class));
+  }
+
+  private void testTSVHighway() {
+TestMgr.check("null",
+restTemplate.getForObject("cse://jaxrs/queryList/queryListTSV?", 
String.class));
+  }
+
+  private void testTSVRest() {
+TestMgr.check("[]",
+restTemplate.getForObject("cse://jaxrs/queryList/queryListTSV?", 
String.class));
+  }
+
+  private void testTSV() {
+TestMgr.check("[1, 2]",
+restTemplate
+.getForObject("cse://jaxrs/queryList/queryListTSV?queryList={1}", 
String.class, "1\t2"));
+TestMgr.check("[, ]",
+
restTemplate.getForObject("cse://jaxrs/queryList/queryListTSV?queryList={1}", 
String.class, "\t"));
+TestMgr.check("[]",
+
restTemplate.getForObject("cse://jaxrs/queryList/queryListTSV?queryList=", 
String.class));
+  }
+
+  private void testPipesHighway() {
+TestMgr.check("null",
+restTemplate.getForObject("cse://jaxrs/queryList/queryListPIPES?", 
String.class));
+  }
+
+  private void testPipesRest() {
+TestMgr.check("[]",
+restTemplate.getForObject("cse://jaxrs/queryList/queryListPIPES?", 
String.class));
+  }
+
+  private void testPipes() {
+TestMgr.check("[1, 2]",
+restTemplate
+
.getForObject("cse://jaxrs/queryList/queryListPIPES?queryList={1}", 
String.class, "1|2"));
+TestMgr.check("[, ]",
+

[servicecomb-java-chassis] 03/03: [SCB-2131]fix review comment

2020-11-26 Thread wujimin
This is an automated email from the ASF dual-hosted git repository.

wujimin pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/servicecomb-java-chassis.git

commit f33483f6ceea68ae36faeb15da9b18f48f2f2b06
Author: liubao 
AuthorDate: Fri Nov 27 09:43:46 2020 +0800

[SCB-2131]fix review comment
---
 .../jaxrs/client/TestQueryParamWithListSchema.java | 40 +++---
 .../jaxrs/server/QueryParamWithListSchema.java | 10 +++---
 2 files changed, 25 insertions(+), 25 deletions(-)

diff --git 
a/demo/demo-jaxrs/jaxrs-client/src/main/java/org/apache/servicecomb/demo/jaxrs/client/TestQueryParamWithListSchema.java
 
b/demo/demo-jaxrs/jaxrs-client/src/main/java/org/apache/servicecomb/demo/jaxrs/client/TestQueryParamWithListSchema.java
index 84ab80a..40c9b8d 100644
--- 
a/demo/demo-jaxrs/jaxrs-client/src/main/java/org/apache/servicecomb/demo/jaxrs/client/TestQueryParamWithListSchema.java
+++ 
b/demo/demo-jaxrs/jaxrs-client/src/main/java/org/apache/servicecomb/demo/jaxrs/client/TestQueryParamWithListSchema.java
@@ -61,16 +61,16 @@ public class TestQueryParamWithListSchema implements 
CategorizedTestCase {
   }
 
   private void testCSVRest() {
-TestMgr.check("[]",
+TestMgr.check("0:[]",
 restTemplate.getForObject("cse://jaxrs/queryList/queryListCSV?", 
String.class));
   }
 
   private void testSSV() {
-TestMgr.check("[1, 2]",
+TestMgr.check("2:[1, 2]",
 
restTemplate.getForObject("cse://jaxrs/queryList/queryListSSV?queryList=1%202", 
String.class));
-TestMgr.check("[, ]",
+TestMgr.check("2:[, ]",
 
restTemplate.getForObject("cse://jaxrs/queryList/queryListSSV?queryList=%20", 
String.class));
-TestMgr.check("[]",
+TestMgr.check("1:[]",
 
restTemplate.getForObject("cse://jaxrs/queryList/queryListSSV?queryList=", 
String.class));
   }
 
@@ -80,17 +80,17 @@ public class TestQueryParamWithListSchema implements 
CategorizedTestCase {
   }
 
   private void testTSVRest() {
-TestMgr.check("[]",
+TestMgr.check("0:[]",
 restTemplate.getForObject("cse://jaxrs/queryList/queryListTSV?", 
String.class));
   }
 
   private void testTSV() {
-TestMgr.check("[1, 2]",
+TestMgr.check("2:[1, 2]",
 restTemplate
 .getForObject("cse://jaxrs/queryList/queryListTSV?queryList={1}", 
String.class, "1\t2"));
-TestMgr.check("[, ]",
+TestMgr.check("2:[, ]",
 
restTemplate.getForObject("cse://jaxrs/queryList/queryListTSV?queryList={1}", 
String.class, "\t"));
-TestMgr.check("[]",
+TestMgr.check("1:[]",
 
restTemplate.getForObject("cse://jaxrs/queryList/queryListTSV?queryList=", 
String.class));
   }
 
@@ -100,17 +100,17 @@ public class TestQueryParamWithListSchema implements 
CategorizedTestCase {
   }
 
   private void testPipesRest() {
-TestMgr.check("[]",
+TestMgr.check("0:[]",
 restTemplate.getForObject("cse://jaxrs/queryList/queryListPIPES?", 
String.class));
   }
 
   private void testPipes() {
-TestMgr.check("[1, 2]",
+TestMgr.check("2:[1, 2]",
 restTemplate
 
.getForObject("cse://jaxrs/queryList/queryListPIPES?queryList={1}", 
String.class, "1|2"));
-TestMgr.check("[, ]",
+TestMgr.check("2:[, ]",
 
restTemplate.getForObject("cse://jaxrs/queryList/queryListPIPES?queryList={1}", 
String.class, "|"));
-TestMgr.check("[]",
+TestMgr.check("1:[]",
 
restTemplate.getForObject("cse://jaxrs/queryList/queryListPIPES?queryList=", 
String.class));
   }
 
@@ -120,16 +120,16 @@ public class TestQueryParamWithListSchema implements 
CategorizedTestCase {
   }
 
   private void testSSVRest() {
-TestMgr.check("[]",
+TestMgr.check("0:[]",
 restTemplate.getForObject("cse://jaxrs/queryList/queryListSSV?", 
String.class));
   }
 
   private void testCSV() {
-TestMgr.check("[1, 2]",
+TestMgr.check("2:[1, 2]",
 
restTemplate.getForObject("cse://jaxrs/queryList/queryListCSV?queryList=1,2", 
String.class));
-TestMgr.check("[, ]",
+TestMgr.check("2:[, ]",
 
restTemplate.getForObject("cse://jaxrs/queryList/queryListCSV?queryList=,", 
String.class));
-TestMgr.check("[]",
+TestMgr.check("1:[]",
 
restTemplate.getForObject("cse://jaxrs/queryList/queryListCSV?queryList=", 
String.class));
   }
 
@@ -139,16 +139,16 @@ public class TestQueryParamWithListSchema implements 
CategorizedTestCase {
   }
 
   private void testMultiRest() {
-TestMgr.check("[]",
+TestMgr.check("0:[]",
 restTemplate.getForObject("cse://jaxrs/queryList/queryListMULTI?", 
String.class));
   }
 
   private void testMulti() {
-TestMgr.check("[1, 2]",
+TestMgr.check("2:[1, 2]",
 
restTemplate.getForObject("cse://jaxrs/queryList/queryListMULTI?queryList=1=2",
 String.class));
-TestMgr.check("[, ]",
+TestMgr.check("2:[, ]",
 
restTemplate.getForObject("cse://jaxrs/queryList/queryListMULTI?queryList==",
 String.class));
-

[servicecomb-java-chassis] branch master updated (4f58467 -> f33483f)

2020-11-26 Thread wujimin
This is an automated email from the ASF dual-hosted git repository.

wujimin pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/servicecomb-java-chassis.git.


from 4f58467  Scb 2128 support dynamic single value enum (#2080)
 new 96afde5  [#2081]add a test case for query with List
 new c3e0a57  [SCB-2131]when timeout exception, connect closed will trigger 
asynchronous callback
 new f33483f  [SCB-2131]fix review comment

The 3 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:
 .../jaxrs/client/TestQueryParamWithListSchema.java | 154 +
 .../jaxrs/server/QueryParamWithListSchema.java |  62 +
 .../rest/client/http/RestClientInvocation.java |  16 ++-
 3 files changed, 228 insertions(+), 4 deletions(-)
 create mode 100644 
demo/demo-jaxrs/jaxrs-client/src/main/java/org/apache/servicecomb/demo/jaxrs/client/TestQueryParamWithListSchema.java
 create mode 100644 
demo/demo-jaxrs/jaxrs-server/src/main/java/org/apache/servicecomb/demo/jaxrs/server/QueryParamWithListSchema.java



[servicecomb-java-chassis] 02/03: [SCB-2131]when timeout exception, connect closed will trigger asynchronous callback

2020-11-26 Thread wujimin
This is an automated email from the ASF dual-hosted git repository.

wujimin pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/servicecomb-java-chassis.git

commit c3e0a57c5b67069d661636c4b9f045041dc2afd5
Author: liubao 
AuthorDate: Thu Nov 26 21:16:15 2020 +0800

[SCB-2131]when timeout exception, connect closed will trigger asynchronous 
callback
---
 .../transport/rest/client/http/RestClientInvocation.java | 16 
 1 file changed, 12 insertions(+), 4 deletions(-)

diff --git 
a/transports/transport-rest/transport-rest-client/src/main/java/org/apache/servicecomb/transport/rest/client/http/RestClientInvocation.java
 
b/transports/transport-rest/transport-rest-client/src/main/java/org/apache/servicecomb/transport/rest/client/http/RestClientInvocation.java
index 838131d..18f6f58 100644
--- 
a/transports/transport-rest/transport-rest-client/src/main/java/org/apache/servicecomb/transport/rest/client/http/RestClientInvocation.java
+++ 
b/transports/transport-rest/transport-rest-client/src/main/java/org/apache/servicecomb/transport/rest/client/http/RestClientInvocation.java
@@ -84,6 +84,8 @@ public class RestClientInvocation {
 
   private Handler throwableHandler = e -> fail((ConnectionBase) 
clientRequest.connection(), e);
 
+  private boolean alreadyFailed = false;
+
   public RestClientInvocation(HttpClientWithContext httpClientWithContext, 
List httpClientFilters) {
 this.httpClientWithContext = httpClientWithContext;
 this.httpClientFilters = httpClientFilters;
@@ -115,8 +117,10 @@ public class RestClientInvocation {
 }
 
 clientRequest.exceptionHandler(e -> {
-  invocation.getTraceIdLogger().error(LOGGER, "Failed to send request, 
local:{}, remote:{}, message={}.",
-  getLocalAddress(), ipPort.getSocketAddress(), 
ExceptionUtils.getExceptionMessageWithoutTrace(e));
+  invocation.getTraceIdLogger()
+  .error(LOGGER, "Failed to send request, alreadyFailed:{}, local:{}, 
remote:{}, message={}.",
+  alreadyFailed, getLocalAddress(), ipPort.getSocketAddress(),
+  ExceptionUtils.getExceptionMessageWithoutTrace(e));
   throwableHandler.handle(e);
 });
 
@@ -129,7 +133,9 @@ public class RestClientInvocation {
 restClientRequest.end();
   } catch (Throwable e) {
 invocation.getTraceIdLogger().error(LOGGER,
-"send http request failed, local:{}, remote: {}, message={}.", 
getLocalAddress(), ipPort
+"send http request failed, alreadyFailed:{}, local:{}, remote: {}, 
message={}.",
+alreadyFailed,
+getLocalAddress(), ipPort
 , ExceptionUtils.getExceptionMessageWithoutTrace(e));
 fail((ConnectionBase) clientRequest.connection(), e);
   }
@@ -249,10 +255,12 @@ public class RestClientInvocation {
   }
 
   protected void fail(ConnectionBase connection, Throwable e) {
-if (invocation.isFinished()) {
+if (alreadyFailed) {
   return;
 }
 
+alreadyFailed = true;
+
 InvocationStageTrace stageTrace = invocation.getInvocationStageTrace();
 // connection maybe null when exception happens such as ssl handshake 
failure
 if (connection != null) {



[GitHub] [servicecomb-java-chassis] codecov-io edited a comment on pull request #2086: [#2081]add a test case for query with List

2020-11-26 Thread GitBox


codecov-io edited a comment on pull request #2086:
URL: 
https://github.com/apache/servicecomb-java-chassis/pull/2086#issuecomment-734308562


   # 
[Codecov](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086?src=pr=h1)
 Report
   > Merging 
[#2086](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086?src=pr=desc)
 (a91f8d5) into 
[master](https://codecov.io/gh/apache/servicecomb-java-chassis/commit/e65d46da2290d27bb89fb6b3aafe2e5244eed7b0?el=desc)
 (e65d46d) will **increase** coverage by `0.04%`.
   > The diff coverage is `100.00%`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/graphs/tree.svg?width=650=150=pr=KXfDcr9rX2)](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086?src=pr=tree)
   
   ```diff
   @@ Coverage Diff  @@
   ## master#2086  +/-   ##
   
   + Coverage 81.50%   81.55%   +0.04% 
   - Complexity 1299 1327  +28 
   
 Files  1435 1442   +7 
 Lines 3924039501 +261 
 Branches   3334 3353  +19 
   
   + Hits  3198232214 +232 
   - Misses 5801 5824  +23 
   - Partials   1457 1463   +6 
   ```
   
   
   | [Impacted 
Files](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086?src=pr=tree)
 | Coverage Δ | Complexity Δ | |
   |---|---|---|---|
   | 
[...emo/jaxrs/client/TestQueryParamWithListSchema.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/diff?src=pr=tree#diff-ZGVtby9kZW1vLWpheHJzL2pheHJzLWNsaWVudC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvZGVtby9qYXhycy9jbGllbnQvVGVzdFF1ZXJ5UGFyYW1XaXRoTGlzdFNjaGVtYS5qYXZh)
 | `100.00% <100.00%> (ø)` | `19.00 <19.00> (?)` | |
   | 
[...ansport/rest/client/http/RestClientInvocation.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/diff?src=pr=tree#diff-dHJhbnNwb3J0cy90cmFuc3BvcnQtcmVzdC90cmFuc3BvcnQtcmVzdC1jbGllbnQvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NlcnZpY2Vjb21iL3RyYW5zcG9ydC9yZXN0L2NsaWVudC9odHRwL1Jlc3RDbGllbnRJbnZvY2F0aW9uLmphdmE=)
 | `94.66% <100.00%> (+0.18%)` | `0.00 <0.00> (ø)` | |
   | 
[...l/schema/deserializer/scalar/EnumsReadSchemas.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/diff?src=pr=tree#diff-Zm91bmRhdGlvbnMvZm91bmRhdGlvbi1wcm90b2J1Zi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvZm91bmRhdGlvbi9wcm90b2J1Zi9pbnRlcm5hbC9zY2hlbWEvZGVzZXJpYWxpemVyL3NjYWxhci9FbnVtc1JlYWRTY2hlbWFzLmphdmE=)
 | `54.34% <0.00%> (-13.22%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...pache/servicecomb/config/kie/client/KieClient.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/diff?src=pr=tree#diff-ZHluYW1pYy1jb25maWcvY29uZmlnLWtpZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvY29uZmlnL2tpZS9jbGllbnQvS2llQ2xpZW50LmphdmE=)
 | `72.61% <0.00%> (-5.96%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...nal/schema/serializer/scalar/EnumWriteSchemas.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/diff?src=pr=tree#diff-Zm91bmRhdGlvbnMvZm91bmRhdGlvbi1wcm90b2J1Zi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvZm91bmRhdGlvbi9wcm90b2J1Zi9pbnRlcm5hbC9zY2hlbWEvc2VyaWFsaXplci9zY2FsYXIvRW51bVdyaXRlU2NoZW1hcy5qYXZh)
 | `86.53% <0.00%> (-5.30%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...ecomb/provider/pojo/PojoConsumerMetaRefresher.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/diff?src=pr=tree#diff-cHJvdmlkZXJzL3Byb3ZpZGVyLXBvam8vc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NlcnZpY2Vjb21iL3Byb3ZpZGVyL3Bvam8vUG9qb0NvbnN1bWVyTWV0YVJlZnJlc2hlci5qYXZh)
 | `75.60% <0.00%> (-2.44%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...omb/codec/protobuf/definition/ProtobufManager.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/diff?src=pr=tree#diff-Y29tbW9uL2NvbW1vbi1wcm90b2J1Zi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvY29kZWMvcHJvdG9idWYvZGVmaW5pdGlvbi9Qcm90b2J1Zk1hbmFnZXIuamF2YQ==)
 | `70.73% <0.00%> (-2.44%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...servicecomb/it/testcase/TestDataTypePrimitive.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/diff?src=pr=tree#diff-aW50ZWdyYXRpb24tdGVzdHMvaXQtY29uc3VtZXIvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NlcnZpY2Vjb21iL2l0L3Rlc3RjYXNlL1Rlc3REYXRhVHlwZVByaW1pdGl2ZS5qYXZh)
 | `100.00% <0.00%> (ø)` | `160.00% <0.00%> (+8.00%)` | |
   | 
[...ecomb/foundation/common/base/DynamicEnumCache.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/diff?src=pr=tree#diff-Zm91bmRhdGlvbnMvZm91bmRhdGlvbi1jb21tb24vc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NlcnZpY2Vjb21iL2ZvdW5kYXRpb24vY29tbW9uL2Jhc2UvRHluYW1pY0VudW1DYWNoZS5qYXZh)
 | `66.66% <0.00%> (ø)` | `0.00% <0.00%> (?%)` | |
   | 

[GitHub] [servicecomb-java-chassis] liubao68 commented on a change in pull request #2086: [#2081]add a test case for query with List

2020-11-26 Thread GitBox


liubao68 commented on a change in pull request #2086:
URL: 
https://github.com/apache/servicecomb-java-chassis/pull/2086#discussion_r531320628



##
File path: 
demo/demo-jaxrs/jaxrs-client/src/main/java/org/apache/servicecomb/demo/jaxrs/client/TestQueryParamWithListSchema.java
##
@@ -0,0 +1,154 @@
+/*
+ * 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.servicecomb.demo.jaxrs.client;
+
+import org.apache.servicecomb.demo.CategorizedTestCase;
+import org.apache.servicecomb.demo.TestMgr;
+import org.apache.servicecomb.provider.springmvc.reference.RestTemplateBuilder;
+import org.springframework.stereotype.Component;
+import org.springframework.web.client.RestTemplate;
+
+@Component
+public class TestQueryParamWithListSchema implements CategorizedTestCase {
+  private RestTemplate restTemplate = RestTemplateBuilder.create();
+
+  @Override
+  public void testAllTransport() throws Exception {
+testMulti();
+testCSV();
+testSSV();
+testTSV();
+testPipes();
+  }
+
+  @Override
+  public void testRestTransport() throws Exception {
+testMultiRest();
+testCSVRest();
+testSSVRest();
+testTSVRest();
+testPipesRest();
+  }
+
+  @Override
+  // highway do not handle empty/default/null
+  public void testHighwayTransport() throws Exception {
+testMultiHighway();
+testCSVHighway();
+testSSVHighway();
+testTSVHighway();
+testPipesHighway();
+  }
+
+  private void testCSVHighway() {
+TestMgr.check("null",
+restTemplate.getForObject("cse://jaxrs/queryList/queryListCSV?", 
String.class));
+  }
+
+  private void testCSVRest() {
+TestMgr.check("[]",
+restTemplate.getForObject("cse://jaxrs/queryList/queryListCSV?", 
String.class));
+  }
+
+  private void testSSV() {
+TestMgr.check("[1, 2]",
+
restTemplate.getForObject("cse://jaxrs/queryList/queryListSSV?queryList=1%202", 
String.class));
+TestMgr.check("[, ]",
+
restTemplate.getForObject("cse://jaxrs/queryList/queryListSSV?queryList=%20", 
String.class));
+TestMgr.check("[]",
+
restTemplate.getForObject("cse://jaxrs/queryList/queryListSSV?queryList=", 
String.class));
+  }
+
+  private void testTSVHighway() {
+TestMgr.check("null",
+restTemplate.getForObject("cse://jaxrs/queryList/queryListTSV?", 
String.class));
+  }
+
+  private void testTSVRest() {
+TestMgr.check("[]",
+restTemplate.getForObject("cse://jaxrs/queryList/queryListTSV?", 
String.class));
+  }
+
+  private void testTSV() {
+TestMgr.check("[1, 2]",
+restTemplate
+.getForObject("cse://jaxrs/queryList/queryListTSV?queryList={1}", 
String.class, "1\t2"));
+TestMgr.check("[, ]",
+
restTemplate.getForObject("cse://jaxrs/queryList/queryListTSV?queryList={1}", 
String.class, "\t"));
+TestMgr.check("[]",

Review comment:
   fixed 





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] fuziye01 commented on a change in pull request #755: Incremental synchronization of sc: sync between sc and syncer

2020-11-26 Thread GitBox


fuziye01 commented on a change in pull request #755:
URL: 
https://github.com/apache/servicecomb-service-center/pull/755#discussion_r531319883



##
File path: etc/conf/app.yaml
##
@@ -120,3 +120,6 @@ tracing:
 
 quota:
   kind:
+
+syncer:
+  enable: false

Review comment:
   已经修改

##
File path: datasource/etcd/event/instance_event_handler.go
##
@@ -144,3 +151,26 @@ func PublishInstanceEvent(evt sd.KvEvent, domainProject 
string, serviceKey *pb.M
}
}
 }
+
+func NotifySyncerInstanceEvent(evt sd.KvEvent, domainProject string, ms 
*pb.MicroService) {
+   msInstance := evt.KV.Value.(*pb.MicroServiceInstance)
+
+   serviceKey := "/cse-sr/ms/files/" + domainProject + "/" + ms.ServiceId

Review comment:
   已经修改

##
File path: server/server.go
##
@@ -173,6 +176,12 @@ func (s *ServiceCenterServer) startServices() {
// notifications
s.notifyService.Start()
 
+   // notify syncer
+   syncerEnable := config.GetBool("syncer.enable", false)

Review comment:
   已经修改





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] tianxiaoliang commented on pull request #764: SCB-2094 Bug fixes

2020-11-26 Thread GitBox


tianxiaoliang commented on pull request #764:
URL: 
https://github.com/apache/servicecomb-service-center/pull/764#issuecomment-734529579


   请描述bug复现过程和现象



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] tianxiaoliang commented on a change in pull request #764: SCB-2094 Bug fixes

2020-11-26 Thread GitBox


tianxiaoliang commented on a change in pull request #764:
URL: 
https://github.com/apache/servicecomb-service-center/pull/764#discussion_r531317843



##
File path: server/core/microservice.go
##
@@ -88,10 +88,11 @@ func prepareSelfRegistration() {
 }
 
 func AddDefaultContextValue(ctx context.Context) context.Context {
-   return util.SetContext(util.SetContext(util.SetDomainProject(ctx,
+   return 
util.SetContext(util.SetContext(util.SetContext(util.SetDomainProject(ctx,
RegistryDomain, RegistryProject),
CtxScSelf, true),
-   CtxScRegistry, "1")
+   CtxScRegistry, "1"),

Review comment:
   magic number





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[servicecomb-java-chassis] branch master updated: Scb 2128 support dynamic single value enum (#2080)

2020-11-26 Thread liubao
This is an automated email from the ASF dual-hosted git repository.

liubao pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/servicecomb-java-chassis.git


The following commit(s) were added to refs/heads/master by this push:
 new 4f58467  Scb 2128 support dynamic single value enum (#2080)
4f58467 is described below

commit 4f5846753c83e184aaecd87a713a47b74810e473
Author: wujimin 
AuthorDate: Fri Nov 27 09:37:18 2020 +0800

Scb 2128 support dynamic single value enum (#2080)

* [SCB-2128] support dynamic single value enum

* [SCB-2128] enhance swagger generator of jdk enum and dynamic enum
---
 .../demo/springmvc/server/CodeFirstSpringmvc.java  |   2 +-
 .../foundation/common/base/DynamicEnum.java|  42 +
 .../foundation/common/base/DynamicEnumCache.java   |  82 
 .../foundation/common/base/EnumUtils.java  |  46 +
 .../foundation/common/base/DynamicEnumTest.java|  87 +
 .../deserializer/scalar/EnumsReadSchemas.java  |  20 
 .../schema/serializer/scalar/EnumWriteSchemas.java |   7 ++
 .../apache/servicecomb/it/schema/DynamicColor.java |  42 +
 .../apache/servicecomb/it/junit/ITJUnitUtils.java  |   4 +
 .../it/testcase/TestDataTypePrimitive.java |  37 
 .../servicecomb/it/schema/DataTypeJaxrsSchema.java |  12 +++
 .../servicecomb/it/schema/DataTypePojoSchema.java  |   4 +
 .../apache/servicecomb/swagger/SwaggerUtils.java   |  14 ++-
 .../swagger/extend/ModelResolverExt.java   |  27 ++
 .../swagger/extend/PropertyModelConverterExt.java  |  59 
 .../servicecomb/swagger/extend/SwaggerEnum.java| 103 +
 .../introspector/JsonPropertyIntrospector.java |  17 +++-
 .../core/processor/annotation/AnnotationUtils.java |   4 +-
 .../processor/parameter/EnumPostProcessor.java |  93 +++
 .../response/DefaultResponseTypeProcessor.java |   4 +-
 ...cecomb.swagger.generator.OperationPostProcessor |  18 
 .../src/test/resources/schemas/allMethod.yaml  |   1 +
 .../src/test/resources/schemas/allType.yaml|   1 +
 .../src/test/resources/schemas/multiParam.yaml |   1 +
 .../servicecomb/swagger/generator/jaxrs/Echo.java  |  25 -
 .../swagger/generator/jaxrs/TestJaxrs.java |  10 ++
 .../generator/jaxrs/model/enums/DynamicStatus.java |  43 +
 .../jaxrs/model/enums/DynamicStatusBeanParam.java  |  27 ++
 .../jaxrs/model/enums/DynamicStatusModel.java  |  24 +
 .../generator/jaxrs/model/enums/JdkStatus.java |  27 ++
 .../jaxrs/model/enums/JdkStatusBeanParam.java  |  27 ++
 .../jaxrs/model/enums/JdkStatusModel.java  |  24 +
 .../test/resources/schemas/dynamicStatusEnum.yaml  |  81 
 .../src/test/resources/schemas/jdkStatusEnum.yaml  |  78 
 34 files changed, 1065 insertions(+), 28 deletions(-)

diff --git 
a/demo/demo-springmvc/springmvc-server/src/main/java/org/apache/servicecomb/demo/springmvc/server/CodeFirstSpringmvc.java
 
b/demo/demo-springmvc/springmvc-server/src/main/java/org/apache/servicecomb/demo/springmvc/server/CodeFirstSpringmvc.java
index 3ffe1a3..52fbe6d 100644
--- 
a/demo/demo-springmvc/springmvc-server/src/main/java/org/apache/servicecomb/demo/springmvc/server/CodeFirstSpringmvc.java
+++ 
b/demo/demo-springmvc/springmvc-server/src/main/java/org/apache/servicecomb/demo/springmvc/server/CodeFirstSpringmvc.java
@@ -335,7 +335,7 @@ public class CodeFirstSpringmvc {
 return name;
   }
 
-  enum NameType {
+  public enum NameType {
 abc,
 def
   }
diff --git 
a/swagger/swagger-generator/generator-core/src/main/java/org/apache/servicecomb/swagger/extend/introspector/JsonPropertyIntrospector.java
 
b/foundations/foundation-common/src/main/java/org/apache/servicecomb/foundation/common/base/DynamicEnum.java
similarity index 50%
copy from 
swagger/swagger-generator/generator-core/src/main/java/org/apache/servicecomb/swagger/extend/introspector/JsonPropertyIntrospector.java
copy to 
foundations/foundation-common/src/main/java/org/apache/servicecomb/foundation/common/base/DynamicEnum.java
index 0c55074..7889332 100644
--- 
a/swagger/swagger-generator/generator-core/src/main/java/org/apache/servicecomb/swagger/extend/introspector/JsonPropertyIntrospector.java
+++ 
b/foundations/foundation-common/src/main/java/org/apache/servicecomb/foundation/common/base/DynamicEnum.java
@@ -14,30 +14,38 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
+package org.apache.servicecomb.foundation.common.base;
 
-package org.apache.servicecomb.swagger.extend.introspector;
+import java.util.Objects;
 
-import org.apache.commons.lang3.StringUtils;
+import com.fasterxml.jackson.annotation.JsonValue;
 
-import com.fasterxml.jackson.annotation.JsonProperty;
+public abstract class DynamicEnum {
+  private T value;
 
-import 

[GitHub] [servicecomb-java-chassis] liubao68 merged pull request #2080: Scb 2128 support dynamic single value enum

2020-11-26 Thread GitBox


liubao68 merged pull request #2080:
URL: https://github.com/apache/servicecomb-java-chassis/pull/2080


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] wujimin commented on a change in pull request #2086: [#2081]add a test case for query with List

2020-11-26 Thread GitBox


wujimin commented on a change in pull request #2086:
URL: 
https://github.com/apache/servicecomb-java-chassis/pull/2086#discussion_r531311822



##
File path: 
demo/demo-jaxrs/jaxrs-client/src/main/java/org/apache/servicecomb/demo/jaxrs/client/TestQueryParamWithListSchema.java
##
@@ -0,0 +1,154 @@
+/*
+ * 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.servicecomb.demo.jaxrs.client;
+
+import org.apache.servicecomb.demo.CategorizedTestCase;
+import org.apache.servicecomb.demo.TestMgr;
+import org.apache.servicecomb.provider.springmvc.reference.RestTemplateBuilder;
+import org.springframework.stereotype.Component;
+import org.springframework.web.client.RestTemplate;
+
+@Component
+public class TestQueryParamWithListSchema implements CategorizedTestCase {
+  private RestTemplate restTemplate = RestTemplateBuilder.create();
+
+  @Override
+  public void testAllTransport() throws Exception {
+testMulti();
+testCSV();
+testSSV();
+testTSV();
+testPipes();
+  }
+
+  @Override
+  public void testRestTransport() throws Exception {
+testMultiRest();
+testCSVRest();
+testSSVRest();
+testTSVRest();
+testPipesRest();
+  }
+
+  @Override
+  // highway do not handle empty/default/null
+  public void testHighwayTransport() throws Exception {
+testMultiHighway();
+testCSVHighway();
+testSSVHighway();
+testTSVHighway();
+testPipesHighway();
+  }
+
+  private void testCSVHighway() {
+TestMgr.check("null",
+restTemplate.getForObject("cse://jaxrs/queryList/queryListCSV?", 
String.class));
+  }
+
+  private void testCSVRest() {
+TestMgr.check("[]",
+restTemplate.getForObject("cse://jaxrs/queryList/queryListCSV?", 
String.class));
+  }
+
+  private void testSSV() {
+TestMgr.check("[1, 2]",
+
restTemplate.getForObject("cse://jaxrs/queryList/queryListSSV?queryList=1%202", 
String.class));
+TestMgr.check("[, ]",
+
restTemplate.getForObject("cse://jaxrs/queryList/queryListSSV?queryList=%20", 
String.class));
+TestMgr.check("[]",
+
restTemplate.getForObject("cse://jaxrs/queryList/queryListSSV?queryList=", 
String.class));
+  }
+
+  private void testTSVHighway() {
+TestMgr.check("null",
+restTemplate.getForObject("cse://jaxrs/queryList/queryListTSV?", 
String.class));
+  }
+
+  private void testTSVRest() {
+TestMgr.check("[]",
+restTemplate.getForObject("cse://jaxrs/queryList/queryListTSV?", 
String.class));
+  }
+
+  private void testTSV() {
+TestMgr.check("[1, 2]",
+restTemplate
+.getForObject("cse://jaxrs/queryList/queryListTSV?queryList={1}", 
String.class, "1\t2"));
+TestMgr.check("[, ]",
+
restTemplate.getForObject("cse://jaxrs/queryList/queryListTSV?queryList={1}", 
String.class, "\t"));
+TestMgr.check("[]",

Review comment:
   无法区分下面两种场景?
   * List.of()
   * List.of("")  
   输出都是`[]`





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] zwwtj2014 closed issue #2087: CSE v2.5.3 Startup on the ARM error,could not load a native library: netty_tcnative

2020-11-26 Thread GitBox


zwwtj2014 closed issue #2087:
URL: https://github.com/apache/servicecomb-java-chassis/issues/2087


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] zwwtj2014 commented on issue #2087: CSE v2.5.3 Startup on the ARM error,could not load a native library: netty_tcnative

2020-11-26 Thread GitBox


zwwtj2014 commented on issue #2087:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2087#issuecomment-734525038


   OK,3Q



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] liubao68 commented on issue #2087: CSE v2.5.3 Startup on the ARM error,could not load a native library: netty_tcnative

2020-11-26 Thread GitBox


liubao68 commented on issue #2087:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2087#issuecomment-734524854


   
   tcnativ 需要升级到 2.0.31以上版本,才支持 ARM 
   
   ```
 
   io.netty
   netty-tcnative-boringssl-static
   ${tcnetty.version}
 
   ```
   
   这个版本已经不再提供三方件升级, 建议及时升级到 servicecomb 2.1.2及其以上版本。 



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] little-cui merged pull request #760: [SCB-2094] implement mongo init client

2020-11-26 Thread GitBox


little-cui merged pull request #760:
URL: https://github.com/apache/servicecomb-service-center/pull/760


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[servicecomb-service-center] branch master updated (5cdb5d9 -> d3f75b5)

2020-11-26 Thread littlecui
This is an automated email from the ASF dual-hosted git repository.

littlecui pushed a change to branch master
in repository 
https://gitbox.apache.org/repos/asf/servicecomb-service-center.git.


from 5cdb5d9  SCB-2094 Bug fixes (#763)
 add d3f75b5  [SCB-2094] implement mongo init client (#760)

No new revisions were added by this update.

Summary of changes:
 datasource/mongo/account_test.go   | 10 ---
 datasource/mongo/client/mongo.go   |  6 ++--
 datasource/mongo/client/mongo_test.go  |  2 +-
 .../heartbeat/heartbeatchecker/heartbeat_test.go   |  2 +-
 datasource/mongo/mongo.go  | 32 --
 datasource/mongo/ms_test.go|  2 +-
 etc/conf/app.conf  |  2 ++
 go.mod |  2 +-
 8 files changed, 38 insertions(+), 20 deletions(-)



[GitHub] [servicecomb-service-center] robotLJW commented on a change in pull request #760: [SCB-2094] implement mongo init client

2020-11-26 Thread GitBox


robotLJW commented on a change in pull request #760:
URL: 
https://github.com/apache/servicecomb-service-center/pull/760#discussion_r531280290



##
File path: datasource/mongo/mongo.go
##
@@ -51,15 +52,39 @@ func NewDataSource(opts datasource.Options) 
(datasource.DataSource, error) {
 }
 
 func (ds *DataSource) initialize() error {
+   var err error
// init heartbeat plugins
-   ds.initPlugins()
+   err = ds.initPlugins()
+   if err != nil {
+   return err
+   }
+   // init mongo client
+   err = ds.initClient()
+   if err != nil {
+   return err
+   }
return nil
 }
 
-func (ds *DataSource) initPlugins() {
-   kind := config.GetString("registry.heartbeat.kind", "")
+func (ds *DataSource) initPlugins() error {
+   kind := config.GetString("registry.heartbeat.kind", "heartbeatchecker")

Review comment:
   done





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] robotLJW commented on a change in pull request #760: [SCB-2094] implement mongo init client

2020-11-26 Thread GitBox


robotLJW commented on a change in pull request #760:
URL: 
https://github.com/apache/servicecomb-service-center/pull/760#discussion_r531270907



##
File path: datasource/mongo/mongo.go
##
@@ -51,15 +52,39 @@ func NewDataSource(opts datasource.Options) 
(datasource.DataSource, error) {
 }
 
 func (ds *DataSource) initialize() error {
+   var err error
// init heartbeat plugins
-   ds.initPlugins()
+   err = ds.initPlugins()
+   if err != nil {
+   return err
+   }
+   // init mongo client
+   err = ds.initClient()
+   if err != nil {
+   return err
+   }
return nil
 }
 
-func (ds *DataSource) initPlugins() {
-   kind := config.GetString("registry.heartbeat.kind", "")
+func (ds *DataSource) initPlugins() error {
+   kind := config.GetString("registry.heartbeat.kind", "heartbeatchecker")
err := heartbeat.Init(heartbeat.Options{PluginImplName: 
heartbeat.ImplName(kind)})
if err != nil {
log.Fatalf(err, "heartbeat init failed")
+   return err
+   }
+   return nil
+}
+
+func (ds *DataSource) initClient() error {
+   uri := config.GetString("registry.mongo.cluster.uri", 
"mongodb://localhost:27017", config.WithStandby("monogo_manager_cluster"))

Review comment:
   已经修改





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] zwwtj2014 opened a new issue #2087: CSE v2.5.3 Startup on the ARM error,could not load a native library: netty_tcnative

2020-11-26 Thread GitBox


zwwtj2014 opened a new issue #2087:
URL: https://github.com/apache/servicecomb-java-chassis/issues/2087


   ```log
   io.vertx.core.VertxException: OpenSSL is not available
at 
io.vertx.core.net.impl.SSLHelper.resolveEngineOptions(SSLHelper.java:76) 
~[vertx-core-3.8.3.jar:3.8.3]
at io.vertx.core.net.impl.SSLHelper.(SSLHelper.java:134) 
~[vertx-core-3.8.3.jar:3.8.3]
at 
io.vertx.core.http.impl.HttpClientImpl.(HttpClientImpl.java:131) 
~[vertx-core-3.8.3.jar:3.8.3]
at io.vertx.core.impl.VertxImpl.createHttpClient(VertxImpl.java:317) 
~[vertx-core-3.8.3.jar:3.8.3]
at 
org.apache.servicecomb.foundation.vertx.client.http.HttpClientPoolFactory.createClientPool(HttpClientPoolFactory.java:36)
 ~[foundation-vertx-1.3.1.jar:1.3.1]
...
   Caused by: java.lang.IllegalArgumentException: Failed to load any of the 
given libraries: [netty_tcnative_linux_aarch_64_fedora, 
netty_tcnative_linux_aarch_64, netty_tcnative_aarch_64, netty_tcnative]
at 
io.netty.util.internal.NativeLibraryLoader.loadFirstAvailable(NativeLibraryLoader.java:104)
 ~[netty-common-4.1.47.Final.jar:4.1.47.Final]
at io.netty.handler.ssl.OpenSsl.loadTcNative(OpenSsl.java:581) 
~[netty-handler-4.1.47.Final.jar:4.1.47.Final]
at io.netty.handler.ssl.OpenSsl.(OpenSsl.java:133) 
~[netty-handler-4.1.47.Final.jar:4.1.47.Final]
at 
io.vertx.core.net.impl.SSLHelper.resolveEngineOptions(SSLHelper.java:75) 
~[vertx-core-3.8.3.jar:3.8.3]
... 19 more
Suppressed: java.lang.UnsatisfiedLinkError: could not load a native 
library: netty_tcnative_linux_aarch_64_fedora
at 
io.netty.util.internal.NativeLibraryLoader.load(NativeLibraryLoader.java:226) 
...
Caused by: java.io.FileNotFoundException: 
META-INF/native/libnetty_tcnative_linux_aarch_64_fedora.so
at 
io.netty.util.internal.NativeLibraryLoader.load(NativeLibraryLoader.java:175) 
~[netty-common-4.1.47.Final.jar:4.1.47.Final]
... 23 more
Suppressed: java.lang.UnsatisfiedLinkError: no 
netty_tcnative_linux_aarch_64_fedora in java.library.path
...
Suppressed: java.lang.UnsatisfiedLinkError: no 
netty_tcnative_linux_aarch_64_fedora in java.library.path
...
Suppressed: java.lang.UnsatisfiedLinkError: could not load a native 
library: netty_tcnative_linux_aarch_64
...
   ```
   
   **need any other dependency?**



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] little-cui opened a new pull request #764: SCB-2094 Bug fixes

2020-11-26 Thread GitBox


little-cui opened a new pull request #764:
URL: https://github.com/apache/servicecomb-service-center/pull/764


   Follow this checklist to help us incorporate your contribution quickly and 
easily:
   
- [ ] Make sure there is a [JIRA 
issue](https://issues.apache.org/jira/browse/SCB) filed for the change (usually 
before you start working on it).  Trivial changes like typos do not require a 
JIRA issue.  Your pull request should address just this issue, without pulling 
in other changes.
- [ ] Each commit in the pull request should have a meaningful subject line 
and body.
- [ ] Format the pull request title like `[SCB-XXX] Fixes bug in 
ApproximateQuantiles`, where you replace `SCB-XXX` with the appropriate JIRA 
issue.
- [ ] Write a pull request description that is detailed enough to 
understand what the pull request does, how, and why.
- [ ] Run `go build` `go test` `go fmt` `go vet` to make sure basic checks 
pass. A more thorough check will be performed on your pull request 
automatically.
- [ ] If this contribution is large, please file an Apache [Individual 
Contributor License Agreement](https://www.apache.org/licenses/icla.pdf).
   
   ---
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] codecov-io commented on pull request #2080: Scb 2128 support dynamic single value enum

2020-11-26 Thread GitBox


codecov-io commented on pull request #2080:
URL: 
https://github.com/apache/servicecomb-java-chassis/pull/2080#issuecomment-734338401


   # 
[Codecov](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2080?src=pr=h1)
 Report
   > Merging 
[#2080](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2080?src=pr=desc)
 (2932e1a) into 
[master](https://codecov.io/gh/apache/servicecomb-java-chassis/commit/593a3a41ec16af2e2ad89bed388c2cc0e794e506?el=desc)
 (593a3a4) will **decrease** coverage by `0.02%`.
   > The diff coverage is `81.81%`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2080/graphs/tree.svg?width=650=150=pr=KXfDcr9rX2)](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2080?src=pr=tree)
   
   ```diff
   @@ Coverage Diff  @@
   ## master#2080  +/-   ##
   
   - Coverage 81.52%   81.49%   -0.03% 
   - Complexity 1297 1308  +11 
   
 Files  1434 1441   +7 
 Lines 3921939411 +192 
 Branches   3334 3353  +19 
   
   + Hits  3197432119 +145 
   - Misses 5790 5826  +36 
   - Partials   1455 1466  +11 
   ```
   
   
   | [Impacted 
Files](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2080?src=pr=tree)
 | Coverage Δ | Complexity Δ | |
   |---|---|---|---|
   | 
[...l/schema/deserializer/scalar/EnumsReadSchemas.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2080/diff?src=pr=tree#diff-Zm91bmRhdGlvbnMvZm91bmRhdGlvbi1wcm90b2J1Zi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvZm91bmRhdGlvbi9wcm90b2J1Zi9pbnRlcm5hbC9zY2hlbWEvZGVzZXJpYWxpemVyL3NjYWxhci9FbnVtc1JlYWRTY2hlbWFzLmphdmE=)
 | `54.34% <0.00%> (-13.22%)` | `0.00 <0.00> (ø)` | |
   | 
[...nal/schema/serializer/scalar/EnumWriteSchemas.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2080/diff?src=pr=tree#diff-Zm91bmRhdGlvbnMvZm91bmRhdGlvbi1wcm90b2J1Zi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvZm91bmRhdGlvbi9wcm90b2J1Zi9pbnRlcm5hbC9zY2hlbWEvc2VyaWFsaXplci9zY2FsYXIvRW51bVdyaXRlU2NoZW1hcy5qYXZh)
 | `86.53% <0.00%> (-5.30%)` | `0.00 <0.00> (ø)` | |
   | 
[...ervicecomb/foundation/common/base/DynamicEnum.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2080/diff?src=pr=tree#diff-Zm91bmRhdGlvbnMvZm91bmRhdGlvbi1jb21tb24vc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NlcnZpY2Vjb21iL2ZvdW5kYXRpb24vY29tbW9uL2Jhc2UvRHluYW1pY0VudW0uamF2YQ==)
 | `45.45% <45.45%> (ø)` | `0.00 <0.00> (?)` | |
   | 
[.../servicecomb/foundation/common/base/EnumUtils.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2080/diff?src=pr=tree#diff-Zm91bmRhdGlvbnMvZm91bmRhdGlvbi1jb21tb24vc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NlcnZpY2Vjb21iL2ZvdW5kYXRpb24vY29tbW9uL2Jhc2UvRW51bVV0aWxzLmphdmE=)
 | `57.14% <57.14%> (ø)` | `0.00 <0.00> (?)` | |
   | 
[...ecomb/foundation/common/base/DynamicEnumCache.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2080/diff?src=pr=tree#diff-Zm91bmRhdGlvbnMvZm91bmRhdGlvbi1jb21tb24vc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NlcnZpY2Vjb21iL2ZvdW5kYXRpb24vY29tbW9uL2Jhc2UvRHluYW1pY0VudW1DYWNoZS5qYXZh)
 | `66.66% <66.66%> (ø)` | `0.00 <0.00> (?)` | |
   | 
[...comb/swagger/extend/PropertyModelConverterExt.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2080/diff?src=pr=tree#diff-c3dhZ2dlci9zd2FnZ2VyLWdlbmVyYXRvci9nZW5lcmF0b3ItY29yZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvc3dhZ2dlci9leHRlbmQvUHJvcGVydHlNb2RlbENvbnZlcnRlckV4dC5qYXZh)
 | `93.75% <93.75%> (ø)` | `0.00 <0.00> (?)` | |
   | 
[...apache/servicecomb/swagger/extend/SwaggerEnum.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2080/diff?src=pr=tree#diff-c3dhZ2dlci9zd2FnZ2VyLWdlbmVyYXRvci9nZW5lcmF0b3ItY29yZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvc3dhZ2dlci9leHRlbmQvU3dhZ2dlckVudW0uamF2YQ==)
 | `94.11% <94.11%> (ø)` | `0.00 <0.00> (?)` | |
   | 
[.../org/apache/servicecomb/it/junit/ITJUnitUtils.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2080/diff?src=pr=tree#diff-aW50ZWdyYXRpb24tdGVzdHMvaXQtY29uc3VtZXIvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NlcnZpY2Vjb21iL2l0L2p1bml0L0lUSlVuaXRVdGlscy5qYXZh)
 | `67.90% <100.00%> (+0.40%)` | `25.00 <1.00> (+1.00)` | |
   | 
[...servicecomb/it/testcase/TestDataTypePrimitive.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2080/diff?src=pr=tree#diff-aW50ZWdyYXRpb24tdGVzdHMvaXQtY29uc3VtZXIvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NlcnZpY2Vjb21iL2l0L3Rlc3RjYXNlL1Rlc3REYXRhVHlwZVByaW1pdGl2ZS5qYXZh)
 | `100.00% <100.00%> (ø)` | `160.00 <8.00> (+8.00)` | |
   | 

[GitHub] [servicecomb-java-chassis] wujimin commented on issue #2081: servicecomb升级至2.1.2版本后,GET接口请求参数设置值方式修改

2020-11-26 Thread GitBox


wujimin commented on issue #2081:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2081#issuecomment-734332412


   准确地说,结果是`new String[]{""}`  
   元素个数为1,不是0  
   这符合语义  



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] codecov-io commented on pull request #2086: [#2081]add a test case for query with List

2020-11-26 Thread GitBox


codecov-io commented on pull request #2086:
URL: 
https://github.com/apache/servicecomb-java-chassis/pull/2086#issuecomment-734308562


   # 
[Codecov](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086?src=pr=h1)
 Report
   > Merging 
[#2086](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086?src=pr=desc)
 (b8f1924) into 
[master](https://codecov.io/gh/apache/servicecomb-java-chassis/commit/e65d46da2290d27bb89fb6b3aafe2e5244eed7b0?el=desc)
 (e65d46d) will **increase** coverage by `0.01%`.
   > The diff coverage is `100.00%`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/graphs/tree.svg?width=650=150=pr=KXfDcr9rX2)](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086?src=pr=tree)
   
   ```diff
   @@ Coverage Diff  @@
   ## master#2086  +/-   ##
   
   + Coverage 81.50%   81.51%   +0.01% 
   - Complexity 1299 1318  +19 
   
 Files  1435 1436   +1 
 Lines 3924039330  +90 
 Branches   3334 3334  
   
   + Hits  3198232061  +79 
   - Misses 5801 5812  +11 
 Partials   1457 1457  
   ```
   
   
   | [Impacted 
Files](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086?src=pr=tree)
 | Coverage Δ | Complexity Δ | |
   |---|---|---|---|
   | 
[...emo/jaxrs/client/TestQueryParamWithListSchema.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/diff?src=pr=tree#diff-ZGVtby9kZW1vLWpheHJzL2pheHJzLWNsaWVudC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvZGVtby9qYXhycy9jbGllbnQvVGVzdFF1ZXJ5UGFyYW1XaXRoTGlzdFNjaGVtYS5qYXZh)
 | `100.00% <100.00%> (ø)` | `19.00 <19.00> (?)` | |
   | 
[...ansport/rest/client/http/RestClientInvocation.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/diff?src=pr=tree#diff-dHJhbnNwb3J0cy90cmFuc3BvcnQtcmVzdC90cmFuc3BvcnQtcmVzdC1jbGllbnQvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NlcnZpY2Vjb21iL3RyYW5zcG9ydC9yZXN0L2NsaWVudC9odHRwL1Jlc3RDbGllbnRJbnZvY2F0aW9uLmphdmE=)
 | `94.66% <100.00%> (+0.18%)` | `0.00 <0.00> (ø)` | |
   | 
[...pache/servicecomb/config/kie/client/KieClient.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/diff?src=pr=tree#diff-ZHluYW1pYy1jb25maWcvY29uZmlnLWtpZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvY29uZmlnL2tpZS9jbGllbnQvS2llQ2xpZW50LmphdmE=)
 | `72.61% <0.00%> (-5.96%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...omb/codec/protobuf/definition/ProtobufManager.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/diff?src=pr=tree#diff-Y29tbW9uL2NvbW1vbi1wcm90b2J1Zi9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvY29kZWMvcHJvdG9idWYvZGVmaW5pdGlvbi9Qcm90b2J1Zk1hbmFnZXIuamF2YQ==)
 | `70.73% <0.00%> (-2.44%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...mb/serviceregistry/client/http/RestClientUtil.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/diff?src=pr=tree#diff-c2VydmljZS1yZWdpc3RyeS9yZWdpc3RyeS1zZXJ2aWNlLWNlbnRlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvc2VydmljZXJlZ2lzdHJ5L2NsaWVudC9odHRwL1Jlc3RDbGllbnRVdGlsLmphdmE=)
 | `75.70% <0.00%> (-1.87%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...egistry/client/http/ServiceRegistryClientImpl.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/diff?src=pr=tree#diff-c2VydmljZS1yZWdpc3RyeS9yZWdpc3RyeS1zZXJ2aWNlLWNlbnRlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvc2VydmljZXJlZ2lzdHJ5L2NsaWVudC9odHRwL1NlcnZpY2VSZWdpc3RyeUNsaWVudEltcGwuamF2YQ==)
 | `69.32% <0.00%> (-0.78%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...mmon/rest/codec/query/QueryCodecWithDelimiter.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086/diff?src=pr=tree#diff-Y29tbW9uL2NvbW1vbi1yZXN0L3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zZXJ2aWNlY29tYi9jb21tb24vcmVzdC9jb2RlYy9xdWVyeS9RdWVyeUNvZGVjV2l0aERlbGltaXRlci5qYXZh)
 | `100.00% <0.00%> (+4.76%)` | `0.00% <0.00%> (ø%)` | |
   
   --
   
   [Continue to review full report at 
Codecov](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086?src=pr=continue).
   > **Legend** - [Click here to learn 
more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute  (impact)`, `ø = not affected`, `? = missing data`
   > Powered by 
[Codecov](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086?src=pr=footer).
 Last update 
[e65d46d...b8f1924](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2086?src=pr=lastupdated).
 Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries 

[GitHub] [servicecomb-service-center] little-cui commented on a change in pull request #760: [SCB-2094] implement mongo init client

2020-11-26 Thread GitBox


little-cui commented on a change in pull request #760:
URL: 
https://github.com/apache/servicecomb-service-center/pull/760#discussion_r531011909



##
File path: datasource/mongo/mongo.go
##
@@ -51,15 +52,39 @@ func NewDataSource(opts datasource.Options) 
(datasource.DataSource, error) {
 }
 
 func (ds *DataSource) initialize() error {
+   var err error
// init heartbeat plugins
-   ds.initPlugins()
+   err = ds.initPlugins()
+   if err != nil {
+   return err
+   }
+   // init mongo client
+   err = ds.initClient()
+   if err != nil {
+   return err
+   }
return nil
 }
 
-func (ds *DataSource) initPlugins() {
-   kind := config.GetString("registry.heartbeat.kind", "")
+func (ds *DataSource) initPlugins() error {
+   kind := config.GetString("registry.heartbeat.kind", "heartbeatchecker")

Review comment:
   增加WithStandby("heartbeat_plugin")支持,同时在conf/app.conf增加该配置





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] liubao68 commented on pull request #2086: [#2081]add a test case for query with List

2020-11-26 Thread GitBox


liubao68 commented on pull request #2086:
URL: 
https://github.com/apache/servicecomb-java-chassis/pull/2086#issuecomment-734293887


   When running CI , find a bug, fix it too.
   
   [SCB-2131]when timeout exception, connect closed will trigger asynchr



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] jasononion commented on a change in pull request #755: Incremental synchronization of sc: sync between sc and syncer

2020-11-26 Thread GitBox


jasononion commented on a change in pull request #755:
URL: 
https://github.com/apache/servicecomb-service-center/pull/755#discussion_r530970598



##
File path: etc/conf/app.yaml
##
@@ -120,3 +120,6 @@ tracing:
 
 quota:
   kind:
+
+syncer:
+  enable: false

Review comment:
   改成enabled

##
File path: datasource/etcd/event/instance_event_handler.go
##
@@ -144,3 +151,26 @@ func PublishInstanceEvent(evt sd.KvEvent, domainProject 
string, serviceKey *pb.M
}
}
 }
+
+func NotifySyncerInstanceEvent(evt sd.KvEvent, domainProject string, ms 
*pb.MicroService) {
+   msInstance := evt.KV.Value.(*pb.MicroServiceInstance)
+
+   serviceKey := "/cse-sr/ms/files/" + domainProject + "/" + ms.ServiceId

Review comment:
   /cse-sr/ms/files/ 用常量

##
File path: server/server.go
##
@@ -173,6 +176,12 @@ func (s *ServiceCenterServer) startServices() {
// notifications
s.notifyService.Start()
 
+   // notify syncer
+   syncerEnable := config.GetBool("syncer.enable", false)

Review comment:
   这里的配置项对应修改一下





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] little-cui commented on a change in pull request #760: [SCB-2094] implement mongo init client

2020-11-26 Thread GitBox


little-cui commented on a change in pull request #760:
URL: 
https://github.com/apache/servicecomb-service-center/pull/760#discussion_r531010775



##
File path: datasource/mongo/mongo.go
##
@@ -51,15 +52,39 @@ func NewDataSource(opts datasource.Options) 
(datasource.DataSource, error) {
 }
 
 func (ds *DataSource) initialize() error {
+   var err error
// init heartbeat plugins
-   ds.initPlugins()
+   err = ds.initPlugins()
+   if err != nil {
+   return err
+   }
+   // init mongo client
+   err = ds.initClient()
+   if err != nil {
+   return err
+   }
return nil
 }
 
-func (ds *DataSource) initPlugins() {
-   kind := config.GetString("registry.heartbeat.kind", "")
+func (ds *DataSource) initPlugins() error {
+   kind := config.GetString("registry.heartbeat.kind", "heartbeatchecker")
err := heartbeat.Init(heartbeat.Options{PluginImplName: 
heartbeat.ImplName(kind)})
if err != nil {
log.Fatalf(err, "heartbeat init failed")
+   return err
+   }
+   return nil
+}
+
+func (ds *DataSource) initClient() error {
+   uri := config.GetString("registry.mongo.cluster.uri", 
"mongodb://localhost:27017", config.WithStandby("monogo_manager_cluster"))

Review comment:
   WithStandby("manager_cluster"),跟etcd使用统一的配置





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] yangyinqi closed issue #2085: ServiceComb如何支持soap类型的接口,或者怎么处理xml格式的消息呢?

2020-11-26 Thread GitBox


yangyinqi closed issue #2085:
URL: https://github.com/apache/servicecomb-java-chassis/issues/2085


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] yangyinqi commented on issue #2085: ServiceComb如何支持soap类型的接口,或者怎么处理xml格式的消息呢?

2020-11-26 Thread GitBox


yangyinqi commented on issue #2085:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2085#issuecomment-734279386


   > servicecomb 没正式提供 xml 支持。 扩展机制适用的范围比较小。
   
   好的,明白了,多谢。



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] liubao68 merged pull request #2084: [SCB-2130]vert.x 3.9.4 ping/pong message will call on message

2020-11-26 Thread GitBox


liubao68 merged pull request #2084:
URL: https://github.com/apache/servicecomb-java-chassis/pull/2084


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[servicecomb-java-chassis] branch master updated: [SCB-2130]vert.x 3.9.4 ping/pong message will call on message (#2084)

2020-11-26 Thread liubao
This is an automated email from the ASF dual-hosted git repository.

liubao pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/servicecomb-java-chassis.git


The following commit(s) were added to refs/heads/master by this push:
 new e65d46d  [SCB-2130]vert.x 3.9.4 ping/pong message will call on message 
(#2084)
e65d46d is described below

commit e65d46da2290d27bb89fb6b3aafe2e5244eed7b0
Author: bao liu 
AuthorDate: Thu Nov 26 20:10:53 2020 +0800

[SCB-2130]vert.x 3.9.4 ping/pong message will call on message (#2084)
---
 .../ConfigCenterConfigurationSourceImpl.java   |  2 +-
 .../config/client/ConfigCenterClient.java  | 30 ++
 .../client/http/WebsocketClientUtil.java   |  8 +-
 3 files changed, 28 insertions(+), 12 deletions(-)

diff --git 
a/dynamic-config/config-cc/src/main/java/org/apache/servicecomb/config/archaius/sources/ConfigCenterConfigurationSourceImpl.java
 
b/dynamic-config/config-cc/src/main/java/org/apache/servicecomb/config/archaius/sources/ConfigCenterConfigurationSourceImpl.java
index 1c2a5cc..eb40703 100644
--- 
a/dynamic-config/config-cc/src/main/java/org/apache/servicecomb/config/archaius/sources/ConfigCenterConfigurationSourceImpl.java
+++ 
b/dynamic-config/config-cc/src/main/java/org/apache/servicecomb/config/archaius/sources/ConfigCenterConfigurationSourceImpl.java
@@ -145,7 +145,7 @@ public class ConfigCenterConfigurationSourceImpl implements 
ConfigCenterConfigur
 LOGGER.error("action: {} is invalid.", action);
 return;
   }
-  LOGGER.warn("Config value cache changed: action:{}; item:{}", action, 
configuration.keySet());
+  LOGGER.info("Config value cache changed: action:{}; item:{}", action, 
configuration.keySet());
 }
   }
 }
diff --git 
a/dynamic-config/config-cc/src/main/java/org/apache/servicecomb/config/client/ConfigCenterClient.java
 
b/dynamic-config/config-cc/src/main/java/org/apache/servicecomb/config/client/ConfigCenterClient.java
index 6a40c85..26e7314 100644
--- 
a/dynamic-config/config-cc/src/main/java/org/apache/servicecomb/config/client/ConfigCenterClient.java
+++ 
b/dynamic-config/config-cc/src/main/java/org/apache/servicecomb/config/client/ConfigCenterClient.java
@@ -243,16 +243,26 @@ public class ConfigCenterClient {
 // ignore, just prevent NPE.
   });
   asyncResult.result().frameHandler(frame -> {
-Buffer action = frame.binaryData();
-LOGGER.info("watching config recieved {}", action);
-Map mAction = action.toJsonObject().getMap();
-if ("CREATE".equals(mAction.get("action"))) {
-  //event loop can not be blocked,we just keep nothing changed 
in push mode
-  refreshConfig(configCenter, false);
-} else if ("MEMBER_CHANGE".equals(mAction.get("action"))) {
-  refreshMembers(memberdis);
-} else {
-  parseConfigUtils.refreshConfigItemsIncremental(mAction);
+if (frame.isText() || frame.isBinary()) {
+  Buffer action = frame.binaryData();
+  LOGGER.debug("watching config received {}", action);
+  Map mAction = null;
+
+  try {
+mAction = action.toJsonObject().getMap();
+  } catch (Exception e) {
+LOGGER.error("parse config item failed.", e);
+return;
+  }
+
+  if ("CREATE".equals(mAction.get("action"))) {
+//event loop can not be blocked,we just keep nothing 
changed in push mode
+refreshConfig(configCenter, false);
+  } else if ("MEMBER_CHANGE".equals(mAction.get("action"))) {
+refreshMembers(memberdis);
+  } else {
+parseConfigUtils.refreshConfigItemsIncremental(mAction);
+  }
 }
   });
   startHeartBeatThread(asyncResult.result());
diff --git 
a/service-registry/registry-service-center/src/main/java/org/apache/servicecomb/serviceregistry/client/http/WebsocketClientUtil.java
 
b/service-registry/registry-service-center/src/main/java/org/apache/servicecomb/serviceregistry/client/http/WebsocketClientUtil.java
index cb9aef5..c646358 100644
--- 
a/service-registry/registry-service-center/src/main/java/org/apache/servicecomb/serviceregistry/client/http/WebsocketClientUtil.java
+++ 
b/service-registry/registry-service-center/src/main/java/org/apache/servicecomb/serviceregistry/client/http/WebsocketClientUtil.java
@@ -78,7 +78,13 @@ public final class WebsocketClientUtil {
   asyncResult.result().pongHandler(pong -> {
 // ignore, just prevent NPE.
   });
-  asyncResult.result().frameHandler((frame) -> 
onMessage.handle(frame.binaryData()));
+  

[GitHub] [servicecomb-java-chassis] liubao68 edited a comment on issue #2085: ServiceComb如何支持soap类型的接口,或者怎么处理xml格式的消息呢?

2020-11-26 Thread GitBox


liubao68 edited a comment on issue #2085:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2085#issuecomment-734231042


   servicecomb 没正式提供 xml 支持。 扩展机制适用的范围比较小。 



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] liubao68 commented on issue #2085: ServiceComb如何支持soap类型的接口,或者怎么处理xml格式的消息呢?

2020-11-26 Thread GitBox


liubao68 commented on issue #2085:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2085#issuecomment-734231042


   servicecomb 没正式提供 xml 支持。 扩展机制试用的范围比较小。 



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] tianxiaoliang commented on a change in pull request #736: [SCB-2093]Add roles to control access to API resources

2020-11-26 Thread GitBox


tianxiaoliang commented on a change in pull request #736:
URL: 
https://github.com/apache/servicecomb-service-center/pull/736#discussion_r530946448



##
File path: pkg/rbacframe/api.go
##
@@ -74,3 +76,27 @@ func Authenticate(tokenStr string, pub *rsa.PublicKey) 
(interface{}, error) {
}
return claims, nil
 }
+
+// TypeOfRole return role list string
+func TypeOfRole(v interface{}) ([]string, error) {

Review comment:
   没问题,改吧,不能用反射做断言





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] hityc2019 commented on a change in pull request #736: [SCB-2093]Add roles to control access to API resources

2020-11-26 Thread GitBox


hityc2019 commented on a change in pull request #736:
URL: 
https://github.com/apache/servicecomb-service-center/pull/736#discussion_r530943868



##
File path: pkg/rbacframe/api.go
##
@@ -74,3 +76,27 @@ func Authenticate(tokenStr string, pub *rsa.PublicKey) 
(interface{}, error) {
}
return claims, nil
 }
+
+// TypeOfRole return role list string
+func TypeOfRole(v interface{}) ([]string, error) {

Review comment:
   这里面确实是roles啊!应该是ClaimsRole改成ClaimsRoles更准确





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] tianxiaoliang commented on a change in pull request #736: [SCB-2093]Add roles to control access to API resources

2020-11-26 Thread GitBox


tianxiaoliang commented on a change in pull request #736:
URL: 
https://github.com/apache/servicecomb-service-center/pull/736#discussion_r530939136



##
File path: pkg/rbacframe/api.go
##
@@ -74,3 +76,27 @@ func Authenticate(tokenStr string, pub *rsa.PublicKey) 
(interface{}, error) {
}
return claims, nil
 }
+
+// TypeOfRole return role list string
+func TypeOfRole(v interface{}) ([]string, error) {

Review comment:
   不要搞复杂,这里面就是roles,没有role





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] tianxiaoliang commented on a change in pull request #759: [SCB-2094] implement mongo instance/dependence/engine interface

2020-11-26 Thread GitBox


tianxiaoliang commented on a change in pull request #759:
URL: 
https://github.com/apache/servicecomb-service-center/pull/759#discussion_r530937313



##
File path: datasource/mongo/database.go
##
@@ -65,13 +67,17 @@ const (
ServiceAlias   = "serviceinfo.alias"
ServiceVersion = "serviceinfo.version"
ServiceSchemas = "serviceinfo.schemas"
+   ServiceEnvironment = "serviceinfo.environment"
RuleAttribute  = "ruleinfo.attribute"
RulePattern= "ruleinfo.pattern"
RuleModTime= "ruleinfo.modtimestamp"
RuleDescription= "ruleinfo.description"
RuleRuletype   = "ruleinfo.ruletype"
SchemaInfo = "schemainfo"
SchemaSummary  = "schemasummary"
+   DepConEnv  = "consumerdependency.consumer.environment"

Review comment:
   here

##
File path: datasource/mongo/database.go
##
@@ -31,8 +31,8 @@ const (
AccountTokenExpirationTime = "tokenexpirationtime"
AccountCurrentPassword = "currentpassword"
AccountStatus  = "status"
-   InstanceID = "instanceinfo.instanceid"
-   ServiceID  = "instanceinfo.serviceid"
+   InstanceInstanceID = "instanceinfo.instanceid"

Review comment:
   here





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] tianxiaoliang commented on a change in pull request #759: [SCB-2094] implement mongo instance/dependence/engine interface

2020-11-26 Thread GitBox


tianxiaoliang commented on a change in pull request #759:
URL: 
https://github.com/apache/servicecomb-service-center/pull/759#discussion_r530927638



##
File path: datasource/mongo/database.go
##
@@ -65,13 +67,17 @@ const (
ServiceAlias   = "serviceinfo.alias"
ServiceVersion = "serviceinfo.version"
ServiceSchemas = "serviceinfo.schemas"
+   ServiceEnvironment = "serviceinfo.environment"
RuleAttribute  = "ruleinfo.attribute"
RulePattern= "ruleinfo.pattern"
RuleModTime= "ruleinfo.modtimestamp"
RuleDescription= "ruleinfo.description"
RuleRuletype   = "ruleinfo.ruletype"
SchemaInfo = "schemainfo"
SchemaSummary  = "schemasummary"
+   DepConEnv  = "consumerdependency.consumer.environment"
+   DepConAppID= "consumerdependency.consumer.appid"

Review comment:
   这consume在2处有,什么意思,不是冗余信息?

##
File path: datasource/mongo/database.go
##
@@ -31,8 +31,8 @@ const (
AccountTokenExpirationTime = "tokenexpirationtime"
AccountCurrentPassword = "currentpassword"
AccountStatus  = "status"
-   InstanceID = "instanceinfo.instanceid"
-   ServiceID  = "instanceinfo.serviceid"
+   InstanceInstanceID = "instanceinfo.instanceid"

Review comment:
   here





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] tianxiaoliang commented on a change in pull request #759: [SCB-2094] implement mongo instance/dependence/engine interface

2020-11-26 Thread GitBox


tianxiaoliang commented on a change in pull request #759:
URL: 
https://github.com/apache/servicecomb-service-center/pull/759#discussion_r530926496



##
File path: datasource/mongo/heartbeat/heartbeatchecker/heartbeat_test.go
##
@@ -57,8 +57,8 @@ func TestUpdateInstanceRefreshTime(t *testing.T) {
err = updateInstanceRefreshTime(context.Background(), 
instance1.InstanceInfo.ServiceId, instance1.InstanceInfo.InstanceId)
assert.Equal(t, nil, err)
filter := bson.M{
-   mongo.InstanceID: instance1.InstanceInfo.InstanceId,
-   mongo.ServiceID:  instance1.InstanceInfo.ServiceId,
+   mongo.InstanceInstanceID: 
instance1.InstanceInfo.InstanceId,
+   mongo.InstanceServiceID:  
instance1.InstanceInfo.ServiceId,

Review comment:
   这名字重复,很多这种问题,统一改





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] tianxiaoliang commented on a change in pull request #759: [SCB-2094] implement mongo instance/dependence/engine interface

2020-11-26 Thread GitBox


tianxiaoliang commented on a change in pull request #759:
URL: 
https://github.com/apache/servicecomb-service-center/pull/759#discussion_r530926496



##
File path: datasource/mongo/heartbeat/heartbeatchecker/heartbeat_test.go
##
@@ -57,8 +57,8 @@ func TestUpdateInstanceRefreshTime(t *testing.T) {
err = updateInstanceRefreshTime(context.Background(), 
instance1.InstanceInfo.ServiceId, instance1.InstanceInfo.InstanceId)
assert.Equal(t, nil, err)
filter := bson.M{
-   mongo.InstanceID: instance1.InstanceInfo.InstanceId,
-   mongo.ServiceID:  instance1.InstanceInfo.ServiceId,
+   mongo.InstanceInstanceID: 
instance1.InstanceInfo.InstanceId,
+   mongo.InstanceServiceID:  
instance1.InstanceInfo.ServiceId,

Review comment:
   这名字重复





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] liubao68 commented on issue #2081: servicecomb升级至2.1.2版本后,GET接口请求参数设置值方式修改

2020-11-26 Thread GitBox


liubao68 commented on issue #2081:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2081#issuecomment-734201884


   加了个测试用例: https://github.com/apache/servicecomb-java-chassis/pull/2086 , 
看下是否符合你的场景。 



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] liubao68 opened a new pull request #2086: [#2081]add a test case for query with List

2020-11-26 Thread GitBox


liubao68 opened a new pull request #2086:
URL: https://github.com/apache/servicecomb-java-chassis/pull/2086


   Follow this checklist to help us incorporate your contribution quickly and 
easily:
   
- [ ] Make sure there is a [JIRA 
issue](https://issues.apache.org/jira/browse/SCB) filed for the change (usually 
before you start working on it).  Trivial changes like typos do not require a 
JIRA issue.  Your pull request should address just this issue, without pulling 
in other changes.
- [ ] Each commit in the pull request should have a meaningful subject line 
and body.
- [ ] Format the pull request title like `[SCB-XXX] Fixes bug in 
ApproximateQuantiles`, where you replace `SCB-XXX` with the appropriate JIRA 
issue.
- [ ] Write a pull request description that is detailed enough to 
understand what the pull request does, how, and why.
- [ ] Run `mvn clean install -Pit` to make sure basic checks pass. A more 
thorough check will be performed on your pull request automatically.
- [ ] If this contribution is large, please file an Apache [Individual 
Contributor License Agreement](https://www.apache.org/licenses/icla.pdf).
   
   ---
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] yangyinqi commented on issue #2085: ServiceComb如何支持soap类型的接口,或者怎么处理xml格式的消息呢?

2020-11-26 Thread GitBox


yangyinqi commented on issue #2085:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2085#issuecomment-734199556


   找到了这个文档资料 
[https://docs.servicecomb.io/java-chassis/zh_CN/general-development/produceprocess/](url),可以实现返回扩展的格式。另外想问下有没有通用一些的支持方法,框架层面的注解或者配置之类的。



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[servicecomb-service-center] branch master updated: SCB-2094 Bug fixes (#763)

2020-11-26 Thread tianxiaoliang
This is an automated email from the ASF dual-hosted git repository.

tianxiaoliang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/servicecomb-service-center.git


The following commit(s) were added to refs/heads/master by this push:
 new 5cdb5d9  SCB-2094 Bug fixes (#763)
5cdb5d9 is described below

commit 5cdb5d901e13e1e4a4972e71cff9d44e15272897
Author: little-cui 
AuthorDate: Thu Nov 26 17:39:06 2020 +0800

SCB-2094 Bug fixes (#763)

* SCB-2094 Bug fixes

* SCB-2094 Bug fixes
---
 etc/conf/app.yaml   | 4 +++-
 server/config/config.go | 2 +-
 server/config/server.go | 2 +-
 3 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/etc/conf/app.yaml b/etc/conf/app.yaml
index efde076..7088ff8 100644
--- a/etc/conf/app.yaml
+++ b/etc/conf/app.yaml
@@ -91,8 +91,10 @@ registry:
 ttl:
 
   schema:
+# if want disable Test Schema, SchemaDisable set true
 disable: false
-editable: true
+# if want disable modification of Schema in production environment, 
SchemaEditable set false
+editable: false
   # enable to register sc itself when startup
   selfRegister: 1
 
diff --git a/server/config/config.go b/server/config/config.go
index 66f6924..59d1575 100644
--- a/server/config/config.go
+++ b/server/config/config.go
@@ -179,7 +179,7 @@ func newInfo() ServerInformation {
InstanceTTL:  GetInt64("registry.instance.ttl", 
0, WithENV("INSTANCE_TTL")),
 
SchemaDisable:  GetBool("registry.schema.disable", 
false, WithENV("SCHEMA_DISABLE")),
-   SchemaEditable: GetBool("registry.schema.editable", 
true, WithENV("SCHEMA_EDITABLE")),
+   SchemaEditable: GetBool("registry.schema.editable", 
false, WithENV("SCHEMA_EDITABLE")),
 
EnableRBAC: GetBool("rbac.enable", false, 
WithStandby("rbac_enabled")),
 
diff --git a/server/config/server.go b/server/config/server.go
index af29b6b..f48a63e 100644
--- a/server/config/server.go
+++ b/server/config/server.go
@@ -75,7 +75,7 @@ type ServerConfig struct {
 
// if want disable Test Schema, SchemaDisable set true
SchemaDisable bool `json:"schemaDisable"`
-   // if want disable modification of Schema, SchemaEditable set false
+   // if want disable modification of Schema in production environment, 
SchemaEditable set false
SchemaEditable bool `json:"-"`
 
// instance ttl in seconds



[GitHub] [servicecomb-service-center] tianxiaoliang merged pull request #763: SCB-2094 Bug fixes

2020-11-26 Thread GitBox


tianxiaoliang merged pull request #763:
URL: https://github.com/apache/servicecomb-service-center/pull/763


   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] liubao68 edited a comment on issue #2081: servicecomb升级至2.1.2版本后,GET接口请求参数设置值方式修改

2020-11-26 Thread GitBox


liubao68 edited a comment on issue #2081:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2081#issuecomment-734186595


   补充问下, `我们接口定义的请求参数是List ,然后传个空,接收下来是[null]`, 这个你是怎么请求的? 我用最新代码测试了下, 结果是空数组。 
下面的测试用例是可以通过的:
   
   ```
 @Path("queryListMULTI")
 @GET
 public String queryListMULTI(@ApiParam(collectionFormat = "multi") 
@QueryParam("queryList") List queryList) {
   return queryList == null ? "null" : queryList.toString();
 }
   
   TestMgr.check("[]",
   
restTemplate.getForObject("cse://jaxrs/queryList/queryListMULTI?queryList=", 
String.class));
   ```



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] liubao68 commented on issue #2081: servicecomb升级至2.1.2版本后,GET接口请求参数设置值方式修改

2020-11-26 Thread GitBox


liubao68 commented on issue #2081:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2081#issuecomment-734186595


   补充问下, `我们接口定义的请求参数是List ,然后传个空,接收下来是[null]`, 这个你是怎么请求的? 为用最新代码测试了下, 结果是空数组。 
下面的测试用例是可以通过的:
   
   ```
 @Path("queryListMULTI")
 @GET
 public String queryListMULTI(@ApiParam(collectionFormat = "multi") 
@QueryParam("queryList") List queryList) {
   return queryList == null ? "null" : queryList.toString();
 }
   
   TestMgr.check("[]",
   
restTemplate.getForObject("cse://jaxrs/queryList/queryListMULTI?queryList=", 
String.class));
   ```



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-service-center] xzccfzy commented on a change in pull request #759: [SCB-2094] implement mongo instance/dependence/engine interface

2020-11-26 Thread GitBox


xzccfzy commented on a change in pull request #759:
URL: 
https://github.com/apache/servicecomb-service-center/pull/759#discussion_r530887764



##
File path: datasource/mongo/dep.go
##
@@ -19,21 +19,338 @@ package mongo
 
 import (
"context"
+   "fmt"
+   "github.com/apache/servicecomb-service-center/datasource/etcd/path"
+   serviceUtil 
"github.com/apache/servicecomb-service-center/datasource/etcd/util"

Review comment:
   ok





This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[servicecomb-service-center] branch test updated (c352986 -> fd031ed)

2020-11-26 Thread littlecui
This is an automated email from the ASF dual-hosted git repository.

littlecui pushed a change to branch test
in repository 
https://gitbox.apache.org/repos/asf/servicecomb-service-center.git.


omit c352986  SCB-2094 Add Dlock API
 add c4c0c22  SCB-2094 Add Dlock API (#762)
 add c9ce76d  SCB-2094 Bug fixes
 add fd031ed  SCB-2094 Bug fixes

This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version.  This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:

 * -- * -- B -- O -- O -- O   (c352986)
\
 N -- N -- N   refs/heads/test (fd031ed)

You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.

Any revisions marked "omit" are not gone; other references still
refer to them.  Any revisions marked "discard" are gone forever.

No new revisions were added by this update.

Summary of changes:
 etc/conf/app.yaml   | 4 +++-
 server/config/config.go | 2 +-
 server/config/server.go | 2 +-
 server/service/rbac/rbac.go | 2 +-
 4 files changed, 6 insertions(+), 4 deletions(-)



[GitHub] [servicecomb-service-center] little-cui opened a new pull request #763: SCB-2094 Bug fixes

2020-11-26 Thread GitBox


little-cui opened a new pull request #763:
URL: https://github.com/apache/servicecomb-service-center/pull/763


   Follow this checklist to help us incorporate your contribution quickly and 
easily:
   
- [ ] Make sure there is a [JIRA 
issue](https://issues.apache.org/jira/browse/SCB) filed for the change (usually 
before you start working on it).  Trivial changes like typos do not require a 
JIRA issue.  Your pull request should address just this issue, without pulling 
in other changes.
- [ ] Each commit in the pull request should have a meaningful subject line 
and body.
- [ ] Format the pull request title like `[SCB-XXX] Fixes bug in 
ApproximateQuantiles`, where you replace `SCB-XXX` with the appropriate JIRA 
issue.
- [ ] Write a pull request description that is detailed enough to 
understand what the pull request does, how, and why.
- [ ] Run `go build` `go test` `go fmt` `go vet` to make sure basic checks 
pass. A more thorough check will be performed on your pull request 
automatically.
- [ ] If this contribution is large, please file an Apache [Individual 
Contributor License Agreement](https://www.apache.org/licenses/icla.pdf).
   
   ---
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] codecov-io commented on pull request #2084: [SCB-2130]vert.x 3.9.4 ping/pong message will call on message

2020-11-26 Thread GitBox


codecov-io commented on pull request #2084:
URL: 
https://github.com/apache/servicecomb-java-chassis/pull/2084#issuecomment-734163165


   # 
[Codecov](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2084?src=pr=h1)
 Report
   > Merging 
[#2084](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2084?src=pr=desc)
 (a61cf33) into 
[master](https://codecov.io/gh/apache/servicecomb-java-chassis/commit/593a3a41ec16af2e2ad89bed388c2cc0e794e506?el=desc)
 (593a3a4) will **decrease** coverage by `0.05%`.
   > The diff coverage is `21.05%`.
   
   [![Impacted file tree 
graph](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2084/graphs/tree.svg?width=650=150=pr=KXfDcr9rX2)](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2084?src=pr=tree)
   
   ```diff
   @@ Coverage Diff  @@
   ## master#2084  +/-   ##
   
   - Coverage 81.52%   81.47%   -0.06% 
   - Complexity 1297 1299   +2 
   
 Files  1434 1435   +1 
 Lines 3921939240  +21 
 Branches   3334 3334  
   
   - Hits  3197431970   -4 
   - Misses 5790 5812  +22 
   - Partials   1455 1458   +3 
   ```
   
   
   | [Impacted 
Files](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2084?src=pr=tree)
 | Coverage Δ | Complexity Δ | |
   |---|---|---|---|
   | 
[.../servicecomb/config/client/ConfigCenterClient.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2084/diff?src=pr=tree#diff-ZHluYW1pYy1jb25maWcvY29uZmlnLWNjL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zZXJ2aWNlY29tYi9jb25maWcvY2xpZW50L0NvbmZpZ0NlbnRlckNsaWVudC5qYXZh)
 | `52.54% <0.00%> (-1.38%)` | `0.00 <0.00> (ø)` | |
   | 
[...rviceregistry/client/http/WebsocketClientUtil.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2084/diff?src=pr=tree#diff-c2VydmljZS1yZWdpc3RyeS9yZWdpc3RyeS1zZXJ2aWNlLWNlbnRlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvc2VydmljZXJlZ2lzdHJ5L2NsaWVudC9odHRwL1dlYnNvY2tldENsaWVudFV0aWwuamF2YQ==)
 | `73.68% <75.00%> (-0.39%)` | `0.00 <0.00> (ø)` | |
   | 
[...s/sources/ConfigCenterConfigurationSourceImpl.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2084/diff?src=pr=tree#diff-ZHluYW1pYy1jb25maWcvY29uZmlnLWNjL3NyYy9tYWluL2phdmEvb3JnL2FwYWNoZS9zZXJ2aWNlY29tYi9jb25maWcvYXJjaGFpdXMvc291cmNlcy9Db25maWdDZW50ZXJDb25maWd1cmF0aW9uU291cmNlSW1wbC5qYXZh)
 | `81.13% <100.00%> (ø)` | `0.00 <0.00> (ø)` | |
   | 
[...pache/servicecomb/config/kie/client/KieClient.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2084/diff?src=pr=tree#diff-ZHluYW1pYy1jb25maWcvY29uZmlnLWtpZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvY29uZmlnL2tpZS9jbGllbnQvS2llQ2xpZW50LmphdmE=)
 | `72.61% <0.00%> (-5.96%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...ecomb/provider/pojo/PojoConsumerMetaRefresher.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2084/diff?src=pr=tree#diff-cHJvdmlkZXJzL3Byb3ZpZGVyLXBvam8vc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NlcnZpY2Vjb21iL3Byb3ZpZGVyL3Bvam8vUG9qb0NvbnN1bWVyTWV0YVJlZnJlc2hlci5qYXZh)
 | `75.60% <0.00%> (-2.44%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...egistry/client/http/ServiceRegistryClientImpl.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2084/diff?src=pr=tree#diff-c2VydmljZS1yZWdpc3RyeS9yZWdpc3RyeS1zZXJ2aWNlLWNlbnRlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvc2VydmljZXJlZ2lzdHJ5L2NsaWVudC9odHRwL1NlcnZpY2VSZWdpc3RyeUNsaWVudEltcGwuamF2YQ==)
 | `69.32% <0.00%> (-1.95%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...mb/serviceregistry/client/http/RestClientUtil.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2084/diff?src=pr=tree#diff-c2VydmljZS1yZWdpc3RyeS9yZWdpc3RyeS1zZXJ2aWNlLWNlbnRlci9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvc2VydmljZXJlZ2lzdHJ5L2NsaWVudC9odHRwL1Jlc3RDbGllbnRVdGlsLmphdmE=)
 | `75.70% <0.00%> (-1.87%)` | `0.00% <0.00%> (ø%)` | |
   | 
[...che/servicecomb/demo/jaxrs/client/JaxrsClient.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2084/diff?src=pr=tree#diff-ZGVtby9kZW1vLWpheHJzL2pheHJzLWNsaWVudC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvZGVtby9qYXhycy9jbGllbnQvSmF4cnNDbGllbnQuamF2YQ==)
 | `91.78% <0.00%> (-0.13%)` | `33.00% <0.00%> (-5.00%)` | |
   | 
[...rvicecomb/demo/jaxrs/client/TestClientTimeout.java](https://codecov.io/gh/apache/servicecomb-java-chassis/pull/2084/diff?src=pr=tree#diff-ZGVtby9kZW1vLWpheHJzL2pheHJzLWNsaWVudC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2VydmljZWNvbWIvZGVtby9qYXhycy9jbGllbnQvVGVzdENsaWVudFRpbWVvdXQuamF2YQ==)
 | `95.12% <0.00%> (ø)` | `7.00% <0.00%> (?%)` | |
   | 

[GitHub] [servicecomb-java-chassis] liubao68 edited a comment on issue #2081: servicecomb升级至2.1.2版本后,GET接口请求参数设置值方式修改

2020-11-26 Thread GitBox


liubao68 edited a comment on issue #2081:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2081#issuecomment-734162008


   query 为 List 的情况有多种编码形式,默认是 `multi`,  你需要的是那种?
   
   ```
 @Path("queryArrCSV")
 @GET
 public String queryArrCSV(@ApiParam(collectionFormat = "csv") 
@QueryParam("queryArr") String[] queryArr) {
   return Arrays.toString(queryArr) + queryArr.length;
 }
   
 @Path("queryArrSSV")
 @GET
 public String queryArrSSV(@ApiParam(collectionFormat = "ssv") 
@QueryParam("queryArr") String[] queryArr) {
   return Arrays.toString(queryArr) + queryArr.length;
 }
   
 @Path("queryArrTSV")
 @GET
 public String queryArrTSV(@ApiParam(collectionFormat = "tsv") 
@QueryParam("queryArr") String[] queryArr) {
   return Arrays.toString(queryArr) + queryArr.length;
 }
   
 @Path("queryArrPIPES")
 @GET
 public String queryArrPIPES(@ApiParam(collectionFormat = "pipes") 
@QueryParam("queryArr") String[] queryArr) {
   return Arrays.toString(queryArr) + queryArr.length;
 }
   
 @Path("queryArrMULTI")
 @GET
 public String queryArrMULTI(@ApiParam(collectionFormat = "multi") 
@QueryParam("queryArr") String[] queryArr) {
   return Arrays.toString(queryArr) + queryArr.length;
 }
   ```
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] liubao68 commented on issue #2081: servicecomb升级至2.1.2版本后,GET接口请求参数设置值方式修改

2020-11-26 Thread GitBox


liubao68 commented on issue #2081:
URL: 
https://github.com/apache/servicecomb-java-chassis/issues/2081#issuecomment-734162008


   query 为 List 的情况有多种编码形式, 你需要的是那种?
   
   ```
 @Path("queryArrCSV")
 @GET
 public String queryArrCSV(@ApiParam(collectionFormat = "csv") 
@QueryParam("queryArr") String[] queryArr) {
   return Arrays.toString(queryArr) + queryArr.length;
 }
   
 @Path("queryArrSSV")
 @GET
 public String queryArrSSV(@ApiParam(collectionFormat = "ssv") 
@QueryParam("queryArr") String[] queryArr) {
   return Arrays.toString(queryArr) + queryArr.length;
 }
   
 @Path("queryArrTSV")
 @GET
 public String queryArrTSV(@ApiParam(collectionFormat = "tsv") 
@QueryParam("queryArr") String[] queryArr) {
   return Arrays.toString(queryArr) + queryArr.length;
 }
   
 @Path("queryArrPIPES")
 @GET
 public String queryArrPIPES(@ApiParam(collectionFormat = "pipes") 
@QueryParam("queryArr") String[] queryArr) {
   return Arrays.toString(queryArr) + queryArr.length;
 }
   
 @Path("queryArrMULTI")
 @GET
 public String queryArrMULTI(@ApiParam(collectionFormat = "multi") 
@QueryParam("queryArr") String[] queryArr) {
   return Arrays.toString(queryArr) + queryArr.length;
 }
   ```
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] yangyinqi opened a new issue #2085: ServiceComb如何支持soap类型的接口,或者怎么处理xml格式的消息呢?

2020-11-26 Thread GitBox


yangyinqi opened a new issue #2085:
URL: https://github.com/apache/servicecomb-java-chassis/issues/2085


   RT,现在有个场景是需要用微服务进行xml格式的消息交互,尝试了一下发现返回的数据类型仍然是application/json,但需要的是text/xml。



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org




[GitHub] [servicecomb-java-chassis] liubao68 opened a new pull request #2084: [SCB-2130]vert.x 3.9.4 ping/pong message will call on message

2020-11-26 Thread GitBox


liubao68 opened a new pull request #2084:
URL: https://github.com/apache/servicecomb-java-chassis/pull/2084


   Follow this checklist to help us incorporate your contribution quickly and 
easily:
   
- [ ] Make sure there is a [JIRA 
issue](https://issues.apache.org/jira/browse/SCB) filed for the change (usually 
before you start working on it).  Trivial changes like typos do not require a 
JIRA issue.  Your pull request should address just this issue, without pulling 
in other changes.
- [ ] Each commit in the pull request should have a meaningful subject line 
and body.
- [ ] Format the pull request title like `[SCB-XXX] Fixes bug in 
ApproximateQuantiles`, where you replace `SCB-XXX` with the appropriate JIRA 
issue.
- [ ] Write a pull request description that is detailed enough to 
understand what the pull request does, how, and why.
- [ ] Run `mvn clean install -Pit` to make sure basic checks pass. A more 
thorough check will be performed on your pull request automatically.
- [ ] If this contribution is large, please file an Apache [Individual 
Contributor License Agreement](https://www.apache.org/licenses/icla.pdf).
   
   ---
   



This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org