[ 
https://issues.apache.org/jira/browse/SCB-706?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16529967#comment-16529967
 ] 

ASF GitHub Bot commented on SCB-706:
------------------------------------

wujimin commented on a change in pull request #786: [SCB-706]refactor 
loadbalance filters logic to support invocation based filter
URL: 
https://github.com/apache/incubator-servicecomb-java-chassis/pull/786#discussion_r199508274
 
 

 ##########
 File path: 
handlers/handler-loadbalance/src/main/java/org/apache/servicecomb/loadbalance/filter/ZoneAwareServerListFilterExt.java
 ##########
 @@ -20,33 +20,53 @@
 import java.util.ArrayList;
 import java.util.List;
 
-import org.apache.servicecomb.loadbalance.CseServer;
+import org.apache.servicecomb.core.Invocation;
+import org.apache.servicecomb.loadbalance.LoadBalancer;
+import org.apache.servicecomb.loadbalance.ServiceCombServer;
 import org.apache.servicecomb.loadbalance.ServerListFilterExt;
 import org.apache.servicecomb.serviceregistry.RegistryUtils;
 import 
org.apache.servicecomb.serviceregistry.api.registry.MicroserviceInstance;
 
+import com.netflix.config.DynamicPropertyFactory;
 import com.netflix.loadbalancer.Server;
 
 public class ZoneAwareServerListFilterExt implements ServerListFilterExt {
 
 Review comment:
   is it possible that move old filters to DiscoveryFilter?
   so that we can cache filter result in most scenes

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on 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


> refactor loadbalance filters logic to support invocation based filter
> ---------------------------------------------------------------------
>
>                 Key: SCB-706
>                 URL: https://issues.apache.org/jira/browse/SCB-706
>             Project: Apache ServiceComb
>          Issue Type: Improvement
>            Reporter: liubao
>            Assignee: liubao
>            Priority: Major
>
> Why we do this?
>  # When implement invocation based filter, e.g. darklaunch deployment, we 
> need to filter servers based on invocation parameters. But now, we create a 
> Loadbalaner instance for each service, and Robin filter interface can not 
> pass Invocation to it. Before refactor, we doing this by ThreadLocal and 
> cache Invocation, and use in filter implementation. This is error prone and 
> users can't handle this complixity
>  # We have other improvements, e.g. SCB-700, we can do server status check, 
> and add a filter a choose from active servers. We need to consider filter 
> orders and other feature, current implementation not satisfy this.
>  # We want to make loadbalance code handy by remove some compatible fixes. 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to