Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
山不在高_有仙则灵
SkyWalking
提交
66bd78cf
S
SkyWalking
项目概览
山不在高_有仙则灵
/
SkyWalking
与 Fork 源项目一致
Fork自
apache / SkyWalking
通知
12
Star
0
Fork
2
代码
文件
提交
分支
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,发现更多精彩内容 >>
提交
66bd78cf
编写于
1月 24, 2016
作者:
wu-sheng
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
1.修复一批方法名,明确方法逻辑。
上级
fc10691f
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
11 addition
and
13 deletion
+11
-13
skywalking-analysis/src/main/java/com/ai/cloud/skywalking/analysis/categorize2chain/ChainSpecificTimeWindowSummary.java
...ysis/categorize2chain/ChainSpecificTimeWindowSummary.java
+1
-1
skywalking-analysis/src/main/java/com/ai/cloud/skywalking/analysis/categorize2chain/ChainSummary.java
...ud/skywalking/analysis/categorize2chain/ChainSummary.java
+9
-11
skywalking-analysis/src/main/java/com/ai/cloud/skywalking/analysis/categorize2chain/DBCallChainInfoDao.java
...walking/analysis/categorize2chain/DBCallChainInfoDao.java
+1
-1
未找到文件。
skywalking-analysis/src/main/java/com/ai/cloud/skywalking/analysis/categorize2chain/ChainSpecificTimeWindowSummary.java
浏览文件 @
66bd78cf
...
...
@@ -39,7 +39,7 @@ public class ChainSpecificTimeWindowSummary {
chainNodeSummaryResultMap
.
put
(
chainNodeSummaryResult
.
getTraceLevelId
(),
chainNodeSummaryResult
);
}
public
void
summary
Result
(
ChainNode
node
)
{
public
void
summary
NodeValue
(
ChainNode
node
)
{
String
tlid
=
node
.
getTraceLevelId
();
ChainNodeSpecificTimeWindowSummary
chainNodeSummaryResult
=
chainNodeSummaryResultMap
.
get
(
tlid
);
if
(
chainNodeSummaryResult
==
null
)
{
...
...
skywalking-analysis/src/main/java/com/ai/cloud/skywalking/analysis/categorize2chain/ChainSummary.java
浏览文件 @
66bd78cf
...
...
@@ -14,24 +14,22 @@ import java.util.Date;
public
class
ChainSummary
{
private
Map
<
String
,
ChainSpecificTimeWindowSummary
>
summaryResultMap
;
private
Map
<
String
,
ChainSpecificTimeWindowSummary
>
loadedChainSpecificTimeWindowSummary
;
private
Map
<
String
,
Timestamp
>
updateChainInfo
;
public
ChainSummary
()
{
summaryResultMap
=
new
HashMap
<
String
,
ChainSpecificTimeWindowSummary
>();
loadedChainSpecificTimeWindowSummary
=
new
HashMap
<
String
,
ChainSpecificTimeWindowSummary
>();
updateChainInfo
=
new
HashMap
<
String
,
Timestamp
>();
}
public
void
summary
(
ChainInfo
chainInfo
)
{
for
(
ChainNode
node
:
chainInfo
.
getNodes
())
{
String
csk
=
generateChainSummaryKey
(
chainInfo
.
getCID
(),
node
.
getStartDate
());
ChainSpecificTimeWindowSummary
chainSummaryResult
=
summaryResultMap
.
get
(
csk
);
if
(
chainSummaryResult
==
null
)
{
chainSummaryResult
=
ChainSpecificTimeWindowSummary
.
load
(
csk
);
summaryResultMap
.
put
(
csk
,
chainSummaryResult
);
if
(
loadedChainSpecificTimeWindowSummary
.
containsKey
(
csk
))
{
loadedChainSpecificTimeWindowSummary
.
put
(
csk
,
ChainSpecificTimeWindowSummary
.
load
(
csk
));
}
summaryResultMap
.
get
(
csk
).
summaryResult
(
node
);
loadedChainSpecificTimeWindowSummary
.
get
(
csk
).
summaryNodeValue
(
node
);
}
updateChainInfo
.
put
(
chainInfo
.
getCID
(),
new
Timestamp
(
System
.
currentTimeMillis
()));
...
...
@@ -44,16 +42,16 @@ public class ChainSummary {
public
void
save
()
throws
IOException
,
InterruptedException
,
SQLException
{
batchSaveChainSpecificTimeWindowSummary
();
batchUpdateChainDetail
();
updateChainLastActiveTime
();
}
private
void
batchUpdateChainDetail
()
throws
SQLException
{
DBCallChainInfoDao
.
updateChain
Detail
(
updateChainInfo
);
private
void
updateChainLastActiveTime
()
throws
SQLException
{
DBCallChainInfoDao
.
updateChain
LastActiveTime
(
updateChainInfo
);
}
private
void
batchSaveChainSpecificTimeWindowSummary
()
throws
IOException
,
InterruptedException
{
List
<
Put
>
puts
=
new
ArrayList
<
Put
>();
for
(
Map
.
Entry
<
String
,
ChainSpecificTimeWindowSummary
>
entry
:
summaryResultMap
.
entrySet
())
{
for
(
Map
.
Entry
<
String
,
ChainSpecificTimeWindowSummary
>
entry
:
loadedChainSpecificTimeWindowSummary
.
entrySet
())
{
Put
put
=
new
Put
(
entry
.
getKey
().
getBytes
());
entry
.
getValue
().
save
(
put
);
puts
.
add
(
put
);
...
...
skywalking-analysis/src/main/java/com/ai/cloud/skywalking/analysis/categorize2chain/DBCallChainInfoDao.java
浏览文件 @
66bd78cf
...
...
@@ -61,7 +61,7 @@ public class DBCallChainInfoDao {
connection
.
commit
();
}
public
synchronized
static
void
updateChain
Detail
(
Map
<
String
,
Timestamp
>
updateChainInfo
)
public
synchronized
static
void
updateChain
LastActiveTime
(
Map
<
String
,
Timestamp
>
updateChainInfo
)
throws
SQLException
{
PreparedStatement
preparedStatement
=
null
;
try
{
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录