Professional Documents
Culture Documents
AuthService
AuthService
AuthService
1.1.1. login
条件:
用户当前处在未登录状态。
错误处理:
用户输入用户名密码不匹配,向外抛出用户名密码错误异常。
1.1.2. logout
条件:
用户当前处在登录状态。
1.2. BrokerService
1.2.1. listBrokerName
条件:
用户当前处在登录状态。
1.2.2. getBrokerNameListByGroup
条件:
用户当前处在登录状态。
1.3. CommunicateService
1.3.1. sendCommand
条件:
用户当前处在登录状态。
1.3.2. subConfig
条件:
用户当前处在登录状态。
1.4. ClusterService
1.4.1. list
条件:
用户当前处在登录状态。
1.5. ConsumeService
1.5.1. consume
条件:
用户当前处在登录状态。
1.5.2. getConsumerConnection
条件:
用户当前处在登录状态。
1.6. DashBoardService
1.6.1. statisticsOverview
条件:
用户当前处在登录状态。
1.6.2. topicOverview
条件:
用户当前处在登录状态。
1.6.3. topicQuery
条件:
用户当前处在登录状态。
1.6.4. queryMsgDistribution
条件:
用户当前处在登录状态。
1.6.5. queryTopicDistribution
条件:
用户当前处在登录状态。
1.6.6. viewMsgDistribution
条件:
用户当前处在登录状态。
1.6.7. viewTopicDistribution
条件:
用户当前处在登录状态。
1.7. GroupService
1.7.1. page
条件:
用户当前处在登录状态。
1.7.2. consumerList
条件:
用户当前处在登录状态。
1.7.3. createOrUpdateGroup
条件:
用户当前处在登录状态。
1.7.4. deleteGroup
条件:
用户当前处在登录状态。
1.7.5. getClientConnection
条件:
用户当前处在登录状态。
1.7.6. getConsumerGroupConfig
条件:
用户当前处在登录状态。
1.7.7. checkGroupUnique
条件:
用户当前处在登录状态。
1.7.8. list
条件:
用户当前处在登录状态。
1.8. MessageLogServic
1.8.1. pages
条件:
用户当前处在登录状态。
SQL:
select service_id, service_name, message_id,
type, topic, lineId, tag,
"key", create_time, message_detail from MESSAGE_LOG
where
topic = ? and
message_id = ? and
service_id = ? and
create_at between ? and ? and
is_delete = 0 limit ?, ?;
1.8.2. lineIdList
条件:
用户当前处在登录状态。
SQL:
1.8.3. batchSavee
条件:
用户当前处在登录状态。
SQL:
insert into MESSAGE_LOG (service_id, service_name,
message_id,
type, topic, lineId, tag,
"key", create_time, message_detail, is_delete)
values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, 0);
1.9. MessageService
1.9.1. viewMessage
条件:
用户当前处在登录状态。
1.9.2. messageTrackDetail
条件:
用户当前处在登录状态。
1.9.3. queryMessageByTopic
条件:
用户当前处在登录状态。
1.9.4. queryMessageByTopicAndKey
条件:
用户当前处在登录状态。
1.9.5. consumeMessageDirectly
条件:
用户当前处在登录状态。
1.9.6. queryLatestMessage
条件:
用户当前处在登录状态。
1.9.7. getMessageCount
条件:
用户当前处在登录状态。
1.10. PermissionService
1.10.1. getPermissionVO
条件:
用户当前处在登录状态。
SQL:
1.10.2. getPermissionCodeByIds
条件:
用户当前处在登录状态。
SQL:
1.11. ProducerService
1.11.1. send
条件:
用户当前处在登录状态。
1.12. RolePermissionService
1.12.1. addOrUpdate
条件:
用户当前处在登录状态。
SQL:
输入记录 ID 为 null
输入记录 ID 非 null
1.12.2. removeByRoleId
条件:
用户当前处在登录状态。
SQL:
条件:
用户当前处在登录状态。
SQL:
1.13. RoleService
1.13.1. addOrUpdate
条件:
用户当前处在登录状态。
SQL:
输入记录 ID 为 null
输入记录 ID 非 null
update ROLE set name = ?, describe = ? where id = ?;
1.13.2. getPermissionCodesByRoleIds
条件:
用户当前处在登录状态。
SQL:
1.13.3. getPermissionCodesByUserId
条件:
用户当前处在登录状态。
SQL:
select p.code from ROLE_PERMISSION rp inner join
PERMISSION p on rp.permission_id = p.id
inner join DA_USER_ROLE_REL ur on ur.role_id = rp.role_id
inner join DA_USER u on u.role_id = rp.role_id
where ur.user_id in (?, ?, ?) and
rp.is_delete = 0 and
p.is_delete = 0 and
ur.is_delete = 0;
1.13.4. page
条件:
用户当前处在登录状态。
SQL:
1.13.5. roleList
条件:
用户当前处在登录状态。
SQL:
select name, “describe” from ROLE
where name like ? and
is_delete = 0 limit 100;
1.13.6. del
条件:
用户当前处在登录状态。
SQL:
1.13.7. detail
条件:
用户当前处在登录状态。
SQL:
1.14.1. saveOrUpdate
条件:
用户当前处在登录状态。
1.14.2. page
条件:
用户当前处在登录状态。
1.14.3. delete
条件:
用户当前处在登录状态。
1.14.4. changeStatus
条件:
用户当前处在登录状态。
1.14.5. listAll
条件:
用户当前处在登录状态。
1.14.6. listAllRoot
条件:
用户当前处在登录状态。
1.14.7. getServiceCount
条件:
用户当前处在登录状态。
1.14.8. getServiceInfoList
条件:
用户当前处在登录状态。
1.14.9. getServiceInfo
条件:
用户当前处在登录状态。
1.15. ServiceTopicSubService
1.15.1. add
条件:
用户当前处在登录状态。
1.15.2. del
条件:
用户当前处在登录状态。
1.15.3. pages
条件:
用户当前处在登录状态。
1.15.4. listByServiceId
条件:
用户当前处在登录状态。
1.15.5. topListExcludeRegister
条件:
用户当前处在登录状态。
1.15.6. update
条件:
用户当前处在登录状态。
1.16. TopicService
1.16.1. page
条件:
用户当前处在登录状态。
1.16.2. getTopicConfig
条件:
用户当前处在登录状态。
1.16.3. getQueueStatus
条件:
用户当前处在登录状态。
1.16.4. resetOffset
条件:
用户当前处在登录状态。
1.16.5. consumerList
条件:
用户当前处在登录状态。
1.16.6. deleteTopic
条件:
用户当前处在登录状态。
1.16.7. createOrUpdateTopic
条件:
用户当前处在登录状态。
1.16.8. getTopicCount
条件:
用户当前处在登录状态。
1.16.9. listAllName
条件:
用户当前处在登录状态。
1.16.10. listGroupNameByTopic
条件:
用户当前处在登录状态。
1.17. UserRoleRelService
1.17.1. getRoleIdsByUserId
条件:
用户当前处在登录状态。
SQL:
1.18. UserService
1.18.1. page
条件:
用户当前处在登录状态。
1.18.2. register
条件:
用户当前处在登录状态。
1.18.3. getUserByName
条件:
用户当前处在登录状态。
1.18.4. delete
条件:
用户当前处在登录状态。
1.18.5. update
条件:
用户当前处在登录状态。
1.18.6. resetPassword
条件:
用户当前处在登录状态。
1.18.7. listAll
条件:
用户当前处在登录状态。
1.18.8. listAllName
条件:
用户当前处在登录状态。
1.18.9. getCurrentUser
条件:
用户当前处在登录状态。
2. 数据库设计
2.1. 数据库模型图
图1 用户角色权限模型图
图2 服务管理模型图
2.2. 数据库表清单
表1 数据库表清单
序号 中文名称 英文名称
2.3. 数据库表结构
2.3.1. 权限表-PERMISSION
表2 权限表
表名称 PERMISSION
描述 用户权限表
字段 名称 类型 备注
id INT 主键
表3 角色表
表名称 ROLE
描述 用户角色表
名称 类型 备注
id BIGINIT 主键
表4 角色权限关系表
表名称 ROLE_PERMISSION
描述 角色权限关系表
名称 类型 备注
id BIGINIT 主键
role_id BIGINT 角色 id
2.3.4. 用户表-DA_USER
表5 用户表
表名称 DA_USER
描述 用户表
名称 类型 备注
id BIGINIT 主键
username VARCHAR 账号
password VARCHAR 密码
字段 status TINYINT 状态 0 停用 1 启用
2.3.5. 用户角色关系表-DA_USER_ROLE_REL
表6 用户角色关系表
表名称 DA_USER_ROLE_REL
描述 用户角色关系表
名称 类型 备注
id BIGINIT 主键
user_id BIGINT 用户 id
role_id BIGINT 角色 id
2.3.6. 服务信息表-DA_SERVICE_INFO
表7 服务信息表
表名称 DA_SERVICE_INFO
描述 服务信息表
字段 名称 类型 备注
id BIGINIT 主键
service_id VARCHAR 自定义服务 id
status TINYINT 状态 0 断开 1 启用
parent_id BIGINT 父 id
2.3.7. 服务消费者组关系表-SERVICE_GROUP_SUB
表8 服务消费者组关系表
表名称 SERVICE_GROUP_SUB
描述 服务消费者组关系表
名称 类型 备注
id BIGINIT 主键
2.3.8. 消息授权表-SERVICE_TOPIC_SUB
表9 消息授权表
表名称 SERVICE_TOPIC_SUB
描述 消息授权表
字段 名称 类型 备注
id BIGINIT 主键
2.3.9. 链路分析表-MESSAGE_LOG
表10 链路分析表
表名称 MESSAGE_LOG
描述 链路分析表
名称 类型 备注
id BIGINIT 主键
message_id VARCHAR 消息 id
line_id VARCHAR 行号