Skip to content
Snippets Groups Projects
Commit 16ca2a25 authored by Ming Deng's avatar Ming Deng
Browse files

Fix Reveiw

parent 00f8aa61
No related branches found
No related tags found
No related merge requests found
...@@ -19,8 +19,6 @@ package impl ...@@ -19,8 +19,6 @@ package impl
import ( import (
"sync" "sync"
common2 "github.com/apache/dubbo-go/filter/common"
) )
import ( import (
...@@ -28,6 +26,7 @@ import ( ...@@ -28,6 +26,7 @@ import (
"github.com/apache/dubbo-go/common/constant" "github.com/apache/dubbo-go/common/constant"
"github.com/apache/dubbo-go/common/extension" "github.com/apache/dubbo-go/common/extension"
"github.com/apache/dubbo-go/common/logger" "github.com/apache/dubbo-go/common/logger"
filterCommon "github.com/apache/dubbo-go/filter/common"
"github.com/apache/dubbo-go/protocol" "github.com/apache/dubbo-go/protocol"
) )
...@@ -62,7 +61,7 @@ func (handler *OnlyLogRejectedExecutionHandler) RejectedExecution(url common.URL ...@@ -62,7 +61,7 @@ func (handler *OnlyLogRejectedExecutionHandler) RejectedExecution(url common.URL
return &protocol.RPCResult{} return &protocol.RPCResult{}
} }
func GetOnlyLogRejectedExecutionHandler() common2.RejectedExecutionHandler { func GetOnlyLogRejectedExecutionHandler() filterCommon.RejectedExecutionHandler {
onlyLogHandlerOnce.Do(func() { onlyLogHandlerOnce.Do(func() {
onlyLogHandlerInstance = &OnlyLogRejectedExecutionHandler{} onlyLogHandlerInstance = &OnlyLogRejectedExecutionHandler{}
}) })
......
...@@ -31,8 +31,8 @@ import ( ...@@ -31,8 +31,8 @@ import (
"github.com/apache/dubbo-go/common" "github.com/apache/dubbo-go/common"
"github.com/apache/dubbo-go/common/constant" "github.com/apache/dubbo-go/common/constant"
"github.com/apache/dubbo-go/common/extension" "github.com/apache/dubbo-go/common/extension"
common2 "github.com/apache/dubbo-go/filter/common" filterCommon "github.com/apache/dubbo-go/filter/common"
impl2 "github.com/apache/dubbo-go/filter/common/impl" filterCommonImpl "github.com/apache/dubbo-go/filter/common/impl"
"github.com/apache/dubbo-go/filter/impl/tps" "github.com/apache/dubbo-go/filter/impl/tps"
"github.com/apache/dubbo-go/filter/impl/tps/impl" "github.com/apache/dubbo-go/filter/impl/tps/impl"
"github.com/apache/dubbo-go/protocol" "github.com/apache/dubbo-go/protocol"
...@@ -84,10 +84,10 @@ func TestGenericFilter_Invoke_With_Default_TpsLimiter_Not_Allow(t *testing.T) { ...@@ -84,10 +84,10 @@ func TestGenericFilter_Invoke_With_Default_TpsLimiter_Not_Allow(t *testing.T) {
}) })
mockResult := &protocol.RPCResult{} mockResult := &protocol.RPCResult{}
mockRejectedHandler := impl2.NewMockRejectedExecutionHandler(ctrl) mockRejectedHandler := filterCommonImpl.NewMockRejectedExecutionHandler(ctrl)
mockRejectedHandler.EXPECT().RejectedExecution(gomock.Any(), gomock.Any()).Return(mockResult).Times(1) mockRejectedHandler.EXPECT().RejectedExecution(gomock.Any(), gomock.Any()).Return(mockResult).Times(1)
extension.SetRejectedExecutionHandler(constant.DEFAULT_KEY, func() common2.RejectedExecutionHandler { extension.SetRejectedExecutionHandler(constant.DEFAULT_KEY, func() filterCommon.RejectedExecutionHandler {
return mockRejectedHandler return mockRejectedHandler
}) })
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment