Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
touzizhuo03
Dubbo
提交
510daffd
D
Dubbo
项目概览
touzizhuo03
/
Dubbo
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
D
Dubbo
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
510daffd
编写于
12月 20, 2017
作者:
I
Ian Luo
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
#1067: I18N effort for dubbo code base - dubbo-rpc (part3)
上级
7ba9c2f0
变更
27
隐藏空白更改
内联
并排
Showing
27 changed file
with
267 addition
and
288 deletion
+267
-288
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/listener/DeprecatedInvokerListener.java
...alibaba/dubbo/rpc/listener/DeprecatedInvokerListener.java
+9
-10
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/listener/ExporterListenerAdapter.java
...m/alibaba/dubbo/rpc/listener/ExporterListenerAdapter.java
+9
-10
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/listener/InvokerListenerAdapter.java
...om/alibaba/dubbo/rpc/listener/InvokerListenerAdapter.java
+9
-10
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/listener/ListenerExporterWrapper.java
...m/alibaba/dubbo/rpc/listener/ListenerExporterWrapper.java
+9
-10
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/listener/ListenerInvokerWrapper.java
...om/alibaba/dubbo/rpc/listener/ListenerInvokerWrapper.java
+9
-10
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/protocol/AbstractExporter.java
...java/com/alibaba/dubbo/rpc/protocol/AbstractExporter.java
+9
-11
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/protocol/AbstractInvoker.java
.../java/com/alibaba/dubbo/rpc/protocol/AbstractInvoker.java
+9
-11
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/protocol/AbstractProtocol.java
...java/com/alibaba/dubbo/rpc/protocol/AbstractProtocol.java
+9
-11
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/protocol/AbstractProxyProtocol.java
...com/alibaba/dubbo/rpc/protocol/AbstractProxyProtocol.java
+7
-8
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/protocol/InvokerWrapper.java
...n/java/com/alibaba/dubbo/rpc/protocol/InvokerWrapper.java
+9
-10
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/protocol/ProtocolFilterWrapper.java
...com/alibaba/dubbo/rpc/protocol/ProtocolFilterWrapper.java
+9
-10
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/protocol/ProtocolListenerWrapper.java
...m/alibaba/dubbo/rpc/protocol/ProtocolListenerWrapper.java
+9
-10
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/proxy/AbstractProxyFactory.java
...ava/com/alibaba/dubbo/rpc/proxy/AbstractProxyFactory.java
+9
-10
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/proxy/AbstractProxyInvoker.java
...ava/com/alibaba/dubbo/rpc/proxy/AbstractProxyInvoker.java
+9
-10
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/proxy/InvokerInvocationHandler.java
...com/alibaba/dubbo/rpc/proxy/InvokerInvocationHandler.java
+9
-10
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/proxy/javassist/JavassistProxyFactory.java
...baba/dubbo/rpc/proxy/javassist/JavassistProxyFactory.java
+10
-11
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/proxy/jdk/JdkProxyFactory.java
...java/com/alibaba/dubbo/rpc/proxy/jdk/JdkProxyFactory.java
+9
-10
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/proxy/wrapper/StubProxyFactoryWrapper.java
...baba/dubbo/rpc/proxy/wrapper/StubProxyFactoryWrapper.java
+9
-10
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/service/EchoService.java
.../main/java/com/alibaba/dubbo/rpc/service/EchoService.java
+9
-10
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/service/GenericException.java
.../java/com/alibaba/dubbo/rpc/service/GenericException.java
+9
-10
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/service/GenericService.java
...in/java/com/alibaba/dubbo/rpc/service/GenericService.java
+17
-16
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/support/DelegateExporter.java
.../java/com/alibaba/dubbo/rpc/support/DelegateExporter.java
+15
-16
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/support/DelegateInvoker.java
...n/java/com/alibaba/dubbo/rpc/support/DelegateInvoker.java
+9
-10
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/support/MockInvoker.java
.../main/java/com/alibaba/dubbo/rpc/support/MockInvoker.java
+10
-13
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/support/MockProtocol.java
...main/java/com/alibaba/dubbo/rpc/support/MockProtocol.java
+10
-11
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/support/ProtocolUtils.java
...ain/java/com/alibaba/dubbo/rpc/support/ProtocolUtils.java
+16
-3
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/support/RpcUtils.java
...src/main/java/com/alibaba/dubbo/rpc/support/RpcUtils.java
+11
-17
未找到文件。
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/listener/DeprecatedInvokerListener.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -24,8 +25,6 @@ import com.alibaba.dubbo.rpc.RpcException;
/**
* DeprecatedProtocolFilter
*
* @author william.liangf
*/
@Activate
(
Constants
.
DEPRECATED_KEY
)
public
class
DeprecatedInvokerListener
extends
InvokerListenerAdapter
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/listener/ExporterListenerAdapter.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -21,8 +22,6 @@ import com.alibaba.dubbo.rpc.RpcException;
/**
* ExporterListenerAdapter
*
* @author william.liangf
*/
public
abstract
class
ExporterListenerAdapter
implements
ExporterListener
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/listener/InvokerListenerAdapter.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -21,8 +22,6 @@ import com.alibaba.dubbo.rpc.RpcException;
/**
* InvokerListenerAdapter
*
* @author william.liangf
*/
public
abstract
class
InvokerListenerAdapter
implements
InvokerListener
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/listener/ListenerExporterWrapper.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -25,8 +26,6 @@ import java.util.List;
/**
* ListenerExporter
*
* @author william.liangf
*/
public
class
ListenerExporterWrapper
<
T
>
implements
Exporter
<
T
>
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/listener/ListenerInvokerWrapper.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -28,8 +29,6 @@ import java.util.List;
/**
* ListenerInvoker
*
* @author william.liangf
*/
public
class
ListenerInvokerWrapper
<
T
>
implements
Invoker
<
T
>
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/protocol/AbstractExporter.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -22,9 +23,6 @@ import com.alibaba.dubbo.rpc.Invoker;
/**
* AbstractExporter.
*
* @author qianlei
* @author william.liangf
*/
public
abstract
class
AbstractExporter
<
T
>
implements
Exporter
<
T
>
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/protocol/AbstractInvoker.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -38,9 +39,6 @@ import java.util.concurrent.atomic.AtomicBoolean;
/**
* AbstractInvoker.
*
* @author qian.lei
* @author william.liangf
*/
public
abstract
class
AbstractInvoker
<
T
>
implements
Invoker
<
T
>
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/protocol/AbstractProtocol.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -33,9 +34,6 @@ import java.util.concurrent.ConcurrentHashMap;
/**
* abstract ProtocolSupport.
*
* @author qian.lei
* @author william.liangf
*/
public
abstract
class
AbstractProtocol
implements
Protocol
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/protocol/AbstractProxyProtocol.java
浏览文件 @
510daffd
/*
* Copyright 1999-2012 Alibaba Group.
* 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
*
* Licensed 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
* 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,
...
...
@@ -31,8 +32,6 @@ import java.util.concurrent.CopyOnWriteArrayList;
/**
* AbstractProxyProtocol
*
* @author william.liangf
*/
public
abstract
class
AbstractProxyProtocol
extends
AbstractProtocol
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/protocol/InvokerWrapper.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -23,8 +24,6 @@ import com.alibaba.dubbo.rpc.RpcException;
/**
* InvokerWrapper
*
* @author william.liangf
*/
public
class
InvokerWrapper
<
T
>
implements
Invoker
<
T
>
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/protocol/ProtocolFilterWrapper.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -30,8 +31,6 @@ import java.util.List;
/**
* ListenerProtocol
*
* @author william.liangf
*/
public
class
ProtocolFilterWrapper
implements
Protocol
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/protocol/ProtocolListenerWrapper.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -32,8 +33,6 @@ import java.util.Collections;
/**
* ListenerProtocol
*
* @author william.liangf
*/
public
class
ProtocolListenerWrapper
implements
Protocol
{
static
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/proxy/AbstractProxyFactory.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -24,8 +25,6 @@ import com.alibaba.dubbo.rpc.service.EchoService;
/**
* AbstractProxyFactory
*
* @author william.liangf
*/
public
abstract
class
AbstractProxyFactory
implements
ProxyFactory
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/proxy/AbstractProxyInvoker.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -26,8 +27,6 @@ import java.lang.reflect.InvocationTargetException;
/**
* InvokerWrapper
*
* @author william.liangf
*/
public
abstract
class
AbstractProxyInvoker
<
T
>
implements
Invoker
<
T
>
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/proxy/InvokerInvocationHandler.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -23,8 +24,6 @@ import java.lang.reflect.Method;
/**
* InvokerHandler
*
* @author william.liangf
*/
public
class
InvokerInvocationHandler
implements
InvocationHandler
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/proxy/javassist/JavassistProxyFactory.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -25,8 +26,6 @@ import com.alibaba.dubbo.rpc.proxy.InvokerInvocationHandler;
/**
* JavaassistRpcProxyFactory
*
* @author william.liangf
*/
public
class
JavassistProxyFactory
extends
AbstractProxyFactory
{
...
...
@@ -36,7 +35,7 @@ public class JavassistProxyFactory extends AbstractProxyFactory {
}
public
<
T
>
Invoker
<
T
>
getInvoker
(
T
proxy
,
Class
<
T
>
type
,
URL
url
)
{
// TODO Wrapper
类不能正确处理带$的类名
// TODO Wrapper
cannot handle this scenario correctly: the classname contains '$'
final
Wrapper
wrapper
=
Wrapper
.
getWrapper
(
proxy
.
getClass
().
getName
().
indexOf
(
'$'
)
<
0
?
proxy
.
getClass
()
:
type
);
return
new
AbstractProxyInvoker
<
T
>(
proxy
,
type
,
url
)
{
@Override
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/proxy/jdk/JdkProxyFactory.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -26,8 +27,6 @@ import java.lang.reflect.Proxy;
/**
* JavaassistRpcProxyFactory
*
* @author william.liangf
*/
public
class
JdkProxyFactory
extends
AbstractProxyFactory
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/proxy/wrapper/StubProxyFactoryWrapper.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -36,8 +37,6 @@ import java.lang.reflect.Constructor;
/**
* StubProxyFactoryWrapper
*
* @author william.liangf
*/
public
class
StubProxyFactoryWrapper
implements
ProxyFactory
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/service/EchoService.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -17,8 +18,6 @@ package com.alibaba.dubbo.rpc.service;
/**
* Echo service.
*
* @author qian.lei
* @export
*/
public
interface
EchoService
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/service/GenericException.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -20,8 +21,6 @@ import com.alibaba.dubbo.common.utils.StringUtils;
/**
* GenericException
*
* @author william.liangf
* @serial Don't change the class name and properties.
* @export
*/
public
class
GenericException
extends
RuntimeException
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/service/GenericService.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -16,21 +17,21 @@
package
com.alibaba.dubbo.rpc.service
;
/**
*
通用服务接口
*
Generic service interface
*
* @author william.liangf
* @export
*/
public
interface
GenericService
{
/**
*
泛化调用
*
Generic invocation
*
* @param method 方法名,如:findPerson,如果有重载方法,需带上参数列表,如:findPerson(java.lang.String)
* @param parameterTypes 参数类型
* @param args 参数列表
* @return 返回值
* @throws Throwable 方法抛出的异常
* @param method Method name, e.g. findPerson. If there are overridden methods, parameter info is
* required, e.g. findPerson(java.lang.String)
* @param parameterTypes Parameter types
* @param args Arguments
* @return invocation return value
* @throws Throwable potential exception thrown from the invocation
*/
Object
$invoke
(
String
method
,
String
[]
parameterTypes
,
Object
[]
args
)
throws
GenericException
;
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/support/DelegateExporter.java
浏览文件 @
510daffd
/**
* Project: dubbo-rpc
* <p>
* File Created at 2012-2-24
* $Id$
* <p>
* Copyright 1999-2100 Alibaba.com Corporation Limited.
* All rights reserved.
* <p>
* This software is the confidential and proprietary information of
* Alibaba Company. ("Confidential Information"). You shall not
* disclose such Confidential Information and shall use it only in
* accordance with the terms of the license agreement you entered into
* with Alibaba.com.
/*
* 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
com.alibaba.dubbo.rpc.support
;
...
...
@@ -20,8 +21,6 @@ import com.alibaba.dubbo.rpc.Invoker;
/**
* DelegateExporter
* @author chao.liuc
*
*/
public
class
DelegateExporter
<
T
>
implements
Exporter
<
T
>
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/support/DelegateInvoker.java
浏览文件 @
510daffd
/*
* Copyright 1999-2012 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -23,8 +24,6 @@ import com.alibaba.dubbo.rpc.RpcException;
/**
* DelegateInvoker
*
* @author william.liangf
*/
public
abstract
class
DelegateInvoker
<
T
>
implements
Invoker
<
T
>
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/support/MockInvoker.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -37,10 +38,6 @@ import java.util.List;
import
java.util.Map
;
import
java.util.concurrent.ConcurrentHashMap
;
/**
* @author chao.liuc
* @author william.liangf
*/
final
public
class
MockInvoker
<
T
>
implements
Invoker
<
T
>
{
private
final
static
ProxyFactory
proxyFactory
=
ExtensionLoader
.
getExtensionLoader
(
ProxyFactory
.
class
).
getAdaptiveExtension
();
private
final
static
Map
<
String
,
Invoker
<?>>
mocks
=
new
ConcurrentHashMap
<
String
,
Invoker
<?>>();
...
...
@@ -118,7 +115,7 @@ final public class MockInvoker<T> implements Invoker<T> {
mock
=
mock
.
replace
(
'`'
,
'"'
);
if
(
StringUtils
.
isBlank
(
mock
))
{
throw
new
RpcException
(
" mocked exception for Service degradation. "
);
}
else
{
//
用户自定义类
}
else
{
//
user customized class
Throwable
t
=
getThrowable
(
mock
);
throw
new
RpcException
(
RpcException
.
BIZ_EXCEPTION
,
t
);
}
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/support/MockProtocol.java
浏览文件 @
510daffd
/*
* Copyright 1999-2011 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -22,9 +23,7 @@ import com.alibaba.dubbo.rpc.RpcException;
import
com.alibaba.dubbo.rpc.protocol.AbstractProtocol
;
/**
* MockProtocol 用于在consumer side 通过url及类型生成一个mockInvoker
*
* @author chao.liuc
* MockProtocol is used for generating a mock invoker by URL and type on consumer side
*/
final
public
class
MockProtocol
extends
AbstractProtocol
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/support/ProtocolUtils.java
浏览文件 @
510daffd
/*
* 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
com.alibaba.dubbo.rpc.support
;
import
com.alibaba.dubbo.common.Constants
;
import
com.alibaba.dubbo.common.URL
;
/**
* @author <a href="mailto:gang.lvg@alibaba-inc.com">kimi</a>
*/
public
class
ProtocolUtils
{
private
ProtocolUtils
()
{
...
...
dubbo-rpc/dubbo-rpc-api/src/main/java/com/alibaba/dubbo/rpc/support/RpcUtils.java
浏览文件 @
510daffd
/*
* Copyright 1999-2012 Alibaba Group.
*
* Licensed 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
*
* 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.
...
...
@@ -29,9 +30,6 @@ import java.util.concurrent.atomic.AtomicLong;
/**
* RpcUtils
*
* @author william.liangf
* @author chao.liuc
*/
public
class
RpcUtils
{
...
...
@@ -86,7 +84,7 @@ public class RpcUtils {
}
/**
*
幂等操作:异步操作默认添加invocation id
*
Idempotent operation: invocation id will be added in async operation by default
*
* @param url
* @param inv
...
...
@@ -100,13 +98,11 @@ public class RpcUtils {
private
static
boolean
isAttachInvocationId
(
URL
url
,
Invocation
invocation
)
{
String
value
=
url
.
getMethodParameter
(
invocation
.
getMethodName
(),
Constants
.
AUTO_ATTACH_INVOCATIONID_KEY
);
if
(
value
==
null
)
{
//
异步操作默认添加invocationid
//
add invocationid in async operation by default
return
isAsync
(
url
,
invocation
);
}
else
if
(
Boolean
.
TRUE
.
toString
().
equalsIgnoreCase
(
value
))
{
//设置为添加,则一定添加
return
true
;
}
else
{
//value为false时,不添加
return
false
;
}
}
...
...
@@ -151,7 +147,6 @@ public class RpcUtils {
public
static
boolean
isAsync
(
URL
url
,
Invocation
inv
)
{
boolean
isAsync
;
//如果Java代码中设置优先.
if
(
Boolean
.
TRUE
.
toString
().
equals
(
inv
.
getAttachment
(
Constants
.
ASYNC_KEY
)))
{
isAsync
=
true
;
}
else
{
...
...
@@ -162,7 +157,6 @@ public class RpcUtils {
public
static
boolean
isOneway
(
URL
url
,
Invocation
inv
)
{
boolean
isOneway
;
//如果Java代码中设置优先.
if
(
Boolean
.
FALSE
.
toString
().
equals
(
inv
.
getAttachment
(
Constants
.
RETURN_KEY
)))
{
isOneway
=
true
;
}
else
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录