You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@servicecomb.apache.org by GitBox <gi...@apache.org> on 2020/03/24 12:26:14 UTC

[GitHub] [servicecomb-java-chassis] heyile opened a new pull request #1660: [SCB-1815] Support sdk use different address to registry and discover…

heyile opened a new pull request #1660: [SCB-1815] Support sdk use different address to registry and discover…
URL: https://github.com/apache/servicecomb-java-chassis/pull/1660
 
 
   …y and change outlog item name
   
   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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] heyile commented on issue #1660: [SCB-1815] Support sdk use different address to registry and discover…

Posted by GitBox <gi...@apache.org>.
heyile commented on issue #1660: [SCB-1815] Support sdk use different address to registry and discover…
URL: https://github.com/apache/servicecomb-java-chassis/pull/1660#issuecomment-603212274
 
 
   **modify as bellow**  :
   
   * support use differently address to register and discover
   
   ```yaml
   
   # keep same with go chassis
   # 
   servicecomb:
     service:
       registry:
         address: xxx:30100,xxx:30100
         registrator:
           # registry 
           address: xxx:3100,xxx:30100
         serviceDiscovery:
           # discovery
           address: xxx:3100,xxx:30100
   
   
   ```
   
   * change name of access log item
   
   * remove readme.md of accesslog
   
   
   

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] heyile edited a comment on issue #1660: [SCB-1815] Support sdk use different address to registry and discover…

Posted by GitBox <gi...@apache.org>.
heyile edited a comment on issue #1660: [SCB-1815] Support sdk use different address to registry and discover…
URL: https://github.com/apache/servicecomb-java-chassis/pull/1660#issuecomment-603212274
 
 
   **modify as bellow**  :
   
   * support use differently address to register and discover
   
   we prefer to use  `servicecomb.service.registry.address` and `servicecomb.service.registry.serviceDiscovery.address`. 
   
   either of them does not exist, we will use 
   `servicecomb.service.registry.address` as default
   
   ```yaml
   
   # keep same with go chassis
   # 
   servicecomb:
     service:
       registry:
         address: xxx:30100,xxx:30100
         registrator:
           # registry 
           address: xxx:3100,xxx:30100
         serviceDiscovery:
           # discovery
           address: xxx:3100,xxx:30100
   
   
   ```
   
   * change name of access log item
   
   * remove readme.md of accesslog
   
   
   

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] heyile commented on a change in pull request #1660: [SCB-1815] Support sdk use different address to registry and discover…

Posted by GitBox <gi...@apache.org>.
heyile commented on a change in pull request #1660: [SCB-1815] Support sdk use different address to registry and discover…
URL: https://github.com/apache/servicecomb-java-chassis/pull/1660#discussion_r397722997
 
 

 ##########
 File path: common/common-access-log/src/main/java/org/apache/servicecomb/common/accessLog/core/element/impl/DatetimeAccessConfigurableItem.java
 ##########
 @@ -49,15 +49,15 @@
   /**
    * all configuration is set to default value.
    */
-  public DatetimeConfigurableItemAccess() {
+  public DatetimeAccessConfigurableItem() {
     this(DEFAULT_DATETIME_PATTERN);
   }
 
   /**
    * the configurations not specified will get a default value.
    * @param config the format of configuration is "PATTERN|TIMEZONE|LOCALE" or "PATTERN". It depends on whether the config contains the separator "|"
    */
-  public DatetimeConfigurableItemAccess(String config) {
+  public DatetimeAccessConfigurableItem(String config) {
 
 Review comment:
   ok, i will modify it in #1665 

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] coveralls commented on issue #1660: [SCB-1815] Support sdk register on local SC and discover on SCA

Posted by GitBox <gi...@apache.org>.
coveralls commented on issue #1660: [SCB-1815] Support sdk register on local SC and discover on SCA
URL: https://github.com/apache/servicecomb-java-chassis/pull/1660#issuecomment-604977241
 
 
   
   [![Coverage Status](https://coveralls.io/builds/29659891/badge)](https://coveralls.io/builds/29659891)
   
   Coverage decreased (-0.04%) to 84.959% when pulling **ec11d357784389dc9733c7a35f7c5eb16cc36541 on heyile:heyile-scb-1815** into **9436f0afd1d0024eef674f4d8c380ffaae7ed6f2 on apache:master**.
   

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] heyile edited a comment on issue #1660: [SCB-1815] Support sdk use different address to registry and discover…

Posted by GitBox <gi...@apache.org>.
heyile edited a comment on issue #1660: [SCB-1815] Support sdk use different address to registry and discover…
URL: https://github.com/apache/servicecomb-java-chassis/pull/1660#issuecomment-603212274
 
 
   **modify as bellow**  :
   
   * support use different address to register and discover
   
   we prefer to use  **servicecomb.service.registry.registrator.address** and **servicecomb.service.registry.serviceDiscovery.address**. 
   
   either of them does not exist, we will use 
   **servicecomb.service.registry.address** as default
   
   ```yaml
   
   # keep same with go chassis
   # 
   servicecomb:
     service:
       registry:
         address: xxx:30100,xxx:30100
         registrator:
           # registry 
           address: xxx:3100,xxx:30100
         serviceDiscovery:
           # discovery
           address: xxx:3100,xxx:30100
   ```
   
   There are some restrictions as follows:
   
   1. The target  sc  to be  registered must be in the same cluster with the sca to be discovered.
   
   2. The sca to be watched must be in the same cluster with the sc to be registered.
   
   
   

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] heyile edited a comment on issue #1660: [SCB-1815] Support sdk register on local SC and discover on SCA

Posted by GitBox <gi...@apache.org>.
heyile edited a comment on issue #1660: [SCB-1815] Support sdk register on local SC and discover on SCA
URL: https://github.com/apache/servicecomb-java-chassis/pull/1660#issuecomment-603212274
 
 
   **modify as bellow**  :
   
   Support sdk register on local SC and discover on SCA #
   
   we prefer to use  **servicecomb.service.registry.registrator.address** and **servicecomb.service.registry.serviceDiscovery.address**. 
   
   either of them does not exist, we will use 
   **servicecomb.service.registry.address** as default
   
   ```yaml
   
   # keep same with go chassis
   # 
   servicecomb:
     service:
       registry:
         address: xxx:30100,xxx:30100
         registrator:
           # registry 
           address: xxx:3100,xxx:30100
         serviceDiscovery:
           # discovery
           address: xxx:3100,xxx:30100
   ```
   
   There are some restrictions as follows:
   
   1. The target  sc  to be  registered must be in the same cluster as the sca to be discovered.
   
   2. the registry address  and discovery address must be all http or all https
   
   
   
   

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] liubao68 commented on a change in pull request #1660: [SCB-1815] Support sdk use different address to registry and discover…

Posted by GitBox <gi...@apache.org>.
liubao68 commented on a change in pull request #1660: [SCB-1815] Support sdk use different address to registry and discover…
URL: https://github.com/apache/servicecomb-java-chassis/pull/1660#discussion_r397707391
 
 

 ##########
 File path: common/common-access-log/src/main/java/org/apache/servicecomb/common/accessLog/core/element/impl/DatetimeAccessConfigurableItem.java
 ##########
 @@ -49,15 +49,15 @@
   /**
    * all configuration is set to default value.
    */
-  public DatetimeConfigurableItemAccess() {
+  public DatetimeAccessConfigurableItem() {
     this(DEFAULT_DATETIME_PATTERN);
   }
 
   /**
    * the configurations not specified will get a default value.
    * @param config the format of configuration is "PATTERN|TIMEZONE|LOCALE" or "PATTERN". It depends on whether the config contains the separator "|"
    */
-  public DatetimeConfigurableItemAccess(String config) {
+  public DatetimeAccessConfigurableItem(String config) {
 
 Review comment:
   ConfigurableDatetimeAccessItem

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] heyile edited a comment on issue #1660: [SCB-1815] Support sdk use different address to registry and discover…

Posted by GitBox <gi...@apache.org>.
heyile edited a comment on issue #1660: [SCB-1815] Support sdk use different address to registry and discover…
URL: https://github.com/apache/servicecomb-java-chassis/pull/1660#issuecomment-603212274
 
 
   **modify as bellow**  :
   
   * support use differently address to register and discover
   
   we prefer to use  **servicecomb.service.registry.address** and **servicecomb.service.registry.serviceDiscovery.address**. 
   
   either of them does not exist, we will use 
   **servicecomb.service.registry.address** as default
   
   ```yaml
   
   # keep same with go chassis
   # 
   servicecomb:
     service:
       registry:
         address: xxx:30100,xxx:30100
         registrator:
           # registry 
           address: xxx:3100,xxx:30100
         serviceDiscovery:
           # discovery
           address: xxx:3100,xxx:30100
   
   
   ```
   
   * change name of access log item
   
   * remove readme.md of accesslog
   
   
   

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] heyile edited a comment on issue #1660: [SCB-1815] Support sdk use different address to registry and discover…

Posted by GitBox <gi...@apache.org>.
heyile edited a comment on issue #1660: [SCB-1815] Support sdk use different address to registry and discover…
URL: https://github.com/apache/servicecomb-java-chassis/pull/1660#issuecomment-603212274
 
 
   **modify as bellow**  :
   
   * support use different address to register and discover
   
   we prefer to use  **servicecomb.service.registry.registrator.address** and **servicecomb.service.registry.serviceDiscovery.address**. 
   
   either of them does not exist, we will use 
   **servicecomb.service.registry.address** as default
   
   ```yaml
   
   # keep same with go chassis
   # 
   servicecomb:
     service:
       registry:
         address: xxx:30100,xxx:30100
         registrator:
           # registry 
           address: xxx:3100,xxx:30100
         serviceDiscovery:
           # discovery
           address: xxx:3100,xxx:30100
   ```
   
   There are some restrictions as follows:
   
   1. The target  sc  to be  registered must be in the same cluster as the sca to be discovered.
   
   2. the registry address  and discovery address must be all http or all https
   
   
   
   

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] heyile edited a comment on issue #1660: [SCB-1815] Support sdk use different address to registry and discover…

Posted by GitBox <gi...@apache.org>.
heyile edited a comment on issue #1660: [SCB-1815] Support sdk use different address to registry and discover…
URL: https://github.com/apache/servicecomb-java-chassis/pull/1660#issuecomment-603212274
 
 
   **modify as bellow**  :
   
   * support use different address to register and discover
   
   we prefer to use  **servicecomb.service.registry.registrator.address** and **servicecomb.service.registry.serviceDiscovery.address**. 
   
   either of them does not exist, we will use 
   **servicecomb.service.registry.address** as default
   
   ```yaml
   
   # keep same with go chassis
   # 
   servicecomb:
     service:
       registry:
         address: xxx:30100,xxx:30100
         registrator:
           # registry 
           address: xxx:3100,xxx:30100
         serviceDiscovery:
           # discovery
           address: xxx:3100,xxx:30100
   
   
   ```
   
   * change name of access log item
   
   * remove readme.md of accesslog
   
   
   

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] heyile edited a comment on issue #1660: [SCB-1815] Support sdk use different address to registry and discover…

Posted by GitBox <gi...@apache.org>.
heyile edited a comment on issue #1660: [SCB-1815] Support sdk use different address to registry and discover…
URL: https://github.com/apache/servicecomb-java-chassis/pull/1660#issuecomment-603212274
 
 
   **modify as bellow**  :
   
   * support use differently address to register and discover
   
   we prefer to use  `**servicecomb.service.registry.address**` and `**servicecomb.service.registry.serviceDiscovery.address**`. 
   
   either of them does not exist, we will use 
   `**servicecomb.service.registry.address**` as default
   
   ```yaml
   
   # keep same with go chassis
   # 
   servicecomb:
     service:
       registry:
         address: xxx:30100,xxx:30100
         registrator:
           # registry 
           address: xxx:3100,xxx:30100
         serviceDiscovery:
           # discovery
           address: xxx:3100,xxx:30100
   
   
   ```
   
   * change name of access log item
   
   * remove readme.md of accesslog
   
   
   

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] liubao68 commented on a change in pull request #1660: [SCB-1815] Support sdk register on local SC and discover on SCA

Posted by GitBox <gi...@apache.org>.
liubao68 commented on a change in pull request #1660: [SCB-1815] Support sdk register on local SC and discover on SCA
URL: https://github.com/apache/servicecomb-java-chassis/pull/1660#discussion_r399907041
 
 

 ##########
 File path: service-registry/src/main/java/org/apache/servicecomb/serviceregistry/config/ServiceRegistryConfigBuilder.java
 ##########
 @@ -129,6 +131,46 @@ public boolean isSsl() {
     return ipPortList;
   }
 
+  public ArrayList<IpPort> getRegistryIpPort() {
 
 Review comment:
   This 3 methods and atract to one `public ArrayList<IpPort> getIpPort(String key) `

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] heyile edited a comment on issue #1660: [SCB-1815] Support sdk use different address to registry and discover…

Posted by GitBox <gi...@apache.org>.
heyile edited a comment on issue #1660: [SCB-1815] Support sdk use different address to registry and discover…
URL: https://github.com/apache/servicecomb-java-chassis/pull/1660#issuecomment-603212274
 
 
   **modify as bellow**  :
   
   * support use different address to register and discover
   
   we prefer to use  **servicecomb.service.registry.address** and **servicecomb.service.registry.serviceDiscovery.address**. 
   
   either of them does not exist, we will use 
   **servicecomb.service.registry.address** as default
   
   ```yaml
   
   # keep same with go chassis
   # 
   servicecomb:
     service:
       registry:
         address: xxx:30100,xxx:30100
         registrator:
           # registry 
           address: xxx:3100,xxx:30100
         serviceDiscovery:
           # discovery
           address: xxx:3100,xxx:30100
   
   
   ```
   
   * change name of access log item
   
   * remove readme.md of accesslog
   
   
   

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

[GitHub] [servicecomb-java-chassis] liubao68 commented on a change in pull request #1660: [SCB-1815] Support sdk register on local SC and discover on SCA

Posted by GitBox <gi...@apache.org>.
liubao68 commented on a change in pull request #1660: [SCB-1815] Support sdk register on local SC and discover on SCA
URL: https://github.com/apache/servicecomb-java-chassis/pull/1660#discussion_r399905550
 
 

 ##########
 File path: core/src/main/java/org/apache/servicecomb/core/bootup/AddressInformationCollector.java
 ##########
 @@ -18,15 +18,21 @@
 package org.apache.servicecomb.core.bootup;
 
 import org.apache.servicecomb.deployment.Deployment;
+import org.apache.servicecomb.deployment.DeploymentProvider;
 import org.apache.servicecomb.deployment.SystemBootstrapInfo;
 
 public class AddressInformationCollector implements BootUpInformationCollector {
   @Override
   public String collect() {
-    return "Service Center: "
-        + getCenterInfo(Deployment.getSystemBootStrapInfo("ServiceCenter"))
-        + "\n" + "Config Center: "
-        + getCenterInfo(Deployment.getSystemBootStrapInfo("ConfigCenter"));
+    return "Service Center:\n"
+        + "  Registration: "
+        + getCenterInfo(Deployment.getSystemBootStrapInfo(DeploymentProvider.SYSTEM_KEY_SERVICE_CENTER_REGISTRY))
 
 Review comment:
   not correct, lack of servicecomb.service.registry.address

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services