Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
山不在高_有仙则灵
SkyWalking
提交
79cddf65
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,发现更多精彩内容 >>
提交
79cddf65
编写于
1月 13, 2018
作者:
P
peng-yongsheng
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Changed boolean type to integer, true: 1, false: 0.
上级
cbcb592c
变更
13
显示空白变更内容
内联
并排
Showing
13 changed file
with
32 addition
and
38 deletion
+32
-38
apm-collector/apm-collector-analysis/analysis-jvm/jvm-provider/src/main/java/org/apache/skywalking/apm/collector/analysis/jvm/provider/service/MemoryMetricService.java
...or/analysis/jvm/provider/service/MemoryMetricService.java
+2
-1
apm-collector/apm-collector-analysis/analysis-register/register-provider/src/main/java/org/apache/skywalking/apm/collector/analysis/register/provider/register/ApplicationRegisterSerialWorker.java
...er/provider/register/ApplicationRegisterSerialWorker.java
+2
-1
apm-collector/apm-collector-analysis/analysis-register/register-provider/src/main/java/org/apache/skywalking/apm/collector/analysis/register/provider/register/InstanceRegisterSerialWorker.java
...ister/provider/register/InstanceRegisterSerialWorker.java
+2
-1
apm-collector/apm-collector-analysis/analysis-register/register-provider/src/main/java/org/apache/skywalking/apm/collector/analysis/register/provider/service/ApplicationIDService.java
...lysis/register/provider/service/ApplicationIDService.java
+3
-6
apm-collector/apm-collector-analysis/analysis-register/register-provider/src/main/java/org/apache/skywalking/apm/collector/analysis/register/provider/service/InstanceIDService.java
...analysis/register/provider/service/InstanceIDService.java
+3
-2
apm-collector/apm-collector-boot/src/main/resources/application.yml
...tor/apm-collector-boot/src/main/resources/application.yml
+4
-4
apm-collector/apm-collector-storage/collector-storage-define/src/main/java/org/apache/skywalking/apm/collector/storage/table/jvm/MemoryMetric.java
...walking/apm/collector/storage/table/jvm/MemoryMetric.java
+4
-5
apm-collector/apm-collector-storage/collector-storage-define/src/main/java/org/apache/skywalking/apm/collector/storage/table/register/Application.java
...ing/apm/collector/storage/table/register/Application.java
+4
-5
apm-collector/apm-collector-storage/collector-storage-define/src/main/java/org/apache/skywalking/apm/collector/storage/table/register/Instance.java
...alking/apm/collector/storage/table/register/Instance.java
+4
-5
apm-collector/apm-collector-storage/collector-storage-es-provider/src/main/java/org/apache/skywalking/apm/collector/storage/es/dao/cache/InstanceEsCacheDAO.java
...pm/collector/storage/es/dao/cache/InstanceEsCacheDAO.java
+0
-4
apm-collector/apm-collector-storage/collector-storage-es-provider/src/main/java/org/apache/skywalking/apm/collector/storage/es/dao/cache/NetworkAddressEsCacheDAO.java
...lector/storage/es/dao/cache/NetworkAddressEsCacheDAO.java
+1
-1
apm-collector/apm-collector-storage/collector-storage-es-provider/src/main/java/org/apache/skywalking/apm/collector/storage/es/dao/memorymp/AbstractMemoryMetricEsPersistenceDAO.java
...es/dao/memorymp/AbstractMemoryMetricEsPersistenceDAO.java
+1
-1
apm-collector/apm-collector-storage/collector-storage-h2-provider/src/main/java/org/apache/skywalking/apm/collector/storage/h2/dao/memorymp/AbstractMemoryMetricH2PersistenceDAO.java
...h2/dao/memorymp/AbstractMemoryMetricH2PersistenceDAO.java
+2
-2
未找到文件。
apm-collector/apm-collector-analysis/analysis-jvm/jvm-provider/src/main/java/org/apache/skywalking/apm/collector/analysis/jvm/provider/service/MemoryMetricService.java
浏览文件 @
79cddf65
...
...
@@ -22,6 +22,7 @@ import org.apache.skywalking.apm.collector.analysis.jvm.define.graph.GraphIdDefi
import
org.apache.skywalking.apm.collector.analysis.jvm.define.service.IMemoryMetricService
;
import
org.apache.skywalking.apm.collector.core.graph.Graph
;
import
org.apache.skywalking.apm.collector.core.graph.GraphManager
;
import
org.apache.skywalking.apm.collector.core.util.BooleanUtils
;
import
org.apache.skywalking.apm.collector.core.util.Const
;
import
org.apache.skywalking.apm.collector.core.util.ObjectUtils
;
import
org.apache.skywalking.apm.collector.storage.table.jvm.MemoryMetric
;
...
...
@@ -53,7 +54,7 @@ public class MemoryMetricService implements IMemoryMetricService {
memoryMetric
.
setId
(
id
);
memoryMetric
.
setMetricId
(
metricId
);
memoryMetric
.
setInstanceId
(
instanceId
);
memoryMetric
.
setIsHeap
(
isHeap
);
memoryMetric
.
setIsHeap
(
BooleanUtils
.
booleanToValue
(
isHeap
)
);
memoryMetric
.
setInit
(
init
);
memoryMetric
.
setMax
(
max
);
memoryMetric
.
setUsed
(
used
);
...
...
apm-collector/apm-collector-analysis/analysis-register/register-provider/src/main/java/org/apache/skywalking/apm/collector/analysis/register/provider/register/ApplicationRegisterSerialWorker.java
浏览文件 @
79cddf65
...
...
@@ -25,6 +25,7 @@ import org.apache.skywalking.apm.collector.analysis.worker.model.base.WorkerExce
import
org.apache.skywalking.apm.collector.cache.CacheModule
;
import
org.apache.skywalking.apm.collector.cache.service.ApplicationCacheService
;
import
org.apache.skywalking.apm.collector.core.module.ModuleManager
;
import
org.apache.skywalking.apm.collector.core.util.BooleanUtils
;
import
org.apache.skywalking.apm.collector.core.util.Const
;
import
org.apache.skywalking.apm.collector.storage.StorageModule
;
import
org.apache.skywalking.apm.collector.storage.dao.register.IApplicationRegisterDAO
;
...
...
@@ -65,7 +66,7 @@ public class ApplicationRegisterSerialWorker extends AbstractLocalAsyncWorker<Ap
userApplication
.
setApplicationCode
(
Const
.
USER_CODE
);
userApplication
.
setApplicationId
(
Const
.
NONE_APPLICATION_ID
);
userApplication
.
setAddressId
(
Const
.
NONE
);
userApplication
.
setIsAddress
(
false
);
userApplication
.
setIsAddress
(
BooleanUtils
.
FALSE
);
applicationRegisterDAO
.
save
(
userApplication
);
newApplication
=
new
Application
();
...
...
apm-collector/apm-collector-analysis/analysis-register/register-provider/src/main/java/org/apache/skywalking/apm/collector/analysis/register/provider/register/InstanceRegisterSerialWorker.java
浏览文件 @
79cddf65
...
...
@@ -25,6 +25,7 @@ import org.apache.skywalking.apm.collector.analysis.worker.model.base.WorkerExce
import
org.apache.skywalking.apm.collector.cache.CacheModule
;
import
org.apache.skywalking.apm.collector.cache.service.InstanceCacheService
;
import
org.apache.skywalking.apm.collector.core.module.ModuleManager
;
import
org.apache.skywalking.apm.collector.core.util.BooleanUtils
;
import
org.apache.skywalking.apm.collector.core.util.Const
;
import
org.apache.skywalking.apm.collector.storage.StorageModule
;
import
org.apache.skywalking.apm.collector.storage.dao.register.IInstanceRegisterDAO
;
...
...
@@ -70,7 +71,7 @@ public class InstanceRegisterSerialWorker extends AbstractLocalAsyncWorker<Insta
userInstance
.
setOsInfo
(
Const
.
EMPTY_STRING
);
userInstance
.
setRegisterTime
(
System
.
currentTimeMillis
());
userInstance
.
setAddressId
(
Const
.
NONE
);
userInstance
.
setIsAddress
(
false
);
userInstance
.
setIsAddress
(
BooleanUtils
.
FALSE
);
instanceRegisterDAO
.
save
(
userInstance
);
newInstance
=
new
Instance
();
...
...
apm-collector/apm-collector-analysis/analysis-register/register-provider/src/main/java/org/apache/skywalking/apm/collector/analysis/register/provider/service/ApplicationIDService.java
浏览文件 @
79cddf65
...
...
@@ -26,19 +26,16 @@ import org.apache.skywalking.apm.collector.cache.service.NetworkAddressCacheServ
import
org.apache.skywalking.apm.collector.core.graph.Graph
;
import
org.apache.skywalking.apm.collector.core.graph.GraphManager
;
import
org.apache.skywalking.apm.collector.core.module.ModuleManager
;
import
org.apache.skywalking.apm.collector.core.util.BooleanUtils
;
import
org.apache.skywalking.apm.collector.core.util.Const
;
import
org.apache.skywalking.apm.collector.core.util.ObjectUtils
;
import
org.apache.skywalking.apm.collector.storage.table.register.Application
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
/**
* @author peng-yongsheng
*/
public
class
ApplicationIDService
implements
IApplicationIDService
{
private
final
Logger
logger
=
LoggerFactory
.
getLogger
(
ApplicationIDService
.
class
);
private
final
ModuleManager
moduleManager
;
private
ApplicationCacheService
applicationCacheService
;
private
NetworkAddressCacheService
networkAddressCacheService
;
...
...
@@ -78,7 +75,7 @@ public class ApplicationIDService implements IApplicationIDService {
application
.
setApplicationCode
(
applicationCode
);
application
.
setApplicationId
(
0
);
application
.
setAddressId
(
Const
.
NONE
);
application
.
setIsAddress
(
false
);
application
.
setIsAddress
(
BooleanUtils
.
FALSE
);
getApplicationRegisterGraph
().
start
(
application
);
}
...
...
@@ -94,7 +91,7 @@ public class ApplicationIDService implements IApplicationIDService {
application
.
setApplicationCode
(
networkAddress
);
application
.
setApplicationId
(
0
);
application
.
setAddressId
(
addressId
);
application
.
setIsAddress
(
true
);
application
.
setIsAddress
(
BooleanUtils
.
TRUE
);
getApplicationRegisterGraph
().
start
(
application
);
}
...
...
apm-collector/apm-collector-analysis/analysis-register/register-provider/src/main/java/org/apache/skywalking/apm/collector/analysis/register/provider/service/InstanceIDService.java
浏览文件 @
79cddf65
...
...
@@ -25,6 +25,7 @@ import org.apache.skywalking.apm.collector.cache.service.InstanceCacheService;
import
org.apache.skywalking.apm.collector.core.graph.Graph
;
import
org.apache.skywalking.apm.collector.core.graph.GraphManager
;
import
org.apache.skywalking.apm.collector.core.module.ModuleManager
;
import
org.apache.skywalking.apm.collector.core.util.BooleanUtils
;
import
org.apache.skywalking.apm.collector.core.util.Const
;
import
org.apache.skywalking.apm.collector.core.util.ObjectUtils
;
import
org.apache.skywalking.apm.collector.storage.StorageModule
;
...
...
@@ -83,7 +84,7 @@ public class InstanceIDService implements IInstanceIDService {
instance
.
setHeartBeatTime
(
registerTime
);
instance
.
setInstanceId
(
0
);
instance
.
setOsInfo
(
osInfo
);
instance
.
setIsAddress
(
false
);
instance
.
setIsAddress
(
BooleanUtils
.
FALSE
);
instance
.
setAddressId
(
Const
.
NONE
);
getInstanceRegisterGraph
().
start
(
instance
);
...
...
@@ -104,7 +105,7 @@ public class InstanceIDService implements IInstanceIDService {
instance
.
setHeartBeatTime
(
registerTime
);
instance
.
setInstanceId
(
0
);
instance
.
setOsInfo
(
Const
.
EMPTY_STRING
);
instance
.
setIsAddress
(
true
);
instance
.
setIsAddress
(
BooleanUtils
.
TRUE
);
instance
.
setAddressId
(
addressId
);
getInstanceRegisterGraph
().
start
(
instance
);
...
...
apm-collector/apm-collector-boot/src/main/resources/application.yml
浏览文件 @
79cddf65
...
...
@@ -42,10 +42,10 @@ ui:
# index_shards_number: 2
# index_replicas_number: 0
# ttl: 7
#
storage:
#
h2:
#
url: jdbc:h2:tcp://localhost/~/test
#
user_name: sa
storage
:
h2
:
url
:
jdbc:h2:tcp://localhost/~/test
user_name
:
sa
configuration
:
default
:
application_apdex_threshold
:
2000
...
...
apm-collector/apm-collector-storage/collector-storage-define/src/main/java/org/apache/skywalking/apm/collector/storage/table/jvm/MemoryMetric.java
浏览文件 @
79cddf65
...
...
@@ -25,7 +25,6 @@ import org.apache.skywalking.apm.collector.core.data.operator.CoverOperation;
import
org.apache.skywalking.apm.collector.core.data.operator.MaxOperation
;
import
org.apache.skywalking.apm.collector.core.data.operator.MinOperation
;
import
org.apache.skywalking.apm.collector.core.data.operator.NonOperation
;
import
org.apache.skywalking.apm.collector.core.util.BooleanUtils
;
/**
* @author peng-yongsheng
...
...
@@ -132,11 +131,11 @@ public class MemoryMetric extends StreamData {
setDataInteger
(
0
,
instanceId
);
}
public
Boolean
getIsHeap
()
{
return
BooleanUtils
.
valueToBoolean
(
getDataInteger
(
1
)
);
public
Integer
getIsHeap
()
{
return
getDataInteger
(
1
);
}
public
void
setIsHeap
(
Boolean
isHeap
)
{
setDataInteger
(
1
,
BooleanUtils
.
booleanToValue
(
isHeap
)
);
public
void
setIsHeap
(
Integer
isHeap
)
{
setDataInteger
(
1
,
isHeap
);
}
}
apm-collector/apm-collector-storage/collector-storage-define/src/main/java/org/apache/skywalking/apm/collector/storage/table/register/Application.java
浏览文件 @
79cddf65
...
...
@@ -22,7 +22,6 @@ import org.apache.skywalking.apm.collector.core.data.Column;
import
org.apache.skywalking.apm.collector.core.data.StreamData
;
import
org.apache.skywalking.apm.collector.core.data.operator.CoverOperation
;
import
org.apache.skywalking.apm.collector.core.data.operator.NonOperation
;
import
org.apache.skywalking.apm.collector.core.util.BooleanUtils
;
/**
* @author peng-yongsheng
...
...
@@ -90,11 +89,11 @@ public class Application extends StreamData {
setDataInteger
(
1
,
addressId
);
}
public
boolean
getIsAddress
()
{
return
BooleanUtils
.
valueToBoolean
(
getDataInteger
(
2
)
);
public
int
getIsAddress
()
{
return
getDataInteger
(
2
);
}
public
void
setIsAddress
(
boolean
isAddress
)
{
setDataInteger
(
2
,
BooleanUtils
.
booleanToValue
(
isAddress
)
);
public
void
setIsAddress
(
int
isAddress
)
{
setDataInteger
(
2
,
isAddress
);
}
}
apm-collector/apm-collector-storage/collector-storage-define/src/main/java/org/apache/skywalking/apm/collector/storage/table/register/Instance.java
浏览文件 @
79cddf65
...
...
@@ -22,7 +22,6 @@ import org.apache.skywalking.apm.collector.core.data.Column;
import
org.apache.skywalking.apm.collector.core.data.StreamData
;
import
org.apache.skywalking.apm.collector.core.data.operator.CoverOperation
;
import
org.apache.skywalking.apm.collector.core.data.operator.NonOperation
;
import
org.apache.skywalking.apm.collector.core.util.BooleanUtils
;
/**
* @author peng-yongsheng
...
...
@@ -127,11 +126,11 @@ public class Instance extends StreamData {
setDataInteger
(
2
,
addressId
);
}
public
boolean
getIsAddress
()
{
return
BooleanUtils
.
valueToBoolean
(
getDataInteger
(
3
)
);
public
int
getIsAddress
()
{
return
getDataInteger
(
3
);
}
public
void
setIsAddress
(
boolean
isAddress
)
{
setDataInteger
(
3
,
BooleanUtils
.
booleanToValue
(
isAddress
)
);
public
void
setIsAddress
(
int
isAddress
)
{
setDataInteger
(
3
,
isAddress
);
}
}
apm-collector/apm-collector-storage/collector-storage-es-provider/src/main/java/org/apache/skywalking/apm/collector/storage/es/dao/cache/InstanceEsCacheDAO.java
浏览文件 @
79cddf65
...
...
@@ -30,16 +30,12 @@ import org.elasticsearch.action.search.SearchType;
import
org.elasticsearch.index.query.BoolQueryBuilder
;
import
org.elasticsearch.index.query.QueryBuilders
;
import
org.elasticsearch.search.SearchHit
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
/**
* @author peng-yongsheng
*/
public
class
InstanceEsCacheDAO
extends
EsDAO
implements
IInstanceCacheDAO
{
private
final
Logger
logger
=
LoggerFactory
.
getLogger
(
InstanceEsCacheDAO
.
class
);
public
InstanceEsCacheDAO
(
ElasticSearchClient
client
)
{
super
(
client
);
}
...
...
apm-collector/apm-collector-storage/collector-storage-es-provider/src/main/java/org/apache/skywalking/apm/collector/storage/es/dao/cache/NetworkAddressEsCacheDAO.java
浏览文件 @
79cddf65
...
...
@@ -48,7 +48,7 @@ public class NetworkAddressEsCacheDAO extends EsDAO implements INetworkAddressCa
ElasticSearchClient
client
=
getClient
();
SearchRequestBuilder
searchRequestBuilder
=
client
.
prepareSearch
(
NetworkAddressTable
.
TABLE
);
searchRequestBuilder
.
setTypes
(
"type"
);
searchRequestBuilder
.
setTypes
(
NetworkAddressTable
.
TABLE_TYPE
);
searchRequestBuilder
.
setSearchType
(
SearchType
.
QUERY_THEN_FETCH
);
searchRequestBuilder
.
setQuery
(
QueryBuilders
.
termQuery
(
NetworkAddressTable
.
COLUMN_NETWORK_ADDRESS
,
networkAddress
));
searchRequestBuilder
.
setSize
(
1
);
...
...
apm-collector/apm-collector-storage/collector-storage-es-provider/src/main/java/org/apache/skywalking/apm/collector/storage/es/dao/memorymp/AbstractMemoryMetricEsPersistenceDAO.java
浏览文件 @
79cddf65
...
...
@@ -44,7 +44,7 @@ public abstract class AbstractMemoryMetricEsPersistenceDAO extends AbstractPersi
memoryMetric
.
setMetricId
((
String
)
source
.
get
(
MemoryMetricTable
.
COLUMN_METRIC_ID
));
memoryMetric
.
setInstanceId
(((
Number
)
source
.
get
(
MemoryMetricTable
.
COLUMN_INSTANCE_ID
)).
intValue
());
memoryMetric
.
setIsHeap
((
Boolean
)
source
.
get
(
MemoryMetricTable
.
COLUMN_IS_HEAP
));
memoryMetric
.
setIsHeap
((
(
Number
)
source
.
get
(
MemoryMetricTable
.
COLUMN_IS_HEAP
)).
intValue
(
));
memoryMetric
.
setInit
(((
Number
)
source
.
get
(
MemoryMetricTable
.
COLUMN_INIT
)).
longValue
());
memoryMetric
.
setMax
(((
Number
)
source
.
get
(
MemoryMetricTable
.
COLUMN_MAX
)).
longValue
());
...
...
apm-collector/apm-collector-storage/collector-storage-h2-provider/src/main/java/org/apache/skywalking/apm/collector/storage/h2/dao/memorymp/AbstractMemoryMetricH2PersistenceDAO.java
浏览文件 @
79cddf65
...
...
@@ -28,7 +28,7 @@ import org.apache.skywalking.apm.collector.storage.table.jvm.MemoryMetric;
import
org.apache.skywalking.apm.collector.storage.table.jvm.MemoryMetricTable
;
/**
* @author peng-yongsheng
, clevertension
* @author peng-yongsheng
*/
public
abstract
class
AbstractMemoryMetricH2PersistenceDAO
extends
AbstractPersistenceH2DAO
<
MemoryMetric
>
{
...
...
@@ -42,7 +42,7 @@ public abstract class AbstractMemoryMetricH2PersistenceDAO extends AbstractPersi
memoryMetric
.
setMetricId
(
resultSet
.
getString
(
MemoryMetricTable
.
COLUMN_METRIC_ID
));
memoryMetric
.
setInstanceId
(
resultSet
.
getInt
(
MemoryMetricTable
.
COLUMN_INSTANCE_ID
));
memoryMetric
.
setIsHeap
(
resultSet
.
get
Boolean
(
MemoryMetricTable
.
COLUMN_IS_HEAP
));
memoryMetric
.
setIsHeap
(
resultSet
.
get
Int
(
MemoryMetricTable
.
COLUMN_IS_HEAP
));
memoryMetric
.
setInit
(
resultSet
.
getLong
(
MemoryMetricTable
.
COLUMN_INIT
));
memoryMetric
.
setMax
(
resultSet
.
getLong
(
MemoryMetricTable
.
COLUMN_MAX
));
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录