Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
阿信在这里
SkyWalking
提交
0d2ee9af
S
SkyWalking
项目概览
阿信在这里
/
SkyWalking
与 Fork 源项目一致
Fork自
山不在高_有仙则灵 / SkyWalking
通知
1
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,发现更多精彩内容 >>
提交
0d2ee9af
编写于
11月 26, 2016
作者:
wu-sheng
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix more issue. change README.md to English.
上级
d81a3325
变更
8
隐藏空白更改
内联
并排
Showing
8 changed file
with
129 addition
and
166 deletion
+129
-166
README.md
README.md
+12
-64
skywalking-sniffer/skywalking-agent/dependency-reduced-pom.xml
...lking-sniffer/skywalking-agent/dependency-reduced-pom.xml
+101
-90
skywalking-sniffer/skywalking-agent/src/main/java/com/a/eye/skywalking/agent/SkyWalkingAgent.java
...main/java/com/a/eye/skywalking/agent/SkyWalkingAgent.java
+4
-4
skywalking-sniffer/skywalking-api/pom.xml
skywalking-sniffer/skywalking-api/pom.xml
+0
-6
skywalking-sniffer/skywalking-api/src/main/java/com/a/eye/skywalking/conf/Config.java
...g-api/src/main/java/com/a/eye/skywalking/conf/Config.java
+2
-0
skywalking-sniffer/skywalking-api/src/main/java/com/a/eye/skywalking/conf/ConfigInitializer.java
...ain/java/com/a/eye/skywalking/conf/ConfigInitializer.java
+8
-1
skywalking-sniffer/skywalking-api/src/main/java/com/a/eye/skywalking/disruptor/ack/SendAckSpanEventHandler.java
...eye/skywalking/disruptor/ack/SendAckSpanEventHandler.java
+1
-0
skywalking-sniffer/skywalking-api/src/main/java/com/a/eye/skywalking/disruptor/request/SendRequestSpanEventHandler.java
...alking/disruptor/request/SendRequestSpanEventHandler.java
+1
-1
未找到文件。
README.md
浏览文件 @
0d2ee9af
...
...
@@ -104,58 +104,23 @@ ___
## instrument javaagent jdk version
-
support 1.6+ , instruments applications can run in jdk6
## 编译与部署 / Build and deploy
-
服务端发布版本
[
下载
](
https://github.com/wu-sheng/sky-walking/releases
)
(
.tar.gz
)
## Download and deploy servers
-
Download Server release version.
[
Download
](
https://github.com/wu-sheng/sky-walking/releases
)
(
.tar.gz
)
-
[
配置应用服务器
](
CONFIG_DOC.md
)
-
[
config servers
](
CONFIG_DOC.md
)
-
如果您想自己编译最新版本,可参考《
[
代码编译说明
](
BUILD_DOC.md
)
》
-
[
Code compilation instructions
](
BUILD_DOC.md
)
### run all servers in a Docker
-
Docker version is good quick-test.
## Download offical agent
[
![Download
](
https://api.bintray.com/packages/wu-sheng/skywalking/com.a.eye.skywalking-agent/images/download.svg
)
](https://bintray.com/wu-sheng/skywalking/com.a.eye.skywalking-agent/_latestVersion)
-
通过github-release
[
下载
](
https://github.com/wu-sheng/sky-walking/releases
)
-
通过
[
skywalking bintray官网
](
https://bintray.com/wu-sheng/skywalking/
)
托管,可使用公网仓库
[
https://jcenter.bintray.com/
](
https://jcenter.bintray.com/
)
下载。
-
use public repository
[
https://jcenter.bintray.com/
](
https://jcenter.bintray.com/
)
to download sdk
### deploy your own cluster
## 下载并设置授权文件 / Download auth file
-
注册并登陆过skywalking-webui,创建应用。(一个用户代表一个逻辑集群,一个应用代表一个服务集群。如前后端应用应该设置两个应用,但归属一个用户)
-
Sign up and login in skywalking-webui. Create application as needed.
-
下载授权文件,放在在agent jar所在目录中
-
download auth file(
*
.auth), and copy the auth file to directory of the agent jar
## 在运行时环境中设置环境变量 / set environment variables
```
export SKYWALKING_RUN=true
```
-
设置完成后,SkyWalking将随应用启动运行
-
After set env, SkyWalking will be working, when application startup.
## Download agent
[
![Download
](
https://api.bintray.com/packages/wu-sheng/skywalking/com.a.eye.skywalking-agent/images/download.svg
)
](https://bintray.com/wu-sheng/skywalking/com.a.eye.skywalking-agent/_latestVersion)
## 使用-javaagent 并启动应用程序 / start application with -javaagent
-
为应用程序添加启动参数
## start application with -javaagent
```
shell
java
-jar
...
-javaagent
:/..ospath../skywalking-agent-x.x
-Final
.jar
java
-jar
...
-javaagent
:/..ospath../skywalking-agent-x.x.jar
```
-
Tomcat可以使用修改启动文件,配置-javaagent参数
# 在应用程序中显示traceid / How to find tid
-
通过web应用的http调用入口,通过返回的header信息,找到此次调用的traceid。前提:此web应用的url,已经使用skywalking进行监控。
# Development Documents
-
[
Development Guide of Plugin
](
https://github.com/wu-sheng/sky-walking/wiki/Development-Guide-of-Plugin
)
# QA
-
[
SkyWalking SDK是否已经工作? Is SkyWalking SDK Running?
](
QA/IS_RUNNING.md
)
-
[
tid在web-ui上无法查询. tid can't be search on web-ui
](
QA/TID_CANNOT_BE_SEARCH.md
)
-
[
SkyWalking Server的运行情况. The status of SkyWalking Server
](
QA/SERVER_RUNNING_STAUTS.md
)
-
[
SkyWalking Analysis部署运行常见问题. The FAQ of SkyWalking Analysis deployment
](
QA/deploy-sw_analysis-problem.md
)
# 源代码说明
*
[
网络传输协议、缓存文件协议说明. the protocols of transform between agent and collector, collector buffer file
](
doc/protocol.md
)
# Recent RoadMap
*
[In the schedule] v2.1-2017
...
...
@@ -165,26 +130,9 @@ java -jar ... -javaagent:/..ospath../skywalking-agent-x.x-Final.jar
*
support log framework(log4j, log4j2, logback) to output traceid in system log.
*
[Dev] v2.0-2016
*
移除对于Hadoop,HBase的依赖,降低部署和运维难度
*
使用内嵌式数据库,和分布式集群
*
移除副本发送机制
*
支持数据文件的时间分片,支持集群TB级别日志文件存储
*
支持统计和高效的准实时统计汇总
*
更多插件的支持
*
not dependency on Hadoop or HBase, easy to deploy or maintenance
*
support simple-cluster mode
*
support docker mode in single-server-instance
*
support more plugins
*
motan rpc framework (provided)
*
[Release] v1.0-Final
*
客户端与服务端间使用扩展后的网络协议,前置的测试版本无法兼容,以提高服务端的稳定性和健壮性。(在内部使用过程中,发生因为安全扫描,导致服务端宕机)
*
引入javaagent模式,
<b>
无需修改任何代码
</b>
,完成监控。
*
所有插件将基于字节码技术实现,原有的配置文件模式将被移除。
*
[Release] v1.0 beta
*
修复大量前置版本的BUG
*
提供基于MR的分析能力,能够对调用链进行分析汇总,并形成调用链统计视图
*
[Release] v1.0 alpha2
*
基于v1.0-alpha1的较稳定版本,在内部环境进行数月运行,修复大量影响服务端运行稳定性的问题。
*
v1.0-beta,将提供定时分析任务,部分分析页面展现功能。
*
预计:后续版本将在插件模式上有较大改变,计划针对java api的拦截和第三方拦截提供更小侵入性的方法。配置和拦截模式会发生相应变化。具体模式,参考v1.0-beta发布时的说明。
[
More...
](
https://github.com/wu-sheng/sky-walking/releases
)
skywalking-sniffer/skywalking-agent/dependency-reduced-pom.xml
浏览文件 @
0d2ee9af
<?xml version="1.0" encoding="UTF-8"?>
<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/maven-v4_0_0.xsd"
>
<parent>
<artifactId>
skywalking-collector
</artifactId>
<groupId>
com.a.eye
</groupId>
<version>
2.0-2016
</version>
</parent>
<modelVersion>
4.0.0
</modelVersion>
<artifactId>
skywalking-agent
</artifactId>
<name>
skywalking-agent
</name>
<url>
http://maven.apache.org
</url>
<build>
<plugins>
<plugin>
<artifactId>
maven-shade-plugin
</artifactId>
<version>
2.4.1
</version>
<executions>
<execution>
<phase>
package
</phase>
<goals>
<goal>
shade
</goal>
</goals>
<configuration>
<shadedArtifactAttached>
false
</shadedArtifactAttached>
<createDependencyReducedPom>
true
</createDependencyReducedPom>
<createSourcesJar>
true
</createSourcesJar>
<shadeSourcesContent>
true
</shadeSourcesContent>
<transformers>
<transformer>
<resource>
skywalking-plugin.def
</resource>
</transformer>
<transformer>
<manifestEntries>
<Premain-Class>
${premain.class}
</Premain-Class>
</manifestEntries>
</transformer>
</transformers>
<relocations>
<relocation>
<pattern>
${shade.net.bytebuddy.source}
</pattern>
<shadedPattern>
${shade.net.bytebuddy.target}
</shadedPattern>
</relocation>
<relocation>
<pattern>
${shade.io.netty.source}
</pattern>
<shadedPattern>
${shade.io.netty.target}
</shadedPattern>
</relocation>
<relocation>
<pattern>
${shade.com.google.gson.source}
</pattern>
<shadedPattern>
${shade.com.google.gson.target}
</shadedPattern>
</relocation>
</relocations>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>
junit
</groupId>
<artifactId>
junit
</artifactId>
<version>
4.12
</version>
<scope>
test
</scope>
<exclusions>
<exclusion>
<artifactId>
hamcrest-core
</artifactId>
<groupId>
org.hamcrest
</groupId>
</exclusion>
</exclusions>
</dependency>
</dependencies>
<distributionManagement>
<repository>
<id>
bintray-wu-sheng-sky-walking-repository
</id>
<name>
wu-sheng-sky-walking-repository
</name>
<url>
https://api.bintray.com/maven/wu-sheng/skywalking/com.a.eye.skywalking-agent/;publish=1
</url>
</repository>
</distributionManagement>
<properties>
<shade.net.bytebuddy.target>
com.a.eye.skywalking.api.dependencies.net.bytebuddy
</shade.net.bytebuddy.target>
<shade.com.google.gson.source>
com.google.gson
</shade.com.google.gson.source>
<shade.com.google.gson.target>
com.a.eye.skywalking.api.dependencies.com.google.gson
</shade.com.google.gson.target>
<project.build.sourceEncoding>
UTF-8
</project.build.sourceEncoding>
<shade.io.netty.source>
io.netty
</shade.io.netty.source>
<shade.io.netty.target>
com.a.eye.skywalking.api.dependencies.io.netty
</shade.io.netty.target>
<shade.net.bytebuddy.source>
net.bytebuddy
</shade.net.bytebuddy.source>
<premain.class>
com.a.eye.skywalking.agent.SkyWalkingAgent
</premain.class>
</properties>
</project>
<?xml version="1.0" encoding="UTF-8"?>
<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/maven-v4_0_0.xsd"
>
<parent>
<artifactId>
skywalking-sniffer
</artifactId>
<groupId>
com.a.eye
</groupId>
<version>
2.0-2016
</version>
</parent>
<modelVersion>
4.0.0
</modelVersion>
<artifactId>
skywalking-agent
</artifactId>
<name>
skywalking-agent
</name>
<url>
http://maven.apache.org
</url>
<build>
<plugins>
<plugin>
<artifactId>
maven-shade-plugin
</artifactId>
<version>
2.4.1
</version>
<executions>
<execution>
<phase>
package
</phase>
<goals>
<goal>
shade
</goal>
</goals>
<configuration>
<shadedArtifactAttached>
false
</shadedArtifactAttached>
<createDependencyReducedPom>
true
</createDependencyReducedPom>
<createSourcesJar>
true
</createSourcesJar>
<shadeSourcesContent>
true
</shadeSourcesContent>
<transformers>
<transformer>
<resource>
skywalking-plugin.def
</resource>
</transformer>
<transformer>
<manifestEntries>
<Premain-Class>
${premain.class}
</Premain-Class>
</manifestEntries>
</transformer>
</transformers>
<relocations>
<relocation>
<pattern>
${shade.net.bytebuddy.source}
</pattern>
<shadedPattern>
${shade.net.bytebuddy.target}
</shadedPattern>
</relocation>
<relocation>
<pattern>
${shade.com.lmax.disruptor.source}
</pattern>
<shadedPattern>
${shade.com.lmax.disruptor.target}
</shadedPattern>
</relocation>
</relocations>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>
junit
</groupId>
<artifactId>
junit
</artifactId>
<version>
4.12
</version>
<scope>
test
</scope>
<exclusions>
<exclusion>
<artifactId>
hamcrest-core
</artifactId>
<groupId>
org.hamcrest
</groupId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>
org.mockito
</groupId>
<artifactId>
mockito-core
</artifactId>
<version>
1.10.19
</version>
<scope>
test
</scope>
<exclusions>
<exclusion>
<artifactId>
objenesis
</artifactId>
<groupId>
org.objenesis
</groupId>
</exclusion>
<exclusion>
<artifactId>
hamcrest-core
</artifactId>
<groupId>
org.hamcrest
</groupId>
</exclusion>
</exclusions>
</dependency>
</dependencies>
<distributionManagement>
<repository>
<id>
bintray-wu-sheng-sky-walking-repository
</id>
<name>
wu-sheng-sky-walking-repository
</name>
<url>
https://api.bintray.com/maven/wu-sheng/skywalking/com.a.eye.skywalking-agent/;publish=1
</url>
</repository>
</distributionManagement>
<properties>
<shade.net.bytebuddy.target>
${shade.package}.${shade.net.bytebuddy.source}}
</shade.net.bytebuddy.target>
<shade.package>
com.a.eye.skywalking.api.dependencies
</shade.package>
<project.build.sourceEncoding>
UTF-8
</project.build.sourceEncoding>
<shade.com.lmax.disruptor.source>
com.lmax.disruptor
</shade.com.lmax.disruptor.source>
<shade.com.lmax.disruptor.target>
${shade.package}.${shade.com.lmax.disruptor.source}
</shade.com.lmax.disruptor.target>
<shade.net.bytebuddy.source>
net.bytebuddy
</shade.net.bytebuddy.source>
<premain.class>
com.a.eye.skywalking.agent.SkyWalkingAgent
</premain.class>
</properties>
</project>
skywalking-sniffer/skywalking-agent/src/main/java/com/a/eye/skywalking/agent/SkyWalkingAgent.java
浏览文件 @
0d2ee9af
...
...
@@ -29,10 +29,10 @@ public class SkyWalkingAgent {
LogManager
.
setLogResolver
(
new
EasyLogResolver
());
}
private
static
ILog
easyL
ogger
;
private
static
ILog
l
ogger
;
public
static
void
premain
(
String
agentArgs
,
Instrumentation
instrumentation
)
throws
PluginException
{
easyL
ogger
=
LogManager
.
getLogger
(
SkyWalkingAgent
.
class
);
l
ogger
=
LogManager
.
getLogger
(
SkyWalkingAgent
.
class
);
initConfig
();
final
PluginDefineCategory
pluginDefineCategory
=
PluginDefineCategory
.
category
(
new
PluginBootstrap
().
loadPlugins
());
...
...
@@ -54,7 +54,7 @@ public class SkyWalkingAgent {
@Override
public
void
onError
(
String
typeName
,
ClassLoader
classLoader
,
JavaModule
module
,
Throwable
throwable
)
{
easyL
ogger
.
error
(
"Failed to enhance class "
+
typeName
,
throwable
);
l
ogger
.
error
(
"Failed to enhance class "
+
typeName
,
throwable
);
}
@Override
...
...
@@ -86,7 +86,7 @@ public class SkyWalkingAgent {
urlString
=
urlString
.
substring
(
urlString
.
indexOf
(
"file:"
),
urlString
.
indexOf
(
'!'
));
return
new
File
(
new
URL
(
urlString
).
getFile
()).
getParentFile
().
getAbsolutePath
();
}
catch
(
Exception
e
)
{
easyL
ogger
.
error
(
"Failed to init config ."
,
e
);
l
ogger
.
error
(
"Failed to init config ."
,
e
);
return
""
;
}
}
...
...
skywalking-sniffer/skywalking-api/pom.xml
浏览文件 @
0d2ee9af
...
...
@@ -26,7 +26,6 @@
<artifactId>
byte-buddy
</artifactId>
<version>
1.5.7
</version>
</dependency>
<dependency>
<groupId>
com.a.eye
</groupId>
<artifactId>
skywalking-network
</artifactId>
...
...
@@ -37,11 +36,6 @@
<artifactId>
disruptor
</artifactId>
<version>
3.3.6
</version>
</dependency>
<dependency>
<groupId>
com.a.eye
</groupId>
<artifactId>
skywalking-registry
</artifactId>
<version>
${project.parent.version}
</version>
</dependency>
<dependency>
<groupId>
com.a.eye
</groupId>
<artifactId>
skywalking-health-report
</artifactId>
...
...
skywalking-sniffer/skywalking-api/src/main/java/com/a/eye/skywalking/conf/Config.java
浏览文件 @
0d2ee9af
...
...
@@ -11,6 +11,8 @@ public class Config {
public
static
String
AGENT_BASE_PATH
=
""
;
public
static
String
SERVERS
=
""
;
}
public
static
class
Disruptor
{
...
...
skywalking-sniffer/skywalking-api/src/main/java/com/a/eye/skywalking/conf/ConfigInitializer.java
浏览文件 @
0d2ee9af
...
...
@@ -25,6 +25,7 @@ public class ConfigInitializer {
Config
.
SkyWalking
.
USER_ID
=
System
.
getProperty
(
"userId"
);
Config
.
SkyWalking
.
APPLICATION_CODE
=
System
.
getProperty
(
"applicationCode"
);
Config
.
SkyWalking
.
SERVERS
=
System
.
getProperty
(
"server"
);
if
(
configFileStream
==
null
)
{
logger
.
info
(
"Not provide sky-walking certification documents, sky-walking api run in default config."
);
...
...
@@ -39,7 +40,13 @@ public class ConfigInitializer {
}
if
(
StringUtil
.
isEmpty
(
Config
.
SkyWalking
.
USER_ID
)){
throw
new
ExceptionInInitializerError
(
"'-DuserId=' is missing."
);
}
if
(
StringUtil
.
isEmpty
(
Config
.
SkyWalking
.
APPLICATION_CODE
)){
throw
new
ExceptionInInitializerError
(
"'-DapplicationCode=' is missing."
);
}
if
(
StringUtil
.
isEmpty
(
Config
.
SkyWalking
.
SERVERS
)){
throw
new
ExceptionInInitializerError
(
"'-Dserver=' is missing."
);
}
}
...
...
skywalking-sniffer/skywalking-api/src/main/java/com/a/eye/skywalking/disruptor/ack/SendAckSpanEventHandler.java
浏览文件 @
0d2ee9af
...
...
@@ -27,6 +27,7 @@ public class SendAckSpanEventHandler implements EventHandler<AckSpanHolder> {
if
(
endOfBatch
||
buffer
.
size
()
==
bufferSize
)
{
try
{
//TODO, use GRPC to send
HealthCollector
.
getCurrentHeathReading
(
"SendAckSpanEventHandler"
).
updateData
(
HeathReading
.
INFO
,
"%s messages were successful consumed ."
,
buffer
.
size
());
}
finally
{
...
...
skywalking-sniffer/skywalking-api/src/main/java/com/a/eye/skywalking/disruptor/request/SendRequestSpanEventHandler.java
浏览文件 @
0d2ee9af
...
...
@@ -27,7 +27,7 @@ public class SendRequestSpanEventHandler implements EventHandler<RequestSpanHold
if
(
endOfBatch
||
buffer
.
size
()
==
bufferSize
)
{
try
{
//TODO, use GRPC to send
HealthCollector
.
getCurrentHeathReading
(
"SendRequestSpanEventHandler"
).
updateData
(
HeathReading
.
INFO
,
"%s messages were successful consumed ."
,
buffer
.
size
());
}
finally
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录