You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@dubbo.apache.org by al...@apache.org on 2021/10/31 15:27:46 UTC

[dubbo-go] branch improve/3.0 created (now 0afb51f)

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

alexstocks pushed a change to branch improve/3.0
in repository https://gitbox.apache.org/repos/asf/dubbo-go.git.


      at 0afb51f  delete useless codes

This branch includes the following new commits:

     new 0afb51f  delete useless codes

The 1 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.


[dubbo-go] 01/01: delete useless codes

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

alexstocks pushed a commit to branch improve/3.0
in repository https://gitbox.apache.org/repos/asf/dubbo-go.git

commit 0afb51f8d110317d6756c09c65212bbffcb9e0d5
Author: AlexStocks <al...@foxmail.com>
AuthorDate: Sun Oct 31 23:27:37 2021 +0800

    delete useless codes
---
 cluster/cluster/base/cluster_invoker.go | 6 ++----
 cluster/cluster_impl/import.go          | 2 --
 filter/filter_impl/import.go            | 2 --
 3 files changed, 2 insertions(+), 8 deletions(-)

diff --git a/cluster/cluster/base/cluster_invoker.go b/cluster/cluster/base/cluster_invoker.go
index 5b4958d..e4265e5 100644
--- a/cluster/cluster/base/cluster_invoker.go
+++ b/cluster/cluster/base/cluster_invoker.go
@@ -155,11 +155,9 @@ func (invoker *ClusterInvoker) doSelectInvoker(lb loadbalance.LoadBalance, invoc
 			}
 			return reselectedInvoker
 		}
-	} else {
-		return selectedInvoker
 	}
-	logger.Errorf("all %d invokers is unavailable for %s.", len(invokers), selectedInvoker.GetURL().String())
-	return nil
+
+	return selectedInvoker
 }
 
 func isInvoked(selectedInvoker protocol.Invoker, invoked []protocol.Invoker) bool {
diff --git a/cluster/cluster_impl/import.go b/cluster/cluster_impl/import.go
index a7b16b4..68908ab 100644
--- a/cluster/cluster_impl/import.go
+++ b/cluster/cluster_impl/import.go
@@ -30,5 +30,3 @@ import (
 	_ "dubbo.apache.org/dubbo-go/v3/cluster/cluster/forking"
 	_ "dubbo.apache.org/dubbo-go/v3/cluster/cluster/zoneaware"
 )
-
-func init() {}
diff --git a/filter/filter_impl/import.go b/filter/filter_impl/import.go
index 457e3cd..46bfd45 100644
--- a/filter/filter_impl/import.go
+++ b/filter/filter_impl/import.go
@@ -36,5 +36,3 @@ import (
 	_ "dubbo.apache.org/dubbo-go/v3/filter/tps"
 	_ "dubbo.apache.org/dubbo-go/v3/filter/tracing"
 )
-
-func init() {}