Skip to content

Commit ff142f9

Browse files
author
gyl-coder
committed
调整文档格式
1 parent 41d8679 commit ff142f9

File tree

10 files changed

+1
-110
lines changed

10 files changed

+1
-110
lines changed

docs/phoenix-2.x/phoenix-admin/function.md

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -40,57 +40,35 @@ phoniex-admin是配合phoenix框架使用的服务监控平台,能够实现对
4040
- 打快照
4141
- 删除快照
4242
- 聚合根内存查询
43-
4443
## grafana监控
45-
4644
### 概述
4745

4846
grafana是一款美观、强大的可视化监控指标展示工具,phoenix借住了grafana+elasticsearch来实现监控功能。
49-
5047
phoenix服务在消息内部埋有诸多监控指标,通过phoenix自带的phoenix-persist,将这些消息写入到elasticsearch中,通过配置elasticsearch作为数据源,并进行相关配置,我们可以就在grafana中看到我们关心的各种指标。
5148

5249
### 默认面板
5350

5451
phoenix-admin为每个项目内置了一个通用的监控面板,提供基本的监控功能,详情如下:
5552

5653
1. 总览
57-
5854
![image-20200115192350535](../../assets/phoenix2.x/phoenix-admin/image-20200115192350535.png)
59-
6055
2. 筛选栏
61-
6256
可选定系统中,不同的服务集群,和服务集群下面不同的节点的数据
63-
6457
![image-20200115111102393](../../assets/phoenix2.x/phoenix-admin/image-20200115111102393.png)
65-
6658
3. 消息个数统计面板
67-
6859
统计系统内各个消息的个数
69-
7060
![image-20200115111030625](../../assets/phoenix2.x/phoenix-admin/image-20200115111030625.png)
71-
7261
4. 指标个数统计面板
73-
7462
统计系统内具体埋点的数量
75-
7663
![image-20200115110949004](../../assets/phoenix2.x/phoenix-admin/image-20200115110949004.png)
77-
7864
5. 耗时统计面板
79-
8065
统计系统内各种耗时
81-
8266
![image-20200115111135147](../../assets/phoenix2.x/phoenix-admin/image-20200115111135147.png)
83-
8467
6. 速率统计面板
85-
8668
统计系统内各种速率
87-
8869
![image-20200115111155570](../../assets/phoenix2.x/phoenix-admin/image-20200115111155570.png)
89-
9070
7. 数据总览面板
91-
9271
展示数据的详细信息
93-
9472
![image-20200115111217069](../../assets/phoenix2.x/phoenix-admin/image-20200115111217069.png)
9573

9674
### 自定义面板 

docs/phoenix-2.x/phoenix-lite/api.md

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@ public enum RetCode {
3838
}
3939
```
4040

41-
4241
**Client端 rpc 调用返回值** `RpcResult`
4342

4443
```java
@@ -72,8 +71,6 @@ public enum RpcResultCode {
7271

7372
}
7473
```
75-
76-
7774
## 客户端 API
7875

7976
```
@@ -102,11 +99,8 @@ public enum RpcResultCode {
10299
| requestId | string | 必填 | 请求ID (预留字段) |
103100
| timeoutMs | long | 必填 | 超时时间 |
104101

105-
106102
## 服务端 API
107-
108103
### 注解
109-
110104
#### @EntityAggregateAnnotation
111105

112106
这个注释是为了找到聚合根类,为spring ioc注入存储库。 使用 `aggregateRootType` 标识该聚合根的类型
@@ -132,7 +126,6 @@ public class BankAccountAggregate implements Serializable {
132126

133127
该注解一般用于 `act` 方法,aggregateId用于标识事件中的属性,该属性将提供查找Saga实例的值。通常,此值是特定saga监视的聚合的聚合标识符。
134128

135-
136129
```java
137130
@AggregateIdAnnotation(aggregateId = "accountCode")
138131
public ActReturn act(MockCmd cmd) {

docs/phoenix-2.x/phoenix-lite/concept.md

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -8,101 +8,82 @@ title: 基本概念
88
### 消息 msg
99

1010
定义:
11-
1211
- phoenix 中,消息用于服务跟服务之间的通讯
13-
1412
相关概念:
15-
1613
* 消息的ID,全局唯一
1714

1815
### 命令 cmd
1916

2017
定义:
21-
2218
- 请求,未发生
23-
2419
相关概念:
25-
2620
- 命令Id cmdId
2721

2822
### 事件 event
2923

3024
定义:
31-
3225
- 事实,已发生
3326

34-
3527
## 聚合根相关
3628

3729
### 聚合根类别 aggregateRootType
3830

3931
定义:
40-
4132
* phoenix中,每个聚合根类会有一个聚合根类别,用于区分不同的聚合根类,全局唯一
4233
* 长度不超过32字节
4334

4435
### 聚合根ID aggregateRootId
4536

4637
定义:
47-
4838
* 聚合根类的唯一标识,在同一个聚合根类别下唯一
4939
* 长度不超过64字节
5040

51-
5241
## EventSourcing相关
5342

5443
### 事件存储 EeventStore ES
5544

5645
定义:
57-
5846
- 存储领域事件
5947

6048
### 事件回溯 EventSourcing ES
6149

6250
定义:
63-
6451
- 通过领域事件重建聚合
6552

6653
### 快照 Snapshot
6754

6855
定义:
69-
7056
- 快照用于加速事件回溯速度
7157

7258
## 服务相关
7359

7460
### 服务名 applicationName
7561

7662
定义:
77-
7863
- phoenix是一套微服务框架,applicationName为每个服务的名字,全局唯一
7964

8065
## mq相关
8166

8267
### 订阅主题 subscribeTopic
8368

8469
定义:
85-
8670
- 服务采用MQ对外通讯时, 订阅主题为服务用于接收消息的topic名字
8771

8872
## 路由相关
8973

9074
### 服务地址
9175

9276
定义:
93-
9477
- 服务采用mq通讯对外通讯时,采用服务接收的topic名字
9578

9679
### 消息目的地址 dst
9780

9881
定义:
99-
10082
- 用于路由消息到聚合根对象 格式: 服务地址/聚合类别/聚合根类别
10183

10284
### 消息来源地址 src
10385

10486
定义:
105-
10687
- 用于标识一个消息的来源,用于在需要回复的场景中进行消息回复。
10788
格式:服务地址/聚合类别/聚合根类别
10889

@@ -112,7 +93,6 @@ title: 基本概念
11293
### 事务ID transId
11394

11495
定义:
115-
11696
- 事务 Id
11797

11898
### 子事务Id subTransId
@@ -122,13 +102,11 @@ title: 基本概念
122102
### 子事务类型 subTransactionType
123103

124104
定义:
125-
126105
- 分类有:SAGA, TCC
127106

128107
### 子事务动作类型 subTransactionActionType
129108

130109
定义:
131-
132110
* subTransactionType为SAGA时,值有:T, C
133111
* subTransactionType为TCC时, 值有:Try, Confirm, Cancel
134112

docs/phoenix-2.x/phoenix-lite/config.md

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,9 @@ title: 配置
1515
| quantex.phoenix.akka.service-name | 服务名 | String | 服务名 |
1616
| quantex.phoenix.akka.discovery-method | 集群发现的方式 | String | config |
1717
| quantex.phoenix.akka.cinnamon-application | | String | 服务名 |
18-
| | | | |
1918
| 路由表(routers)配置 | | | |
2019
| quantex.phoenix.routers.message | msgName | String ||
2120
| quantex.phoenix.routers.dst | 目标地址 地址定义: 服务名/聚合类别/聚合根类别 | String ||
22-
| | | | |
2321
| ServerWorker配置 | | | |
2422
| quantex.phoenix.server.name | Server端服务名 | String ||
2523
| quantex.phoenix.server.mq.type | MQ 类型 | String | kafka |
@@ -41,7 +39,6 @@ title: 配置
4139
| quantex.phoenix.performance.retry-by-nofinished | AtLeastOneDeliveryAggregate 根据未完成事务个数判断是否继续重试 | Int | 10000|
4240
| quantex.phoenix.performance.batch-retry | AtLeastOneDeliveryAggregate 批量持久化 | Int | 1000 |
4341
| quantex.phoenix.performance.batch-persist | event-store 批量持久化 批次大小 | Int | 200 |
44-
| | | | |
4542
| client相关配置 | | | |
4643
| quantex.phoenix.client.name | Client 端服务名 | String ||
4744
| quantex.phoenix.client.mq.type | MQ 类型 | String | kafka |
@@ -52,7 +49,6 @@ title: 配置
5249
| quantex.phoenix.client.jaas-conf-path | jaas配置文件路径 | String ||
5350
| quantex.phoenix.client.krb5-conf-path | krb5配置文件路径 | String ||
5451
| quantex.phoenix.client.krb-service-name | krb服务名 | String ||
55-
| | | | |
5652

5753

5854

docs/phoenix-2.x/phoenix-lite/feature.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,9 @@ eventstore保证消息有序不丢,在服务宕机恢复是可通过从eventst
2626
## 消息幂等
2727

2828
phoenix 通过重发机制来保证消息的可靠性投递,需要设计消息幂等机制来保证同一个消息不会被多次处理。
29-
3029
phoenix 通过两种方式来实现消息幂等
31-
3230
- 在内存中维护一个固定大小的幂等队列
3331
- 通过 eventstore 的主键和唯一键索引冲突,来防止将同一消息持久化多次
34-
3532
phoenix 维护了一个1000大小的幂等集合,来存储最新处理的1000个消息的msgId,通过该集合来保证消息的幂等。由于某些不可预测的原因,可能该幂等集合幂等失败,这个时候我们可以通过eventstore表的主键和唯一键索引来保证幂等。(消息产生之后在处理之前需要先执行eventstore操作将消息持久化下来。)
3633

3734

docs/phoenix-2.x/phoenix-lite/http-api.md

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,6 @@ title: HTTP API
5858
}
5959
}
6060
```
61-
---
62-
63-
6461

6562
## 快照版本列表查询
6663

@@ -141,10 +138,6 @@ title: HTTP API
141138
}
142139
```
143140

144-
---
145-
146-
147-
148141
## 删除快照
149142

150143
```
@@ -180,10 +173,6 @@ title: HTTP API
180173
}
181174
```
182175

183-
------
184-
185-
186-
187176
## 查看内存数据
188177

189178
```
@@ -231,10 +220,6 @@ title: HTTP API
231220
}
232221
```
233222

234-
------
235-
236-
237-
238223
## 查看实例信息
239224

240225
```
@@ -265,6 +250,3 @@ title: HTTP API
265250
}
266251
}
267252
```
268-
269-
------
270-

docs/phoenix-2.x/phoenix-test/features-test-2x.md

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,7 @@ title: 功能性测试
66
## 前言
77

88
Phoenix是宽拓自主研发的一款消息驱动型的高性能Java开发框架,专注于降低金融行业中业务复杂性高、性能要求高的应用系统的开发难度,助力研发团队打造专业、高效的微服务化的金融应用系统。
9-
109
本篇测试报告主要验证了 Phoenix 提供的如下功能:
11-
1210
- 基于 Phoenix-lite 账户划拨功能正常
1311
- grafana 使用正常
1412
- EventSourcing 使用正常
@@ -23,7 +21,6 @@ title: 功能性测试
2321
### 原理介绍
2422

2523
phoenix-lite 提供了随机划拨和定向划拨两个功能:
26-
2724
1. 定向划拨:指定账户进行转入转出操作(每个账户默认初始有1000元,划拨金额大于0为转入操作,划拨金额小于0为转出操作)
2825
2. 随机划拨:指定账户范围和转账次数,多个账户同时进行划拨操作。
2926

@@ -66,7 +63,6 @@ phoenix-lite 提供了随机划拨和定向划拨两个功能:
6663
### 概述
6764

6865
Phoenix 提供了一套默认的 Grafana 监控面板,用于监控 Phoenix 应用的运行情况。监控指标包括如下内容:
69-
7066
- 消息个数统计
7167
- 指标个数统计
7268
- 耗时统计
@@ -87,9 +83,7 @@ Phoenix 提供了一套默认的 Grafana 监控面板,用于监控 Phoenix 应
8783
#### 校验方法
8884

8985
观察 Grafana 中展示出来的各个指标是否符合预期
90-
9186
Grafana的入口在 Phoenix-admin 中,关于 Phoenix-admin 的使用请参考:[Phoenix-admin 使用说明](../phoenix-admin/admin-instructions-2x)
92-
9387
关于 Grafana 各个监控指标的说明请参考:[Grafana 监控指标说明](../phoenix-admin/grafana-2x)
9488

9589
### 测试步骤
@@ -163,7 +157,6 @@ Phoenix 应用可以通过EventSourcing功能进行内存数据恢复,使用Sn
163157
### 原理介绍
164158

165159
Snapshot是对某一瞬间Phoenix应用内存的一次存储。Phoenix 提供的快照功能提供了如下操作:
166-
167160
1. 每处理1000笔消息自动打一次快照
168161
2. 手动触发打快照
169162
3. 查询快照列表
@@ -220,7 +213,6 @@ Phoenix提供了一套分布式事务的解决方案,引入 phoenix-transactio
220213
### 原理介绍
221214

222215
phoenix-lite 提供了随机转账和定向转账两个功能:
223-
224216
1. 定向转账:指定转出账户和转入账户,以及转账金额
225217
2. 随机转账:指定账户范围和转账次数,多个账户两两之间随机进行转账操作。
226218

0 commit comments

Comments
 (0)