Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
润土的好友猹
SkyWalking
提交
e8988866
S
SkyWalking
项目概览
润土的好友猹
/
SkyWalking
与 Fork 源项目一致
Fork自
apache / SkyWalking
通知
9
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
S
SkyWalking
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
未验证
提交
e8988866
编写于
4月 17, 2021
作者:
G
guyang
提交者:
GitHub
4月 17, 2021
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
feature: jsonrpc4j plugin (#6743)
上级
eba7a5f9
变更
31
隐藏空白更改
内联
并排
Showing
31 changed file
with
1420 addition
and
0 deletion
+1420
-0
.github/workflows/plugins-test.3.yaml
.github/workflows/plugins-test.3.yaml
+1
-0
CHANGES.md
CHANGES.md
+1
-0
apm-protocol/apm-network/src/main/java/org/apache/skywalking/apm/network/trace/component/ComponentsDefine.java
...walking/apm/network/trace/component/ComponentsDefine.java
+2
-0
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/pom.xml
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/pom.xml
+57
-0
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/JsonRpcBasicServerInvokeInterceptor.java
...plugin/jsonrpc4j/JsonRpcBasicServerInvokeInterceptor.java
+46
-0
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/JsonRpcConstants.java
...che/skywalking/apm/plugin/jsonrpc4j/JsonRpcConstants.java
+25
-0
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/JsonRpcHttpClientInterceptor.java
...ng/apm/plugin/jsonrpc4j/JsonRpcHttpClientInterceptor.java
+82
-0
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/JsonRpcHttpClientPrepareConnectionInterceptor.java
...nrpc4j/JsonRpcHttpClientPrepareConnectionInterceptor.java
+62
-0
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/JsonRpcPeerInfo.java
...ache/skywalking/apm/plugin/jsonrpc4j/JsonRpcPeerInfo.java
+51
-0
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/JsonServiceExporterInterceptor.java
.../apm/plugin/jsonrpc4j/JsonServiceExporterInterceptor.java
+82
-0
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/define/JsonRpcBasicServerInstrumentation.java
...n/jsonrpc4j/define/JsonRpcBasicServerInstrumentation.java
+67
-0
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/define/JsonRpcHttpClientInstrumentation.java
...in/jsonrpc4j/define/JsonRpcHttpClientInstrumentation.java
+116
-0
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/define/JsonServiceExporterInstrumentation.java
.../jsonrpc4j/define/JsonServiceExporterInstrumentation.java
+67
-0
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/resources/skywalking-plugin.def
...rpc4j-1.x-plugin/src/main/resources/skywalking-plugin.def
+19
-0
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/test/java/org/apache/skywalking/apm/plugin/jsonrpc4j/JsonRpcHttpClientTests.java
...ywalking/apm/plugin/jsonrpc4j/JsonRpcHttpClientTests.java
+121
-0
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/test/java/org/apache/skywalking/apm/plugin/jsonrpc4j/JsonRpcServerTests.java
...e/skywalking/apm/plugin/jsonrpc4j/JsonRpcServerTests.java
+136
-0
apm-sniffer/apm-sdk-plugin/pom.xml
apm-sniffer/apm-sdk-plugin/pom.xml
+1
-0
docs/en/setup/service-agent/java-agent/Plugin-list.md
docs/en/setup/service-agent/java-agent/Plugin-list.md
+1
-0
oap-server/server-bootstrap/src/main/resources/component-libraries.yml
...rver-bootstrap/src/main/resources/component-libraries.yml
+3
-0
test/plugin/scenarios/dubbo-2.7.x-scenario/config/expectedData.yaml
...n/scenarios/dubbo-2.7.x-scenario/config/expectedData.yaml
+1
-0
test/plugin/scenarios/jsonrpc4j-1.x-scenario/bin/startup.sh
test/plugin/scenarios/jsonrpc4j-1.x-scenario/bin/startup.sh
+21
-0
test/plugin/scenarios/jsonrpc4j-1.x-scenario/config/expectedData.yaml
...scenarios/jsonrpc4j-1.x-scenario/config/expectedData.yaml
+91
-0
test/plugin/scenarios/jsonrpc4j-1.x-scenario/configuration.yml
...plugin/scenarios/jsonrpc4j-1.x-scenario/configuration.yml
+20
-0
test/plugin/scenarios/jsonrpc4j-1.x-scenario/pom.xml
test/plugin/scenarios/jsonrpc4j-1.x-scenario/pom.xml
+119
-0
test/plugin/scenarios/jsonrpc4j-1.x-scenario/src/main/assembly/assembly.xml
...ios/jsonrpc4j-1.x-scenario/src/main/assembly/assembly.xml
+41
-0
test/plugin/scenarios/jsonrpc4j-1.x-scenario/src/main/java/org/apache/skywalking/apm/testcase/jsonrpc4j/Application.java
...apache/skywalking/apm/testcase/jsonrpc4j/Application.java
+36
-0
test/plugin/scenarios/jsonrpc4j-1.x-scenario/src/main/java/org/apache/skywalking/apm/testcase/jsonrpc4j/controller/CaseController.java
...ing/apm/testcase/jsonrpc4j/controller/CaseController.java
+52
-0
test/plugin/scenarios/jsonrpc4j-1.x-scenario/src/main/java/org/apache/skywalking/apm/testcase/jsonrpc4j/services/DemoService.java
...ywalking/apm/testcase/jsonrpc4j/services/DemoService.java
+27
-0
test/plugin/scenarios/jsonrpc4j-1.x-scenario/src/main/java/org/apache/skywalking/apm/testcase/jsonrpc4j/services/DemoServiceImp.java
...lking/apm/testcase/jsonrpc4j/services/DemoServiceImp.java
+32
-0
test/plugin/scenarios/jsonrpc4j-1.x-scenario/src/main/resources/application.yml
...jsonrpc4j-1.x-scenario/src/main/resources/application.yml
+20
-0
test/plugin/scenarios/jsonrpc4j-1.x-scenario/support-version.list
...gin/scenarios/jsonrpc4j-1.x-scenario/support-version.list
+20
-0
未找到文件。
.github/workflows/plugins-test.3.yaml
浏览文件 @
e8988866
...
...
@@ -71,6 +71,7 @@ jobs:
-
xxl-job-2.x-scenario
-
thrift-scenario
-
dbcp-2.x-scenario
-
jsonrpc4j-1.x-scenario
steps
:
-
uses
:
actions/checkout@v2
with
:
...
...
CHANGES.md
浏览文件 @
e8988866
...
...
@@ -11,6 +11,7 @@ Release Notes.
*
Add
`trace_segment_ref_limit_per_span`
configuration mechanism to avoid OOM.
*
Improve
`GlobalIdGenerator`
performance.
*
Add an agent plugin to support elasticsearch7.
*
Add
`jsonrpc4j`
agent plugin.
#### OAP-Backend
*
BugFix: filter invalid Envoy access logs whose socket address is empty.
...
...
apm-protocol/apm-network/src/main/java/org/apache/skywalking/apm/network/trace/component/ComponentsDefine.java
浏览文件 @
e8988866
...
...
@@ -194,4 +194,6 @@ public class ComponentsDefine {
public
static
final
OfficialComponent
APACHE_CXF
=
new
OfficialComponent
(
105
,
"Apache-CXF"
);
public
static
final
OfficialComponent
DOLPHIN_SCHEDULER
=
new
OfficialComponent
(
106
,
"dolphinscheduler"
);
public
static
final
OfficialComponent
JSON_RPC
=
new
OfficialComponent
(
107
,
"JsonRpc"
);
}
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/pom.xml
0 → 100644
浏览文件 @
e8988866
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ 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.
~
-->
<project
xmlns=
"http://maven.apache.org/POM/4.0.0"
xmlns:xsi=
"http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation=
"http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
>
<parent>
<artifactId>
apm-sdk-plugin
</artifactId>
<groupId>
org.apache.skywalking
</groupId>
<version>
8.6.0-SNAPSHOT
</version>
</parent>
<modelVersion>
4.0.0
</modelVersion>
<artifactId>
jsonrpc4j-1.x-plugin
</artifactId>
<properties>
<jsonrpc4j.version>
1.5.3
</jsonrpc4j.version>
<javax-servlet-api.version>
3.0.1
</javax-servlet-api.version>
</properties>
<packaging>
jar
</packaging>
<dependencies>
<dependency>
<groupId>
com.github.briandilley.jsonrpc4j
</groupId>
<artifactId>
jsonrpc4j
</artifactId>
<version>
${jsonrpc4j.version}
</version>
<scope>
provided
</scope>
</dependency>
<dependency>
<groupId>
javax.servlet
</groupId>
<artifactId>
javax.servlet-api
</artifactId>
<version>
${javax-servlet-api.version}
</version>
<scope>
provided
</scope>
</dependency>
</dependencies>
</project>
\ No newline at end of file
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/JsonRpcBasicServerInvokeInterceptor.java
0 → 100644
浏览文件 @
e8988866
/*
* 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
org.apache.skywalking.apm.plugin.jsonrpc4j
;
import
org.apache.skywalking.apm.agent.core.context.ContextManager
;
import
org.apache.skywalking.apm.agent.core.context.trace.AbstractSpan
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.EnhancedInstance
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.InstanceMethodsAroundInterceptor
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.MethodInterceptResult
;
import
java.lang.reflect.Method
;
public
class
JsonRpcBasicServerInvokeInterceptor
implements
InstanceMethodsAroundInterceptor
{
@Override
public
void
beforeMethod
(
EnhancedInstance
objInst
,
Method
method
,
Object
[]
objects
,
Class
<?>[]
classes
,
MethodInterceptResult
result
)
throws
Throwable
{
Method
rpcMethod
=
(
Method
)
objects
[
1
];
AbstractSpan
span
=
ContextManager
.
activeSpan
();
JsonRpcConstants
.
JSON_RPC_METHOD_TAG
.
set
(
span
,
rpcMethod
.
getName
());
}
@Override
public
Object
afterMethod
(
EnhancedInstance
objInst
,
Method
method
,
Object
[]
objects
,
Class
<?>[]
classes
,
Object
ret
)
throws
Throwable
{
return
ret
;
}
@Override
public
void
handleMethodException
(
EnhancedInstance
objInst
,
Method
method
,
Object
[]
objects
,
Class
<?>[]
classes
,
Throwable
throwable
)
{
ContextManager
.
activeSpan
().
log
(
throwable
);
}
}
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/JsonRpcConstants.java
0 → 100644
浏览文件 @
e8988866
/*
* 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
org.apache.skywalking.apm.plugin.jsonrpc4j
;
import
org.apache.skywalking.apm.agent.core.context.tag.StringTag
;
public
class
JsonRpcConstants
{
public
static
final
StringTag
JSON_RPC_METHOD_TAG
=
new
StringTag
(
1
,
"jsonrpc.method"
);
}
\ No newline at end of file
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/JsonRpcHttpClientInterceptor.java
0 → 100644
浏览文件 @
e8988866
/*
* 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
org.apache.skywalking.apm.plugin.jsonrpc4j
;
import
org.apache.skywalking.apm.agent.core.context.ContextCarrier
;
import
org.apache.skywalking.apm.agent.core.context.ContextManager
;
import
org.apache.skywalking.apm.agent.core.context.tag.Tags
;
import
org.apache.skywalking.apm.agent.core.context.trace.AbstractSpan
;
import
org.apache.skywalking.apm.agent.core.context.trace.SpanLayer
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.EnhancedInstance
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.InstanceConstructorInterceptor
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.InstanceMethodsAroundInterceptor
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.MethodInterceptResult
;
import
org.apache.skywalking.apm.network.trace.component.ComponentsDefine
;
import
java.lang.reflect.Method
;
import
java.net.URL
;
@SuppressWarnings
(
"unused"
)
public
class
JsonRpcHttpClientInterceptor
implements
InstanceMethodsAroundInterceptor
,
InstanceConstructorInterceptor
{
@Override
public
void
onConstruct
(
EnhancedInstance
objInst
,
Object
[]
objects
)
{
URL
url
=
(
URL
)
objects
[
1
];
JsonRpcPeerInfo
clientDto
=
new
JsonRpcPeerInfo
();
int
port
=
url
.
getPort
();
if
(
port
<
0
)
{
if
(
isHttps
(
url
))
{
port
=
443
;
}
else
{
port
=
80
;
}
}
clientDto
.
setPort
(
port
);
clientDto
.
setServiceUrl
(
url
);
objInst
.
setSkyWalkingDynamicField
(
clientDto
);
}
@Override
public
void
beforeMethod
(
EnhancedInstance
objInst
,
Method
method
,
Object
[]
objects
,
Class
<?>[]
classes
,
MethodInterceptResult
result
)
throws
Throwable
{
JsonRpcPeerInfo
clientDto
=
(
JsonRpcPeerInfo
)
objInst
.
getSkyWalkingDynamicField
();
String
methodName
=
objects
[
0
].
toString
();
String
operationName
=
clientDto
.
getServiceUrl
().
getPath
()
+
"."
+
methodName
;
AbstractSpan
span
=
ContextManager
.
createExitSpan
(
operationName
,
new
ContextCarrier
(),
clientDto
.
getServiceUrl
().
getHost
()
+
":"
+
clientDto
.
getPort
());
span
.
setComponent
(
ComponentsDefine
.
JSON_RPC
);
Tags
.
HTTP
.
METHOD
.
set
(
span
,
"POST"
);
Tags
.
URL
.
set
(
span
,
clientDto
.
getServiceUrlString
());
SpanLayer
.
asRPCFramework
(
span
);
}
@Override
public
Object
afterMethod
(
EnhancedInstance
objInst
,
Method
method
,
Object
[]
objects
,
Class
<?>[]
classes
,
Object
o
)
throws
Throwable
{
ContextManager
.
stopSpan
();
return
o
;
}
@Override
public
void
handleMethodException
(
EnhancedInstance
objInst
,
Method
method
,
Object
[]
objects
,
Class
<?>[]
classes
,
Throwable
throwable
)
{
ContextManager
.
activeSpan
().
log
(
throwable
);
}
private
boolean
isHttps
(
URL
url
)
{
return
url
.
getProtocol
().
equals
(
"https"
);
}
}
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/JsonRpcHttpClientPrepareConnectionInterceptor.java
0 → 100644
浏览文件 @
e8988866
/*
* 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
org.apache.skywalking.apm.plugin.jsonrpc4j
;
import
org.apache.skywalking.apm.agent.core.context.CarrierItem
;
import
org.apache.skywalking.apm.agent.core.context.ContextCarrier
;
import
org.apache.skywalking.apm.agent.core.context.ContextManager
;
import
org.apache.skywalking.apm.agent.core.context.trace.AbstractSpan
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.EnhancedInstance
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.InstanceMethodsAroundInterceptor
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.MethodInterceptResult
;
import
java.lang.reflect.Method
;
import
java.net.HttpURLConnection
;
@SuppressWarnings
(
"unused"
)
public
class
JsonRpcHttpClientPrepareConnectionInterceptor
implements
InstanceMethodsAroundInterceptor
{
@Override
public
void
beforeMethod
(
EnhancedInstance
objInst
,
Method
method
,
Object
[]
objects
,
Class
<?>[]
classes
,
MethodInterceptResult
result
)
{
}
@Override
public
Object
afterMethod
(
EnhancedInstance
objInst
,
Method
method
,
Object
[]
objects
,
Class
<?>[]
classes
,
Object
retObj
)
{
HttpURLConnection
connection
=
(
HttpURLConnection
)
retObj
;
AbstractSpan
span
=
ContextManager
.
activeSpan
();
if
(
span
==
null
)
{
return
retObj
;
}
ContextCarrier
carrier
=
new
ContextCarrier
();
ContextManager
.
inject
(
carrier
);
CarrierItem
item
=
carrier
.
items
();
if
(
item
.
hasNext
())
{
item
=
item
.
next
();
connection
.
setRequestProperty
(
item
.
getHeadKey
(),
item
.
getHeadValue
());
}
return
retObj
;
}
@Override
public
void
handleMethodException
(
EnhancedInstance
objInst
,
Method
method
,
Object
[]
objects
,
Class
<?>[]
classes
,
Throwable
throwable
)
{
}
}
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/JsonRpcPeerInfo.java
0 → 100644
浏览文件 @
e8988866
/*
* 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
org.apache.skywalking.apm.plugin.jsonrpc4j
;
import
java.net.URL
;
public
class
JsonRpcPeerInfo
{
private
URL
serviceUrl
;
private
String
serviceUrlString
;
public
int
getPort
()
{
return
port
;
}
public
void
setPort
(
int
port
)
{
this
.
port
=
port
;
}
private
int
port
;
public
URL
getServiceUrl
()
{
return
serviceUrl
;
}
public
void
setServiceUrl
(
URL
serviceUrl
)
{
this
.
serviceUrl
=
serviceUrl
;
this
.
serviceUrlString
=
serviceUrl
.
toString
();
}
public
String
getServiceUrlString
()
{
return
serviceUrlString
;
}
}
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/JsonServiceExporterInterceptor.java
0 → 100644
浏览文件 @
e8988866
/*
* 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
org.apache.skywalking.apm.plugin.jsonrpc4j
;
import
org.apache.skywalking.apm.agent.core.context.CarrierItem
;
import
org.apache.skywalking.apm.agent.core.context.ContextCarrier
;
import
org.apache.skywalking.apm.agent.core.context.ContextManager
;
import
org.apache.skywalking.apm.agent.core.context.tag.Tags
;
import
org.apache.skywalking.apm.agent.core.context.trace.AbstractSpan
;
import
org.apache.skywalking.apm.agent.core.context.trace.SpanLayer
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.EnhancedInstance
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.InstanceMethodsAroundInterceptor
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.MethodInterceptResult
;
import
org.apache.skywalking.apm.agent.core.util.MethodUtil
;
import
org.apache.skywalking.apm.network.trace.component.ComponentsDefine
;
import
javax.servlet.http.HttpServletRequest
;
import
javax.servlet.http.HttpServletResponse
;
import
java.lang.reflect.Method
;
public
class
JsonServiceExporterInterceptor
implements
InstanceMethodsAroundInterceptor
{
private
static
boolean
IS_SERVLET_GET_STATUS_METHOD_EXIST
;
private
static
final
String
SERVLET_RESPONSE_CLASS
=
"javax.servlet.http.HttpServletResponse"
;
private
static
final
String
GET_STATUS_METHOD
=
"getStatus"
;
static
{
IS_SERVLET_GET_STATUS_METHOD_EXIST
=
MethodUtil
.
isMethodExist
(
JsonServiceExporterInterceptor
.
class
.
getClassLoader
(),
SERVLET_RESPONSE_CLASS
,
GET_STATUS_METHOD
);
}
@Override
public
void
beforeMethod
(
EnhancedInstance
objInst
,
Method
method
,
Object
[]
objects
,
Class
<?>[]
classes
,
MethodInterceptResult
result
)
throws
Throwable
{
HttpServletRequest
request
=
(
HttpServletRequest
)
objects
[
0
];
ContextCarrier
contextCarrier
=
new
ContextCarrier
();
CarrierItem
next
=
contextCarrier
.
items
();
while
(
next
.
hasNext
())
{
next
=
next
.
next
();
next
.
setHeadValue
(
request
.
getHeader
(
next
.
getHeadKey
()));
}
AbstractSpan
span
=
ContextManager
.
createEntrySpan
(
request
.
getRequestURI
(),
contextCarrier
);
Tags
.
HTTP
.
METHOD
.
set
(
span
,
request
.
getMethod
());
Tags
.
URL
.
set
(
span
,
request
.
getRequestURL
().
toString
());
span
.
setComponent
(
ComponentsDefine
.
JSON_RPC
);
SpanLayer
.
asRPCFramework
(
span
);
}
@Override
public
Object
afterMethod
(
EnhancedInstance
objInst
,
Method
method
,
Object
[]
objects
,
Class
<?>[]
classes
,
Object
ret
)
throws
Throwable
{
HttpServletResponse
response
=
(
HttpServletResponse
)
objects
[
1
];
AbstractSpan
span
=
ContextManager
.
activeSpan
();
if
(
IS_SERVLET_GET_STATUS_METHOD_EXIST
)
{
Tags
.
STATUS_CODE
.
set
(
span
,
String
.
valueOf
(
response
.
getStatus
()));
}
ContextManager
.
stopSpan
();
return
ret
;
}
@Override
public
void
handleMethodException
(
EnhancedInstance
objInst
,
Method
method
,
Object
[]
objects
,
Class
<?>[]
classes
,
Throwable
throwable
)
{
}
}
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/define/JsonRpcBasicServerInstrumentation.java
0 → 100644
浏览文件 @
e8988866
/*
* 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
org.apache.skywalking.apm.plugin.jsonrpc4j.define
;
import
net.bytebuddy.description.method.MethodDescription
;
import
net.bytebuddy.matcher.ElementMatcher
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.ConstructorInterceptPoint
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.InstanceMethodsInterceptPoint
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.ClassInstanceMethodsEnhancePluginDefine
;
import
org.apache.skywalking.apm.agent.core.plugin.match.ClassMatch
;
import
org.apache.skywalking.apm.agent.core.plugin.match.NameMatch
;
import
static
net
.
bytebuddy
.
matcher
.
ElementMatchers
.
named
;
public
class
JsonRpcBasicServerInstrumentation
extends
ClassInstanceMethodsEnhancePluginDefine
{
public
static
final
String
ENHANCE_CLASS
=
"com.googlecode.jsonrpc4j.JsonRpcBasicServer"
;
public
static
final
String
INVOKE_INTERCEPTOR
=
"org.apache.skywalking.apm.plugin.jsonrpc4j.JsonRpcBasicServerInvokeInterceptor"
;
@Override
protected
ClassMatch
enhanceClass
()
{
return
NameMatch
.
byName
(
ENHANCE_CLASS
);
}
@Override
public
ConstructorInterceptPoint
[]
getConstructorsInterceptPoints
()
{
return
new
ConstructorInterceptPoint
[
0
];
}
@Override
public
InstanceMethodsInterceptPoint
[]
getInstanceMethodsInterceptPoints
()
{
return
new
InstanceMethodsInterceptPoint
[]{
new
InstanceMethodsInterceptPoint
()
{
@Override
public
ElementMatcher
<
MethodDescription
>
getMethodsMatcher
()
{
return
named
(
"invoke"
);
}
@Override
public
String
getMethodsInterceptor
()
{
return
INVOKE_INTERCEPTOR
;
}
@Override
public
boolean
isOverrideArgs
()
{
return
false
;
}
}
};
}
}
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/define/JsonRpcHttpClientInstrumentation.java
0 → 100644
浏览文件 @
e8988866
/*
* 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
org.apache.skywalking.apm.plugin.jsonrpc4j.define
;
import
net.bytebuddy.description.method.MethodDescription
;
import
net.bytebuddy.matcher.ElementMatcher
;
import
net.bytebuddy.matcher.ElementMatchers
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.ConstructorInterceptPoint
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.InstanceMethodsInterceptPoint
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.ClassInstanceMethodsEnhancePluginDefine
;
import
org.apache.skywalking.apm.agent.core.plugin.match.ClassMatch
;
import
org.apache.skywalking.apm.agent.core.plugin.match.NameMatch
;
import
java.net.URL
;
import
static
org
.
apache
.
skywalking
.
apm
.
agent
.
core
.
plugin
.
bytebuddy
.
ArgumentTypeNameMatch
.
takesArgumentWithType
;
@SuppressWarnings
(
"unused"
)
public
class
JsonRpcHttpClientInstrumentation
extends
ClassInstanceMethodsEnhancePluginDefine
{
public
static
final
String
ENHANCE_CLASS
=
"com.googlecode.jsonrpc4j.JsonRpcHttpClient"
;
public
static
final
String
INTERCEPTOR_CLASS
=
"org.apache.skywalking.apm.plugin.jsonrpc4j.JsonRpcHttpClientInterceptor"
;
public
static
final
String
PER_CONNECTION_INTERCEPTOR_CLASS
=
"org.apache.skywalking.apm.plugin.jsonrpc4j.JsonRpcHttpClientPrepareConnectionInterceptor"
;
@Override
protected
ClassMatch
enhanceClass
()
{
return
NameMatch
.
byName
(
ENHANCE_CLASS
);
}
@Override
public
ConstructorInterceptPoint
[]
getConstructorsInterceptPoints
()
{
return
new
ConstructorInterceptPoint
[]{
new
ConstructorInterceptPoint
()
{
@Override
public
ElementMatcher
<
MethodDescription
>
getConstructorMatcher
()
{
return
ElementMatchers
.
takesArguments
(
6
).
and
(
ElementMatchers
.
takesArgument
(
1
,
URL
.
class
));
}
@Override
public
String
getConstructorInterceptor
()
{
return
INTERCEPTOR_CLASS
;
}
},
new
ConstructorInterceptPoint
()
{
@Override
public
ElementMatcher
<
MethodDescription
>
getConstructorMatcher
()
{
return
ElementMatchers
.
takesArguments
(
5
).
and
(
ElementMatchers
.
takesArgument
(
1
,
URL
.
class
));
}
@Override
public
String
getConstructorInterceptor
()
{
return
INTERCEPTOR_CLASS
;
}
}
};
}
@Override
public
InstanceMethodsInterceptPoint
[]
getInstanceMethodsInterceptPoints
()
{
return
new
InstanceMethodsInterceptPoint
[]{
new
InstanceMethodsInterceptPoint
()
{
@Override
public
ElementMatcher
<
MethodDescription
>
getMethodsMatcher
()
{
return
ElementMatchers
.
named
(
"invoke"
).
and
(
ElementMatchers
.
takesArguments
(
4
))
.
and
(
takesArgumentWithType
(
2
,
"java.lang.reflect.Type"
));
}
@Override
public
String
getMethodsInterceptor
()
{
return
INTERCEPTOR_CLASS
;
}
@Override
public
boolean
isOverrideArgs
()
{
return
false
;
}
},
new
InstanceMethodsInterceptPoint
()
{
@Override
public
ElementMatcher
<
MethodDescription
>
getMethodsMatcher
()
{
return
ElementMatchers
.
named
(
"prepareConnection"
);
}
@Override
public
String
getMethodsInterceptor
()
{
return
PER_CONNECTION_INTERCEPTOR_CLASS
;
}
@Override
public
boolean
isOverrideArgs
()
{
return
false
;
}
}
};
}
}
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/java/org/apache/skywalking/apm/plugin/jsonrpc4j/define/JsonServiceExporterInstrumentation.java
0 → 100644
浏览文件 @
e8988866
/*
* 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
org.apache.skywalking.apm.plugin.jsonrpc4j.define
;
import
net.bytebuddy.description.method.MethodDescription
;
import
net.bytebuddy.matcher.ElementMatcher
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.ConstructorInterceptPoint
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.InstanceMethodsInterceptPoint
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.ClassInstanceMethodsEnhancePluginDefine
;
import
org.apache.skywalking.apm.agent.core.plugin.match.ClassMatch
;
import
org.apache.skywalking.apm.agent.core.plugin.match.NameMatch
;
import
static
net
.
bytebuddy
.
matcher
.
ElementMatchers
.
named
;
public
class
JsonServiceExporterInstrumentation
extends
ClassInstanceMethodsEnhancePluginDefine
{
public
static
final
String
ENHANCE_CLASS
=
"com.googlecode.jsonrpc4j.spring.JsonServiceExporter"
;
public
static
final
String
INTERCEPTOR_CLASS
=
"org.apache.skywalking.apm.plugin.jsonrpc4j.JsonServiceExporterInterceptor"
;
@Override
protected
ClassMatch
enhanceClass
()
{
return
NameMatch
.
byName
(
ENHANCE_CLASS
);
}
@Override
public
ConstructorInterceptPoint
[]
getConstructorsInterceptPoints
()
{
return
new
ConstructorInterceptPoint
[
0
];
}
@Override
public
InstanceMethodsInterceptPoint
[]
getInstanceMethodsInterceptPoints
()
{
return
new
InstanceMethodsInterceptPoint
[]{
new
InstanceMethodsInterceptPoint
()
{
@Override
public
ElementMatcher
<
MethodDescription
>
getMethodsMatcher
()
{
return
named
(
"handleRequest"
);
}
@Override
public
String
getMethodsInterceptor
()
{
return
INTERCEPTOR_CLASS
;
}
@Override
public
boolean
isOverrideArgs
()
{
return
false
;
}
}
};
}
}
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/main/resources/skywalking-plugin.def
0 → 100644
浏览文件 @
e8988866
# 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.
jsonrpc4j=org.apache.skywalking.apm.plugin.jsonrpc4j.define.JsonRpcHttpClientInstrumentation
jsonrpc4j=org.apache.skywalking.apm.plugin.jsonrpc4j.define.JsonRpcBasicServerInstrumentation
jsonrpc4j=org.apache.skywalking.apm.plugin.jsonrpc4j.define.JsonServiceExporterInstrumentation
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/test/java/org/apache/skywalking/apm/plugin/jsonrpc4j/JsonRpcHttpClientTests.java
0 → 100644
浏览文件 @
e8988866
/*
* 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
org.apache.skywalking.apm.plugin.jsonrpc4j
;
import
com.fasterxml.jackson.databind.ObjectMapper
;
import
com.googlecode.jsonrpc4j.JsonRpcHttpClient
;
import
org.apache.skywalking.apm.agent.core.boot.OverrideImplementor
;
import
org.apache.skywalking.apm.agent.core.context.ContextManagerExtendService
;
import
org.apache.skywalking.apm.agent.core.context.trace.AbstractTracingSpan
;
import
org.apache.skywalking.apm.agent.core.context.trace.TraceSegment
;
import
org.apache.skywalking.apm.agent.core.context.util.TagValuePair
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.EnhancedInstance
;
import
org.apache.skywalking.apm.agent.test.helper.SegmentHelper
;
import
org.apache.skywalking.apm.agent.test.helper.SpanHelper
;
import
org.apache.skywalking.apm.agent.test.tools.AgentServiceRule
;
import
org.apache.skywalking.apm.agent.test.tools.SegmentStorage
;
import
org.apache.skywalking.apm.agent.test.tools.SegmentStoragePoint
;
import
org.apache.skywalking.apm.agent.test.tools.TracingSegmentRunner
;
import
org.junit.Assert
;
import
org.junit.Before
;
import
org.junit.Rule
;
import
org.junit.Test
;
import
org.junit.runner.RunWith
;
import
org.powermock.modules.junit4.PowerMockRunner
;
import
org.powermock.modules.junit4.PowerMockRunnerDelegate
;
import
java.net.HttpURLConnection
;
import
java.net.URL
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
import
static
org
.
hamcrest
.
CoreMatchers
.
is
;
import
static
org
.
junit
.
Assert
.
assertThat
;
@RunWith
(
PowerMockRunner
.
class
)
@PowerMockRunnerDelegate
(
TracingSegmentRunner
.
class
)
public
class
JsonRpcHttpClientTests
{
@SegmentStoragePoint
private
SegmentStorage
segmentStorage
;
@Rule
public
AgentServiceRule
serviceRule
=
new
AgentServiceRule
();
private
MockJsonRpcHttpClient
enhancedInstance
;
private
ObjectMapper
objectMapper
=
new
ObjectMapper
();
private
JsonRpcHttpClientInterceptor
httpClientInterceptor
;
private
JsonRpcHttpClientPrepareConnectionInterceptor
jsonRpcHttpClientPrepareConnectionInterceptor
;
private
URL
url
;
private
HttpURLConnection
httpURLConnection
;
@Before
public
void
setUp
()
throws
Exception
{
url
=
new
URL
(
"HTTP://localhost:8080/test"
);
enhancedInstance
=
new
MockJsonRpcHttpClient
(
objectMapper
,
url
,
new
HashMap
<>(),
false
,
false
);
httpClientInterceptor
=
new
JsonRpcHttpClientInterceptor
();
jsonRpcHttpClientPrepareConnectionInterceptor
=
new
JsonRpcHttpClientPrepareConnectionInterceptor
();
httpURLConnection
=
(
HttpURLConnection
)
url
.
openConnection
();
}
@Test
public
void
testMethodAround
()
throws
Throwable
{
Object
[]
objects
=
new
Object
[]{
"OperationKey"
,
url
};
httpClientInterceptor
.
onConstruct
(
enhancedInstance
,
objects
);
httpClientInterceptor
.
beforeMethod
(
enhancedInstance
,
null
,
objects
,
null
,
null
);
jsonRpcHttpClientPrepareConnectionInterceptor
.
afterMethod
(
enhancedInstance
,
null
,
null
,
null
,
httpURLConnection
);
httpClientInterceptor
.
afterMethod
(
enhancedInstance
,
null
,
objects
,
null
,
null
);
assertThat
(
segmentStorage
.
getTraceSegments
().
size
(),
is
(
1
));
TraceSegment
traceSegment
=
segmentStorage
.
getTraceSegments
().
get
(
0
);
Assert
.
assertEquals
(
1
,
SegmentHelper
.
getSpans
(
traceSegment
).
size
());
AbstractTracingSpan
finishedSpan
=
SegmentHelper
.
getSpans
(
traceSegment
).
get
(
0
);
List
<
TagValuePair
>
tags
=
SpanHelper
.
getTags
(
finishedSpan
);
assertThat
(
tags
.
size
(),
is
(
2
));
assertThat
(
tags
.
get
(
0
).
getValue
(),
is
(
"POST"
));
assertThat
(
tags
.
get
(
1
).
getValue
(),
is
(
url
.
toString
()));
Assert
.
assertEquals
(
false
,
SpanHelper
.
getErrorOccurred
(
finishedSpan
));
}
private
class
MockJsonRpcHttpClient
extends
JsonRpcHttpClient
implements
EnhancedInstance
{
private
Object
object
;
public
MockJsonRpcHttpClient
(
ObjectMapper
mapper
,
URL
serviceUrl
,
Map
<
String
,
String
>
headers
,
boolean
gzipRequests
,
boolean
acceptGzipResponses
)
{
super
(
mapper
,
serviceUrl
,
headers
,
gzipRequests
,
acceptGzipResponses
);
}
@Override
public
Object
getSkyWalkingDynamicField
()
{
return
object
;
}
@Override
public
void
setSkyWalkingDynamicField
(
Object
value
)
{
object
=
value
;
}
}
@OverrideImplementor
(
ContextManagerExtendService
.
class
)
public
static
class
ContextManagerExtendOverrideService
extends
ContextManagerExtendService
{
}
}
apm-sniffer/apm-sdk-plugin/jsonrpc4j-1.x-plugin/src/test/java/org/apache/skywalking/apm/plugin/jsonrpc4j/JsonRpcServerTests.java
0 → 100644
浏览文件 @
e8988866
/*
* 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
org.apache.skywalking.apm.plugin.jsonrpc4j
;
import
com.fasterxml.jackson.databind.ObjectMapper
;
import
com.googlecode.jsonrpc4j.JsonRpcBasicServer
;
import
org.apache.skywalking.apm.agent.core.context.trace.AbstractTracingSpan
;
import
org.apache.skywalking.apm.agent.core.context.trace.TraceSegment
;
import
org.apache.skywalking.apm.agent.core.context.util.TagValuePair
;
import
org.apache.skywalking.apm.agent.core.plugin.interceptor.enhance.EnhancedInstance
;
import
org.apache.skywalking.apm.agent.test.helper.SegmentHelper
;
import
org.apache.skywalking.apm.agent.test.helper.SpanHelper
;
import
org.apache.skywalking.apm.agent.test.tools.AgentServiceRule
;
import
org.apache.skywalking.apm.agent.test.tools.SegmentStorage
;
import
org.apache.skywalking.apm.agent.test.tools.SegmentStoragePoint
;
import
org.apache.skywalking.apm.agent.test.tools.TracingSegmentRunner
;
import
org.junit.Assert
;
import
org.junit.Before
;
import
org.junit.Rule
;
import
org.junit.Test
;
import
org.junit.runner.RunWith
;
import
org.powermock.modules.junit4.PowerMockRunner
;
import
org.powermock.modules.junit4.PowerMockRunnerDelegate
;
import
javax.servlet.http.HttpServletRequest
;
import
javax.servlet.http.HttpServletResponse
;
import
static
org
.
hamcrest
.
CoreMatchers
.
is
;
import
static
org
.
junit
.
Assert
.
assertThat
;
import
static
org
.
mockito
.
Mockito
.
mock
;
import
static
org
.
mockito
.
Mockito
.
when
;
import
java.util.List
;
@RunWith
(
PowerMockRunner
.
class
)
@PowerMockRunnerDelegate
(
TracingSegmentRunner
.
class
)
public
class
JsonRpcServerTests
{
@SegmentStoragePoint
private
SegmentStorage
segmentStorage
;
@Rule
public
AgentServiceRule
serviceRule
=
new
AgentServiceRule
();
private
MockJsonRpcBasicServer
mockJsonRpcBasicServer
;
private
MockJsonServiceExporterInterceptor
mockJsonServiceExporterInterceptor
;
private
JsonServiceExporterInterceptor
jsonServiceExporterInterceptor
;
private
JsonRpcBasicServerInvokeInterceptor
jsonRpcBasicServerInvokeInterceptor
;
private
ObjectMapper
objectMapper
=
new
ObjectMapper
();
private
HttpServletRequest
httpServletRequest
;
private
HttpServletResponse
httpServletResponse
;
@Before
public
void
setUp
()
throws
Exception
{
httpServletRequest
=
mock
(
HttpServletRequest
.
class
);
httpServletResponse
=
mock
(
HttpServletResponse
.
class
);
when
(
httpServletRequest
.
getRequestURI
()).
thenReturn
(
"/test"
);
when
(
httpServletRequest
.
getRequestURL
()).
thenReturn
(
new
StringBuffer
(
"http://localhost:8080"
));
when
(
httpServletResponse
.
getStatus
()).
thenReturn
(
200
);
httpServletResponse
=
mock
(
HttpServletResponse
.
class
);
jsonRpcBasicServerInvokeInterceptor
=
new
JsonRpcBasicServerInvokeInterceptor
();
jsonServiceExporterInterceptor
=
new
JsonServiceExporterInterceptor
();
mockJsonRpcBasicServer
=
new
MockJsonRpcBasicServer
(
objectMapper
,
null
);
mockJsonServiceExporterInterceptor
=
new
MockJsonServiceExporterInterceptor
();
}
@Test
public
void
testJsonRpcServerMethodAround
()
throws
Throwable
{
Object
[]
objects
=
new
Object
[]{
httpServletRequest
};
jsonServiceExporterInterceptor
.
beforeMethod
(
mockJsonServiceExporterInterceptor
,
null
,
objects
,
null
,
null
);
objects
=
new
Object
[]{
null
,
JsonRpcServerTests
.
class
.
getMethod
(
"testJsonRpcServerMethodAround"
)};
jsonRpcBasicServerInvokeInterceptor
.
beforeMethod
(
mockJsonRpcBasicServer
,
null
,
objects
,
null
,
null
);
objects
=
new
Object
[]{
null
,
httpServletResponse
};
jsonServiceExporterInterceptor
.
afterMethod
(
mockJsonServiceExporterInterceptor
,
null
,
objects
,
null
,
null
);
assertThat
(
segmentStorage
.
getTraceSegments
().
size
(),
is
(
1
));
TraceSegment
traceSegment
=
segmentStorage
.
getTraceSegments
().
get
(
0
);
Assert
.
assertEquals
(
1
,
SegmentHelper
.
getSpans
(
traceSegment
).
size
());
AbstractTracingSpan
finishedSpan
=
SegmentHelper
.
getSpans
(
traceSegment
).
get
(
0
);
List
<
TagValuePair
>
tags
=
SpanHelper
.
getTags
(
finishedSpan
);
assertThat
(
tags
.
size
(),
is
(
4
));
Assert
.
assertEquals
(
false
,
SpanHelper
.
getErrorOccurred
(
finishedSpan
));
}
private
class
MockJsonRpcBasicServer
extends
JsonRpcBasicServer
implements
EnhancedInstance
{
public
MockJsonRpcBasicServer
(
ObjectMapper
mapper
,
Object
handler
)
{
super
(
mapper
,
handler
);
}
@Override
public
Object
getSkyWalkingDynamicField
()
{
return
null
;
}
@Override
public
void
setSkyWalkingDynamicField
(
Object
value
)
{
}
}
private
class
MockJsonServiceExporterInterceptor
extends
JsonServiceExporterInterceptor
implements
EnhancedInstance
{
@Override
public
Object
getSkyWalkingDynamicField
()
{
return
null
;
}
@Override
public
void
setSkyWalkingDynamicField
(
Object
value
)
{
}
}
}
apm-sniffer/apm-sdk-plugin/pom.xml
浏览文件 @
e8988866
...
...
@@ -109,6 +109,7 @@
<module>
mssql-jtds-1.x-plugin
</module>
<module>
mssql-jdbc-plugin
</module>
<module>
cxf-3.x-plugin
</module>
<module>
jsonrpc4j-1.x-plugin
</module>
</modules>
<packaging>
pom
</packaging>
...
...
docs/en/setup/service-agent/java-agent/Plugin-list.md
浏览文件 @
e8988866
...
...
@@ -114,3 +114,4 @@
-
mssql-jtds-1.x
-
mssql-jdbc
-
apache-cxf-3.x
-
jsonrpc4j
oap-server/server-bootstrap/src/main/resources/component-libraries.yml
浏览文件 @
e8988866
...
...
@@ -350,6 +350,9 @@ Apache-CXF:
dolphinscheduler
:
id
:
106
languages
:
Java
JsonRpc
:
id
:
107
languages
:
Java
# .NET/.NET Core components
# [3000, 4000) for C#/.NET only
...
...
test/plugin/scenarios/dubbo-2.7.x-scenario/config/expectedData.yaml
浏览文件 @
e8988866
...
...
@@ -13,6 +13,7 @@
# 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.
segmentItems
:
-
serviceName
:
dubbo-2.7.x-scenario
segmentSize
:
ge
3
...
...
test/plugin/scenarios/jsonrpc4j-1.x-scenario/bin/startup.sh
0 → 100644
浏览文件 @
e8988866
#!/bin/bash
#
# 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.
home
=
"
$(
cd
"
$(
dirname
$0
)
"
;
pwd
)
"
java
-jar
${
agent_opts
}
${
home
}
/../libs/jsonrpc4j-1.x-scenario.jar &
\ No newline at end of file
test/plugin/scenarios/jsonrpc4j-1.x-scenario/config/expectedData.yaml
0 → 100644
浏览文件 @
e8988866
# 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.
segmentItems
:
-
serviceName
:
jsonrpc4j-1.x-scenario
segmentSize
:
ge
2
segments
:
-
segmentId
:
not
null
spans
:
-
operationName
:
/jsonrpc4j-1.x-scenario/path/to/demo-service.sayHello
operationId
:
0
parentSpanId
:
0
spanId
:
1
spanLayer
:
RPCFramework
startTime
:
nq
0
endTime
:
nq
0
componentId
:
107
isError
:
false
spanType
:
Exit
peer
:
localhost:8080
skipAnalysis
:
false
tags
:
-
{
key
:
http.method
,
value
:
POST
}
-
{
key
:
url
,
value
:
'
http://localhost:8080/jsonrpc4j-1.x-scenario/path/to/demo-service'
,
}
-
operationName
:
/jsonrpc4j-1.x-scenario/case/json-rpc
operationId
:
0
parentSpanId
:
-1
spanId
:
0
spanLayer
:
Http
startTime
:
nq
0
endTime
:
nq
0
componentId
:
1
isError
:
false
spanType
:
Entry
peer
:
'
'
skipAnalysis
:
false
tags
:
-
{
key
:
url
,
value
:
'
http://localhost:8080/jsonrpc4j-1.x-scenario/case/json-rpc'
,
}
-
{
key
:
http.method
,
value
:
GET
}
-
segmentId
:
not
null
spans
:
-
operationName
:
/jsonrpc4j-1.x-scenario/path/to/demo-service
operationId
:
0
parentSpanId
:
-1
spanId
:
0
spanLayer
:
RPCFramework
startTime
:
nq
0
endTime
:
nq
0
componentId
:
107
isError
:
false
spanType
:
Entry
peer
:
'
'
skipAnalysis
:
false
tags
:
-
{
key
:
http.method
,
value
:
POST
}
-
{
key
:
url
,
value
:
'
http://localhost:8080/jsonrpc4j-1.x-scenario/path/to/demo-service'
,
}
-
{
key
:
jsonrpc.method
,
value
:
sayHello
}
-
{
key
:
status_code
,
value
:
'
200'
}
refs
:
-
{
parentEndpoint
:
/jsonrpc4j-1.x-scenario/case/json-rpc
,
networkAddress
:
'
localhost:8080'
,
refType
:
CrossProcess
,
parentSpanId
:
1
,
parentTraceSegmentId
:
not null
,
parentServiceInstance
:
not null
,
parentService
:
jsonrpc4j-1.x-scenario
,
traceId
:
not null
,
}
test/plugin/scenarios/jsonrpc4j-1.x-scenario/configuration.yml
0 → 100644
浏览文件 @
e8988866
# 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.
type
:
jvm
entryService
:
http://localhost:8080/jsonrpc4j-1.x-scenario/case/json-rpc
healthCheck
:
http://localhost:8080/jsonrpc4j-1.x-scenario/case/healthCheck
startScript
:
./bin/startup.sh
test/plugin/scenarios/jsonrpc4j-1.x-scenario/pom.xml
0 → 100644
浏览文件 @
e8988866
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ 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.
~
-->
<project
xmlns=
"http://maven.apache.org/POM/4.0.0"
xmlns:xsi=
"http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation=
"http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
>
<modelVersion>
4.0.0
</modelVersion>
<groupId>
org.apache.skywalking
</groupId>
<artifactId>
jsonrpc4j-1.x-scenario
</artifactId>
<version>
5.0.0
</version>
<packaging>
jar
</packaging>
<properties>
<maven.compiler.source>
8
</maven.compiler.source>
<maven.compiler.target>
8
</maven.compiler.target>
<project.build.sourceEncoding>
UTF-8
</project.build.sourceEncoding>
<compiler.version>
1.8
</compiler.version>
<spring.boot.version>
2.1.6.RELEASE
</spring.boot.version>
<jsonrpc.version>
1.5.3
</jsonrpc.version>
</properties>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-dependencies
</artifactId>
<version>
${spring.boot.version}
</version>
<type>
pom
</type>
<scope>
import
</scope>
</dependency>
</dependencies>
</dependencyManagement>
<dependencies>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-web
</artifactId>
</dependency>
<dependency>
<groupId>
com.github.briandilley.jsonrpc4j
</groupId>
<artifactId>
jsonrpc4j
</artifactId>
<version>
${jsonrpc.version}
</version>
</dependency>
</dependencies>
<build>
<finalName>
jsonrpc4j-1.x-scenario
</finalName>
<plugins>
<plugin>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-maven-plugin
</artifactId>
<executions>
<execution>
<goals>
<goal>
repackage
</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<artifactId>
maven-compiler-plugin
</artifactId>
<configuration>
<source>
${compiler.version}
</source>
<target>
${compiler.version}
</target>
<encoding>
${project.build.sourceEncoding}
</encoding>
</configuration>
</plugin>
<plugin>
<groupId>
org.apache.maven.plugins
</groupId>
<artifactId>
maven-assembly-plugin
</artifactId>
<executions>
<execution>
<id>
assemble
</id>
<phase>
package
</phase>
<goals>
<goal>
single
</goal>
</goals>
<configuration>
<descriptors>
<descriptor>
src/main/assembly/assembly.xml
</descriptor>
</descriptors>
<outputDirectory>
./target/
</outputDirectory>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
<pluginRepositories>
<pluginRepository>
<id>
spring-snapshots
</id>
<url>
https://repo.spring.io/snapshot
</url>
</pluginRepository>
<pluginRepository>
<id>
spring-milestones
</id>
<url>
https://repo.spring.io/milestone
</url>
</pluginRepository>
</pluginRepositories>
</project>
\ No newline at end of file
test/plugin/scenarios/jsonrpc4j-1.x-scenario/src/main/assembly/assembly.xml
0 → 100644
浏览文件 @
e8988866
<?xml version="1.0" encoding="UTF-8"?>
<!--
~ 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.
~
-->
<assembly
xmlns=
"http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2"
xmlns:xsi=
"http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation=
"http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 http://maven.apache.org/xsd/assembly-1.1.2.xsd"
>
<formats>
<format>
zip
</format>
</formats>
<fileSets>
<fileSet>
<directory>
./bin
</directory>
<fileMode>
0775
</fileMode>
</fileSet>
</fileSets>
<files>
<file>
<source>
./target/jsonrpc4j-1.x-scenario.jar
</source>
<outputDirectory>
./libs
</outputDirectory>
<fileMode>
0775
</fileMode>
</file>
</files>
</assembly>
test/plugin/scenarios/jsonrpc4j-1.x-scenario/src/main/java/org/apache/skywalking/apm/testcase/jsonrpc4j/Application.java
0 → 100644
浏览文件 @
e8988866
/*
* 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
org.apache.skywalking.apm.testcase.jsonrpc4j
;
import
com.googlecode.jsonrpc4j.spring.AutoJsonRpcServiceImplExporter
;
import
org.springframework.boot.SpringApplication
;
import
org.springframework.boot.autoconfigure.SpringBootApplication
;
import
org.springframework.context.annotation.Bean
;
@SpringBootApplication
public
class
Application
{
public
static
void
main
(
String
[]
args
)
{
SpringApplication
.
run
(
Application
.
class
,
args
);
}
@Bean
public
AutoJsonRpcServiceImplExporter
serviceImplExporter
()
{
return
new
AutoJsonRpcServiceImplExporter
();
}
}
test/plugin/scenarios/jsonrpc4j-1.x-scenario/src/main/java/org/apache/skywalking/apm/testcase/jsonrpc4j/controller/CaseController.java
0 → 100644
浏览文件 @
e8988866
/*
* 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
org.apache.skywalking.apm.testcase.jsonrpc4j.controller
;
import
com.googlecode.jsonrpc4j.JsonRpcHttpClient
;
import
com.googlecode.jsonrpc4j.ProxyUtil
;
import
org.apache.skywalking.apm.testcase.jsonrpc4j.services.DemoService
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.ResponseBody
;
import
org.springframework.web.bind.annotation.RestController
;
import
java.net.MalformedURLException
;
import
java.net.URL
;
@RestController
@RequestMapping
(
"/case"
)
public
class
CaseController
{
private
static
final
String
SUCCESS
=
"Success"
;
@RequestMapping
(
"/healthCheck"
)
@ResponseBody
public
String
healthCheck
()
{
return
SUCCESS
;
}
@RequestMapping
(
"/json-rpc"
)
@ResponseBody
public
String
jsonRpc
()
throws
MalformedURLException
{
JsonRpcHttpClient
client
=
new
JsonRpcHttpClient
(
new
URL
(
"http://localhost:8080/jsonrpc4j-1.x-scenario/path/to/demo-service"
));
DemoService
demoService
=
ProxyUtil
.
createClientProxy
(
getClass
().
getClassLoader
(),
DemoService
.
class
,
client
);
demoService
.
sayHello
();
return
SUCCESS
;
}
}
test/plugin/scenarios/jsonrpc4j-1.x-scenario/src/main/java/org/apache/skywalking/apm/testcase/jsonrpc4j/services/DemoService.java
0 → 100644
浏览文件 @
e8988866
/*
* 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
org.apache.skywalking.apm.testcase.jsonrpc4j.services
;
import
com.googlecode.jsonrpc4j.JsonRpcService
;
@JsonRpcService
(
"/path/to/demo-service"
)
public
interface
DemoService
{
String
sayHello
();
}
test/plugin/scenarios/jsonrpc4j-1.x-scenario/src/main/java/org/apache/skywalking/apm/testcase/jsonrpc4j/services/DemoServiceImp.java
0 → 100644
浏览文件 @
e8988866
/*
* 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
org.apache.skywalking.apm.testcase.jsonrpc4j.services
;
import
com.googlecode.jsonrpc4j.spring.AutoJsonRpcServiceImpl
;
import
org.springframework.stereotype.Service
;
@AutoJsonRpcServiceImpl
@Service
public
class
DemoServiceImp
implements
DemoService
{
@Override
public
String
sayHello
()
{
return
"hello"
;
}
}
test/plugin/scenarios/jsonrpc4j-1.x-scenario/src/main/resources/application.yml
0 → 100644
浏览文件 @
e8988866
# 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.
server
:
port
:
8080
servlet
:
context-path
:
/jsonrpc4j-1.x-scenario
test/plugin/scenarios/jsonrpc4j-1.x-scenario/support-version.list
0 → 100644
浏览文件 @
e8988866
# 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.
1.6
1.5.3
1.4.6
1.3.3
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录