diff --git a/CHANGELOG/en/CHANGELOG-2.0.md b/CHANGELOG/en/CHANGELOG-2.0.md
index a539a7887a1..c93f53b828b 100644
--- a/CHANGELOG/en/CHANGELOG-2.0.md
+++ b/CHANGELOG/en/CHANGELOG-2.0.md
@@ -1,14 +1,14 @@
-- [v2.0.3](#v2032024-05-28)
+- [v2.0.3](#v203)
- [Changelog since v2.0.2](#changelog-since-v202)
-- [v2.0.2](#v2022024-03-04)
+- [v2.0.2](#v202)
- [Changelog since v2.0.1](#changelog-since-v201)
-- [v2.0.1](#v2012024-03-01)
+- [v2.0.1](#v201)
- [Changelog since v2.0.0](#changelog-since-v200)
-- [v2.0.0](#v2002024-01-02)
+- [v2.0.0](#v200)
- [Changelog since v1.14.0](#changelog-since-v1140)
@@ -16,7 +16,8 @@
-# v2.0.3(2024-05-28)
+# v2.0.3
+## 2024-05-28
## Changelog since v2.0.2
#### New
- [New] Modification of the login failure pop-up window specification [link](http://github.com/TencentBlueKing/bk-ci/issues/8125)
@@ -25,17 +26,20 @@
- [Fix] Open source community, the open source version of the project management interface needs to be authorized [link](http://github.com/TencentBlueKing/bk-ci/issues/10382)
- [Fix] The front end of the community version of the simple permission center should hide the maximum authorization scope [link](http://github.com/TencentBlueKing/bk-ci/issues/10040)
-# v2.0.2(2024-03-04)
+# v2.0.2
+## 2024-03-04
## Changelog since v2.0.1
#### New
- [New] Initialize bkrepo to modify httpSchema [link](http://github.com/TencentBlueKing/bk-ci/issues/10056)
-# v2.0.1(2024-03-01)
+# v2.0.1
+## 2024-03-01
## Changelog since v2.0.0
#### Fixes
- [Fix] Fix the problem of new project failure [link](http://github.com/TencentBlueKing/bk-ci/issues/10045)
-# v2.0.0(2024-01-02)
+# v2.0.0
+## 2024-01-02
## Changelog since v1.14.0
#### New
- [New] Support the authority center RBAC [link](http://github.com/TencentBlueKing/bk-ci/issues/7794)
diff --git a/CHANGELOG/en/CHANGELOG-2.1.md b/CHANGELOG/en/CHANGELOG-2.1.md
index 44c1aefa894..b45b5f1f789 100644
--- a/CHANGELOG/en/CHANGELOG-2.1.md
+++ b/CHANGELOG/en/CHANGELOG-2.1.md
@@ -1,32 +1,32 @@
-- [v2.1.3](#v2132024-05-28)
+- [v2.1.3](#v213)
- [Changelog since v2.1.2](#changelog-since-v212)
-- [v2.1.2](#v2122024-05-20)
+- [v2.1.2](#v212)
- [Changelog since v2.1.1](#changelog-since-v211)
-- [v2.1.1](#v2112024-04-26)
+- [v2.1.1](#v211)
- [Changelog since v2.1.0](#changelog-since-v210)
-- [v2.1.0](#v2102024-04-22)
+- [v2.1.0](#v210)
- [Changelog since v2.0.0](#changelog-since-v200)
-- [v2.1.0-rc.6](#v210-rc62024-04-19)
+- [v2.1.0-rc.6](#v210-rc6)
- [Changelog since v2.1.0-rc.5](#changelog-since-v210-rc5)
-- [v2.1.0-rc.5](#v210-rc52024-04-10)
+- [v2.1.0-rc.5](#v210-rc5)
- [Changelog since v2.1.0-rc.4](#changelog-since-v210-rc4)
-- [v2.1.0-rc.4](#v210-rc42024-03-22)
+- [v2.1.0-rc.4](#v210-rc4)
- [Changelog since v2.1.0-rc.3](#changelog-since-v210-rc3)
-- [v2.1.0-rc.3](#v210-rc32024-03-07)
+- [v2.1.0-rc.3](#v210-rc3)
- [Changelog since v2.1.0-rc.2](#changelog-since-v210-rc2)
-- [v2.1.0-rc.2](#v210-rc22024-02-22)
+- [v2.1.0-rc.2](#v210-rc2)
- [Changelog since v2.1.0-rc.1](#changelog-since-v210-rc1)
-- [v2.1.0-rc.1](#v210-rc12024-01-16)
+- [v2.1.0-rc.1](#v210-rc1)
- [Changelog since v2.0.0](#changelog-since-v200)
@@ -34,7 +34,8 @@
-# v2.1.3(2024-05-28)
+# v2.1.3
+## 2024-05-28
## Changelog since v2.1.2
#### New
- [New] Modification of the login failure pop-up window specification [link](http://github.com/TencentBlueKing/bk-ci/issues/8125)
@@ -42,17 +43,20 @@
#### Fixes
- [Fix] Open source community, the open source version of the project management interface needs to be authorized [ link ](http://github.com/TencentBlueKing/bk-ci/issues/10382)
-# v2.1.2(2024-05-20)
+# v2.1.2
+## 2024-05-20
## Changelog since v2.1.1
#### Fixes
- [Fix] [Community] Listing failure & white screen issue on pipeline execution page [v2.1.0+] [Link](http://github.com/TencentBlueKing/bk-ci/issues/10357)
-# v2.1.1(2024-04-26)
+# v2.1.1
+## 2024-04-26
## Changelog since v2.1.0
#### Fixes
- [Fix] Failed to start the process service in version 2.1 [link](http://github.com/TencentBlueKing/bk-ci/issues/10271)
-# v2.1.0(2024-04-22)
+# v2.1.0
+## 2024-04-22
## Changelog since v2.0.0
#### New
- [New] Docker build machine supports extended resource scheduling [link](http://github.com/TencentBlueKing/bk-ci/issues/10162)
@@ -325,7 +329,8 @@
- [Fix] DevCloud login debugging, window size cannot adapt [link](http://github.com/TencentBlueKing/bk-ci/issues/9418)
- [Fix] Shared credentials do not need to rely on plugin sensitive interface permission verification [link](http://github.com/TencentBlueKing/bk-ci/issues/9398)
-# v2.1.0-rc.6(2024-04-19)
+# v2.1.0-rc.6
+## 2024-04-19
## Changelog since v2.1.0-rc.5
#### New
- [New] Docker build machine supports extended resource scheduling [link](http://github.com/TencentBlueKing/bk-ci/issues/10162)
@@ -351,7 +356,8 @@
- [Fix] Under the stream pipeline, refreshing the page loads the full list [link](http://github.com/TencentBlueKing/bk-ci/issues/10152)
- [Fix] Fix the special symbol escape problem in permission application jump [link](http://github.com/TencentBlueKing/bk-ci/issues/10188)
-# v2.1.0-rc.5(2024-04-10)
+# v2.1.0-rc.5
+## 2024-04-10
## Changelog since v2.1.0-rc.4
#### New
- [New] Create/edit project openapi and add mandatory check for operational products [link](http://github.com/TencentBlueKing/bk-ci/issues/10088)
@@ -382,7 +388,8 @@
- [Fix] Fix the issue of code base permission loss [link](http://github.com/TencentBlueKing/bk-ci/issues/10131)
- [Fix] Bug in full transfer permissions [link](http://github.com/TencentBlueKing/bk- ci/issues/10117)
-# v2.1.0-rc.4(2024-03-22)
+# v2.1.0-rc.4
+## 2024-03-22
## Changelog since v2.1.0-rc.3
#### New
- [New] Public build machine supports persistent build container scheduling [link](http://github.com/TencentBlueKing/bk-ci/issues/9269)
@@ -406,7 +413,8 @@
- [Fix] When deleting a pipeline, the code base association is not deleted [link](http://github.com/TencentBlueKing/bk-ci/issues/10111)
- [Fix] When the scheduled trigger plug-in checks the latest version of the SVN code base, there is no need to call the session interface [link](http://github.com/TencentBlueKing/bk-ci/issues/10096)
-# v2.1.0-rc.3(2024-03-07)
+# v2.1.0-rc.3
+## 2024-03-07
## Changelog since v2.1.0-rc.2
#### New
- [New] SVN webhook interface switch [link](http://github.com/TencentBlueKing/bk-ci/issues/9302)
@@ -440,7 +448,8 @@
- [Fix] Fix openapi startup error [link](http://github.com/TencentBlueKing/bk-ci/issues/9997)
- [Fix] After renaming the code base, using the old alias to associate the code base will result in an error [link](http://github.com/TencentBlueKing/bk-ci/issues/9984)
-# v2.1.0-rc.2(2024-02-22)
+# v2.1.0-rc.2
+## 2024-02-22
## Changelog since v2.1.0-rc.1
#### New
- [New] Migration logic optimization [link](http://github.com/TencentBlueKing/bk-ci/issues/10014)
@@ -467,7 +476,8 @@
- [Fix] Matrix variables are not replaced after opening new expression [link](http://github.com/TencentBlueKing/bk-ci/issues/9914)
- [Fix] The plugin pauses and the dependent redis cache fails to function properly [link](http://github.com/TencentBlueKing/bk-ci/issues/9913)
-# v2.1.0-rc.1(2024-01-16)
+# v2.1.0-rc.1
+## 2024-01-16
## Changelog since v2.0.0
#### New
- [New] Pipeline archive [link](http://github.com/TencentBlueKing/bk-ci/issues/9397)
diff --git a/CHANGELOG/en/CHANGELOG-3.0.md b/CHANGELOG/en/CHANGELOG-3.0.md
index fc514b2c4ed..077bfeb3e5f 100644
--- a/CHANGELOG/en/CHANGELOG-3.0.md
+++ b/CHANGELOG/en/CHANGELOG-3.0.md
@@ -1,7 +1,7 @@
-- [v3.0.0](#v3002024-09-10)
+- [v3.0.0](#v300)
- [Changelog since v2.1.0](#changelog-since-v210)
-- [v3.0.0-rc.1](#v300-rc12024-09-10)
+- [v3.0.0-rc.1](#v300-rc1)
- [Changelog since v2.1.0](#changelog-since-v210)
@@ -9,7 +9,8 @@
-# v3.0.0(2024-09-10)
+# v3.0.0
+## 2024-09-10
## Changelog since v2.1.0
#### New
##### Pipeline
@@ -224,7 +225,8 @@
- [Fix] Synchronize difference code [link](http://github.com/TencentBlueKing/bk-ci/issues/10319)
- [Fix] Fix npm dependency vulnerability [link](http://github.com/TencentBlueKing/bk-ci/issues/10604)
-# v3.0.0-rc.1(2024-09-10)
+# v3.0.0-rc.1
+## 2024-09-10
## Changelog since v2.1.0
#### New
##### Pipeline
diff --git a/CHANGELOG/genBundledVersionLog.py b/CHANGELOG/genBundledVersionLog.py
index ecee98eb44c..3d887ff5523 100644
--- a/CHANGELOG/genBundledVersionLog.py
+++ b/CHANGELOG/genBundledVersionLog.py
@@ -24,6 +24,7 @@
"requestId": None
}
DEFAULT_LANGUAGE = "zh_CN"
+time_pattern = r'\d{4}-\d{2}-\d{2}'
# 获取版本类型, 0-输出所有版本, 1-输出release版本, 2-输出rc版本
def getVersionType():
@@ -32,20 +33,10 @@ def getVersionType():
versionType = sys.argv[1]
return int(versionType)
-def extract_version_and_time(version_title):
- index = version_title.find("(")
- # 版本号上没有时间戳
- if index == -1:
- version_name = version_title
- date = ""
- else:
- version_name = version_title[0:index]
- date = version_title[index + 1: len(version_title) - 1]
- return version_name, date
-
def extract_title_and_content(changelog_content):
sections_data = []
current_heading = None
+ current_time = ""
current_content = []
lines = changelog_content.split('\n')
@@ -53,16 +44,16 @@ def extract_title_and_content(changelog_content):
line = line.rstrip()
if line.startswith('# '):
if current_heading:
- version_name, time = extract_version_and_time(current_heading)
- sections_data.append((version_name, time , '\n'.join(current_content)))
+ sections_data.append((current_heading, current_time , '\n'.join(current_content)))
current_heading = line[2:]
current_content = []
+ elif line.startswith('## ') and re.search(time_pattern, line) and current_heading:
+ current_time = line[3:]
elif current_heading:
current_content.append(line)
if current_heading:
- version_name, time = extract_version_and_time(current_heading)
- sections_data.append((version_name, time, '\n'.join(current_content)))
+ sections_data.append((current_heading, current_time, '\n'.join(current_content)))
return sections_data
def process(data, path):
diff --git a/CHANGELOG/zh_CN/CHANGELOG-2.0.md b/CHANGELOG/zh_CN/CHANGELOG-2.0.md
index fa6b17b43a1..fd7890931d9 100644
--- a/CHANGELOG/zh_CN/CHANGELOG-2.0.md
+++ b/CHANGELOG/zh_CN/CHANGELOG-2.0.md
@@ -1,17 +1,20 @@
-- [v2.0.4](#v2042024-10-18)
+- [v2.0.5](#v205)
+ - [Changelog since v2.0.4](#changelog-since-v204)
+
+- [v2.0.4](#v204)
- [Changelog since v2.0.3](#changelog-since-v203)
-- [v2.0.3](#v2032024-05-28)
+- [v2.0.3](#v203)
- [Changelog since v2.0.2](#changelog-since-v202)
-- [v2.0.2](#v2022024-03-04)
+- [v2.0.2](#v202)
- [Changelog since v2.0.1](#changelog-since-v201)
-- [v2.0.1](#v2012024-03-01)
+- [v2.0.1](#v201)
- [Changelog since v2.0.0](#changelog-since-v200)
-- [v2.0.0](#v2002024-01-02)
+- [v2.0.0](#v200)
- [Changelog since v1.14.0](#changelog-since-v1140)
@@ -19,12 +22,20 @@
-# v2.0.4(2024-10-18)
+# v2.0.5
+## 2024-10-29
+## Changelog since v2.0.4
+#### 新增
+- [新增] 最大可授权范围更改无效修复 [链接](http://github.com/TencentBlueKing/bk-ci/issues/11153)
+
+# v2.0.4
+## 2024-10-18
## Changelog since v2.0.3
#### 修复
- [修复] 归档报告插件创建token没有实现 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10693)
-# v2.0.3(2024-05-28)
+# v2.0.3
+## 2024-05-28
## Changelog since v2.0.2
#### 新增
- [新增] 登录失效弹窗规范修改 [链接](http://github.com/TencentBlueKing/bk-ci/issues/8125)
@@ -33,17 +44,20 @@
- [修复] 开源社区,项目管理界面 开源版权限需放开 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10382)
- [修复] 社区版simple权限中心前端应该隐藏最大授权范围 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10040)
-# v2.0.2(2024-03-04)
+# v2.0.2
+## 2024-03-04
## Changelog since v2.0.1
#### 新增
- [新增] 初始化bkrepo可以修改httpSchema [链接](http://github.com/TencentBlueKing/bk-ci/issues/10056)
-# v2.0.1(2024-03-01)
+# v2.0.1
+## 2024-03-01
## Changelog since v2.0.0
#### 修复
- [修复] 修复新建项目失败 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10045)
-# v2.0.0(2024-01-02)
+# v2.0.0
+## 2024-01-02
## Changelog since v1.14.0
#### 新增
- [新增] 蓝盾对接权限中心RBAC [链接](http://github.com/TencentBlueKing/bk-ci/issues/7794)
diff --git a/CHANGELOG/zh_CN/CHANGELOG-2.1.md b/CHANGELOG/zh_CN/CHANGELOG-2.1.md
index 927e51142d1..b15d57d8f17 100644
--- a/CHANGELOG/zh_CN/CHANGELOG-2.1.md
+++ b/CHANGELOG/zh_CN/CHANGELOG-2.1.md
@@ -1,35 +1,35 @@
-- [v2.1.4](#v2142024-10-16)
+- [v2.1.4](#v214)
- [Changelog since v2.1.3](#changelog-since-v213)
--[v2.1.3](#v2132024-05-28)
+- [v2.1.3](#v213)
- [Changelog since v2.1.2](#changelog-since-v212)
-- [v2.1.2](#v2122024-05-20)
+- [v2.1.2](#v212)
- [Changelog since v2.1.1](#changelog-since-v211)
-- [v2.1.1](#v2112024-04-26)
+- [v2.1.1](#v211)
- [Changelog since v2.1.0](#changelog-since-v210)
-- [v2.1.0](#v2102024-04-22)
+- [v2.1.0](#v210)
- [Changelog since v2.0.0](#changelog-since-v200)
-- [v2.1.0-rc.6](#v210-rc62024-04-19)
+- [v2.1.0-rc.6](#v210-rc6)
- [Changelog since v2.1.0-rc.5](#changelog-since-v210-rc5)
-- [v2.1.0-rc.5](#v210-rc52024-04-10)
+- [v2.1.0-rc.5](#v210-rc5)
- [Changelog since v2.1.0-rc.4](#changelog-since-v210-rc4)
-- [v2.1.0-rc.4](#v210-rc42024-03-22)
+- [v2.1.0-rc.4](#v210-rc4)
- [Changelog since v2.1.0-rc.3](#changelog-since-v210-rc3)
-- [v2.1.0-rc.3](#v210-rc32024-03-07)
+- [v2.1.0-rc.3](#v210-rc3)
- [Changelog since v2.1.0-rc.2](#changelog-since-v210-rc2)
-- [v2.1.0-rc.2](#v210-rc22024-02-22)
+- [v2.1.0-rc.2](#v210-rc2)
- [Changelog since v2.1.0-rc.1](#changelog-since-v210-rc1)
-- [v2.1.0-rc.1](#v210-rc12024-01-16)
+- [v2.1.0-rc.1](#v210-rc1)
- [Changelog since v2.0.0](#changelog-since-v200)
@@ -37,12 +37,14 @@
-# v2.1.4(2024-10-16)
+# v2.1.4
+## 2024-10-16
## Changelog since v2.1.3
#### 修复
- [修复] 归档报告插件创建token没有实现 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10693)
-# v2.1.3(2024-05-28)
+# v2.1.3
+## 2024-05-28
## Changelog since v2.1.2
#### 新增
- [新增] 登录失效弹窗规范修改 [链接](http://github.com/TencentBlueKing/bk-ci/issues/8125)
@@ -50,17 +52,20 @@
#### 修复
- [修复] 开源社区,项目管理界面 开源版权限需放开 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10382)
-# v2.1.2(2024-05-20)
+# v2.1.2
+## 2024-05-20
## Changelog since v2.1.1
#### 修复
- [修复] [社区]上架失败&流水线执行页面白屏问题[v2.1.0+] [链接](http://github.com/TencentBlueKing/bk-ci/issues/10357)
-# v2.1.1(2024-04-26)
+# v2.1.1
+## 2024-04-26
## Changelog since v2.1.0
#### 修复
- [修复] 2.1版本process服务启动失败 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10271)
-# v2.1.0(2024-04-22)
+# v2.1.0
+## 2024-04-22
## Changelog since v2.0.0
#### 新增
- [新增] Docker构建机支持拓展资源调度 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10162)
@@ -332,7 +337,8 @@
- [修复] openapi 判断是否项目成员没有根据项目路由 [链接](http://github.com/TencentBlueKing/bk-ci/issues/9427)
- [修复] devcloud类型登录调试,窗口大小无法自适应 [链接](http://github.com/TencentBlueKing/bk-ci/issues/9418)
- [修复] 共享凭据不需要依赖插件敏感接口权限校验 [链接](http://github.com/TencentBlueKing/bk-ci/issues/9398)
-# v2.1.0-rc.6(2024-04-19)
+# v2.1.0-rc.6
+## 2024-04-19
## Changelog since v2.1.0-rc.5
#### 新增
- [新增] Docker构建机支持拓展资源调度 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10162)
@@ -358,7 +364,8 @@
- [修复] stream 流水线下,刷新页面加载了全量的列表 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10152)
- [修复] 修复申请权限跳转特殊符号转义问题 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10188)
-# v2.1.0-rc.5(2024-04-10)
+# v2.1.0-rc.5
+## 2024-04-10
## Changelog since v2.1.0-rc.4
#### 新增
- [新增] 创建/编辑项目openapi增加运营产品必填检查 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10088)
@@ -389,7 +396,8 @@
- [修复] 修复代码库权限丢失问题 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10131)
- [修复] 全量交接权限存在Bug [链接](http://github.com/TencentBlueKing/bk-ci/issues/10117)
-# v2.1.0-rc.4(2024-03-22)
+# v2.1.0-rc.4
+## 2024-03-22
## Changelog since v2.1.0-rc.3
#### 新增
- [新增] 公共构建机支持持久化构建容器调度 [链接](http://github.com/TencentBlueKing/bk-ci/issues/9269)
@@ -413,7 +421,8 @@
- [修复] 删除流水线时,代码库关联关系未删除 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10111)
- [修复] 定时触发插件检查SVN代码库最新版本时, 无需调用会话接口 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10096)
-# v2.1.0-rc.3(2024-03-07)
+# v2.1.0-rc.3
+## 2024-03-07
## Changelog since v2.1.0-rc.2
#### 新增
- [新增] svn webhook接口切换 [链接](http://github.com/TencentBlueKing/bk-ci/issues/9302)
@@ -447,7 +456,8 @@
- [修复] 修复openapi启动报错 [链接](http://github.com/TencentBlueKing/bk-ci/issues/9997)
- [修复] 重命名代码库以后, 使用旧别名关联代码库会报错 [链接](http://github.com/TencentBlueKing/bk-ci/issues/9984)
-# v2.1.0-rc.2(2024-02-22)
+# v2.1.0-rc.2
+## 2024-02-22
## Changelog since v2.1.0-rc.1
#### 新增
- [新增] 迁移逻辑优化 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10014)
@@ -474,7 +484,8 @@
- [修复] 开启了新表达式矩阵变量没有替换 [链接](http://github.com/TencentBlueKing/bk-ci/issues/9914)
- [修复] 插件暂停依赖的redis缓存失效时功能异常 [链接](http://github.com/TencentBlueKing/bk-ci/issues/9913)
-# v2.1.0-rc.1(2024-01-16)
+# v2.1.0-rc.1
+## 2024-01-16
## Changelog since v2.0.0
#### 新增
- [新增] 流水线归档 [链接](http://github.com/TencentBlueKing/bk-ci/issues/9397)
diff --git a/CHANGELOG/zh_CN/CHANGELOG-3.0.md b/CHANGELOG/zh_CN/CHANGELOG-3.0.md
index 3583e006f3c..652fd5d6acb 100644
--- a/CHANGELOG/zh_CN/CHANGELOG-3.0.md
+++ b/CHANGELOG/zh_CN/CHANGELOG-3.0.md
@@ -1,7 +1,7 @@
-- [v3.0.0](#v3002024-09-10)
+- [v3.0.0](#v300)
- [Changelog since v2.1.0](#changelog-since-v210)
-- [v3.0.0-rc.1](#v300-rc12024-09-10)
+- [v3.0.0-rc.1](#v300-rc1)
- [Changelog since v2.1.0](#changelog-since-v210)
@@ -9,7 +9,8 @@
-# v3.0.0(2024-09-10)
+# v3.0.0
+## 2024-09-10
## Changelog since v2.1.0
#### 新增
##### 流水线
@@ -224,7 +225,8 @@
- [修复] 同步差异代码 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10319)
- [修复] 修复npm依赖漏洞 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10604)
-# v3.0.0-rc.1(2024-09-10)
+# v3.0.0-rc.1
+## 2024-09-10
## Changelog since v2.1.0
#### 新增
##### 流水线
diff --git a/CHANGELOG/zh_CN/CHANGELOG-3.1.md b/CHANGELOG/zh_CN/CHANGELOG-3.1.md
index 00deffc38ac..c84e76c5bb0 100644
--- a/CHANGELOG/zh_CN/CHANGELOG-3.1.md
+++ b/CHANGELOG/zh_CN/CHANGELOG-3.1.md
@@ -1,4 +1,7 @@
+- [v3.1.0-rc.2](#v310-rc2)
+ - [Changelog since v3.1.0-rc.1](#changelog-since-v310-rc1)
+
- [v3.1.0-rc.1](#v310-rc1)
- [Changelog since v3.0.0](#changelog-since-v300)
@@ -7,7 +10,67 @@
+# v3.1.0-rc.2
+## 2024-10-26
+## Changelog since v3.1.0-rc.1
+#### 新增
+##### 流水线
+- [新增] 推荐版本号优化 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10958)
+- [新增] 支持流水线指标监控 [链接](http://github.com/TencentBlueKing/bk-ci/issues/9860)
+- [新增] 流水线列表,增加标签展示 [链接](http://github.com/TencentBlueKing/bk-ci/issues/11054)
+- [新增] 模版管理-列表支持展示字段和排序优化 [链接](http://github.com/TencentBlueKing/bk-ci/issues/11056)
+- [新增] 源材料展示优化 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10733)
+- [新增] Post action 中支持获取父任务ID [链接](http://github.com/TencentBlueKing/bk-ci/issues/10968)
+- [新增] stage 审核支持 checklist 确认场景 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10920)
+- [新增] AI大模型融入 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10825)
+- [新增] 丰富流水线-stage准入的审核功能,支持配置角色或用户组作为审核人 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10689)
+- [新增] 流水线日志支持AI修复 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10913)
+- [新增] 流水线并发运行时,支持限制并发个数和排队 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10718)
+- [新增] 插件管理菜单对应插件列表增加默认公共插件显示 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10472)
+- [新增] 当策略为「锁定构建号」时,执行界面可以修改当前值 [链接](http://github.com/TencentBlueKing/bk-ci/issues/11089)
+- [新增] 社区版流水线完成通知,支持通知组 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10976)
+- [新增] Job 互斥组排队时,队列长度支持最长到 50 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10975)
+- [新增] 触发事件重放操作权限控制 [链接](http://github.com/TencentBlueKing/bk-ci/issues/11052)
+- [新增] 通过子流水线调用触发的执行,支持重试 [链接](http://github.com/TencentBlueKing/bk-ci/issues/11015)
+- [新增] UI方式下的「所有参数满足条件时执行」和「所有参数满足条件时不执行」转为Code 优化 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10930)
+- [新增] MR 事件触发器支持 WIP [链接](http://github.com/TencentBlueKing/bk-ci/issues/10683)
+- [新增] 工蜂 MR 触发增加 action=edit [链接](http://github.com/TencentBlueKing/bk-ci/issues/11024)
+##### 代码库
+- [新增] 增加获取工蜂和github oauth url的build接口 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10826)
+##### 权限中心
+- [新增] 同步并分表存储资源组权限数据 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10964)
+- [新增] 创建自定义组并赋予组组权限 [链接](http://github.com/TencentBlueKing/bk-ci/issues/11026)
+##### 环境管理
+- [新增] 第三方构建机支持使用 dcoker 运行构建任务 [链接](http://github.com/TencentBlueKing/bk-ci/issues/9820)
+- [新增] 第三方构建机DockerUi界面支持 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10962)
+##### Openapi
+- [新增] OpenApi提供转发Turbo编译加速上报资源统计数据接口 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10508)
+##### 其他
+- [新增] 支持查看版本日志 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10938)
+- [新增] 优化AESUtil [链接](http://github.com/TencentBlueKing/bk-ci/issues/11084)
+- [新增] sql doc 文档更新 [链接](http://github.com/TencentBlueKing/bk-ci/issues/9974)
+- [新增] 引擎等MQ场景接入SCS框架 [链接](http://github.com/TencentBlueKing/bk-ci/issues/7443)
+
+#### 优化
+##### 研发商店
+- [优化] 研发商店组件指标数据字段优化 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10219)
+##### Stream
+- [优化] [stream] 存留问题优化 [链接](http://github.com/TencentBlueKing/bk-ci/issues/11045)
+
+#### 修复
+##### 流水线
+- [修复] 某些构建场景下插入T_PIPELINE_BUILD_RECORD_TASK表的CONTAINER_ID字段值错误 [链接](http://github.com/TencentBlueKing/bk-ci/issues/11029)
+- [修复] 触发器条件引入${{variables.xxx}}变量触发不了流水线 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10987)
+- [修复] 触发器变量补充 [链接](http://github.com/TencentBlueKing/bk-ci/issues/11002)
+##### 研发商店
+- [修复] 研发商店组件包文件上传下载优化 [链接](http://github.com/TencentBlueKing/bk-ci/issues/11115)
+- [修复] 修复更新组件关联初始化项目信息时,新增调试项目记录时未成功把旧的调试项目记录清理 [链接](http://github.com/TencentBlueKing/bk-ci/issues/11011)
+##### 制品库
+- [修复] 归档报告插件创建token没有实现 [链接](http://github.com/TencentBlueKing/bk-ci/issues/10693)
+
+
# v3.1.0-rc.1
+## 2024-10-15
## Changelog since v3.0.0
#### 新增
##### 流水线
diff --git a/docs/overview/db/devops_ci_auth.md b/docs/overview/db/devops_ci_auth.md
index ae8fd164cb8..246058ced55 100644
--- a/docs/overview/db/devops_ci_auth.md
+++ b/docs/overview/db/devops_ci_auth.md
@@ -32,6 +32,7 @@
| T_AUTH_RESOURCE_GROUP_APPLY | 用户组申请记录表 |
| T_AUTH_RESOURCE_GROUP_CONFIG | 资源用户组配置表 |
| T_AUTH_RESOURCE_GROUP_MEMBER | 资源组成员 |
+| T_AUTH_RESOURCE_GROUP_PERMISSION | 资源组权限表 |
| T_AUTH_RESOURCE_SYNC | 同步 IAM 资源 |
| T_AUTH_RESOURCE_TYPE | 权限资源类型表 |
| T_AUTH_STRATEGY | 权限策略表 |
@@ -276,11 +277,12 @@
| 1 | ACCESS_TOKEN | varchar | 64 | 0 | N | N | | ACCESS_TOKEN |
| 2 | CLIENT_ID | varchar | 32 | 0 | N | N | | 客户端 ID |
| 3 | USER_NAME | varchar | 32 | 0 | Y | N | | 登录的用户名,客户端模式该值为空 |
-| 4 | GRANT_TYPE | varchar | 32 | 0 | N | N | | 授权模式 |
-| 5 | EXPIRED_TIME | bigint | 20 | 0 | N | N | | 过期时间 |
-| 6 | REFRESH_TOKEN | varchar | 64 | 0 | Y | N | | REFRESH_TOKEN,客户端模式该值为空 |
-| 7 | SCOPE_ID | int | 10 | 0 | N | N | | 授权范围 ID |
-| 8 | CREATE_TIME | datetime | 19 | 0 | N | N | CURRENT_TIMESTAMP | 创建时间 |
+| 4 | PASS_WORD | varchar | 64 | 0 | Y | N | | 用于密码模式 |
+| 5 | GRANT_TYPE | varchar | 32 | 0 | N | N | | 授权模式 |
+| 6 | EXPIRED_TIME | bigint | 20 | 0 | N | N | | 过期时间 |
+| 7 | REFRESH_TOKEN | varchar | 64 | 0 | Y | N | | REFRESH_TOKEN,客户端模式该值为空 |
+| 8 | SCOPE_ID | int | 10 | 0 | N | N | | 授权范围 ID |
+| 9 | CREATE_TIME | datetime | 19 | 0 | N | N | CURRENT_TIMESTAMP | 创建时间 |
**表名:** T_AUTH_OAUTH2_CLIENT_DETAILS
@@ -479,6 +481,29 @@
| 11 | CREATE_TIME | datetime | 19 | 0 | N | N | CURRENT_TIMESTAMP | 创建时间 |
| 12 | UPDATE_TIME | datetime | 19 | 0 | N | N | CURRENT_TIMESTAMP | 更新时间 |
+**表名:** T_AUTH_RESOURCE_GROUP_PERMISSION
+
+**说明:** 资源组权限表
+
+**数据列:**
+
+| 序号 | 名称 | 数据类型 | 长度 | 小数位 | 允许空值 | 主键 | 默认值 | 说明 |
+| :---: | :---: | :---: | :---: | :---: | :---: | :---: | :---: | :---: |
+| 1 | ID | bigint | 20 | 0 | N | Y | | 主键 ID |
+| 2 | PROJECT_CODE | varchar | 64 | 0 | N | N | | 项目 ID |
+| 3 | RESOURCE_TYPE | varchar | 32 | 0 | N | N | | 用户组关联的资源类型 |
+| 4 | RESOURCE_CODE | varchar | 255 | 0 | N | N | | 用户组关联的资源 ID |
+| 5 | IAM_RESOURCE_CODE | varchar | 32 | 0 | N | N | | 用户组关联的 IAM 资源 ID |
+| 6 | GROUP_CODE | varchar | 32 | 0 | N | N | | 用户组标识 |
+| 7 | IAM_GROUP_ID | int | 10 | 0 | N | N | | 关联的 IAM 组 ID |
+| 8 | ACTION | varchar | 64 | 0 | N | N | | 操作 ID |
+| 9 | ACTION_RELATED_RESOURCE_TYPE | varchar | 32 | 0 | N | N | | 动作关联的资源类型 |
+| 10 | RELATED_RESOURCE_TYPE | varchar | 32 | 0 | N | N | | 组权限关联的资源类型 |
+| 11 | RELATED_RESOURCE_CODE | varchar | 255 | 0 | N | N | | 组权限关联的资源 ID |
+| 12 | RELATED_IAM_RESOURCE_CODE | varchar | 255 | 0 | N | N | | 组权限关联的资源 ID |
+| 13 | CREATE_TIME | datetime | 19 | 0 | N | N | CURRENT_TIMESTAMP | 创建时间 |
+| 14 | UPDATE_TIME | datetime | 19 | 0 | N | N | CURRENT_TIMESTAMP | 更新时间 |
+
**表名:** T_AUTH_RESOURCE_SYNC
**说明:** 同步 IAM 资源
diff --git a/docs/overview/db/devops_ci_plugin.md b/docs/overview/db/devops_ci_plugin.md
index ac496d2a91b..6500a0ec287 100644
--- a/docs/overview/db/devops_ci_plugin.md
+++ b/docs/overview/db/devops_ci_plugin.md
@@ -7,9 +7,29 @@
**文档描述:** devops_ci_plugin 的数据库文档
| 表名 | 说明 |
| :---: | :---: |
+| T_AI_SCORE | 脚本执行报错 AI 分析-评分 |
| T_PLUGIN_GITHUB_CHECK | |
| T_PLUGIN_GIT_CHECK | |
+**表名:** T_AI_SCORE
+
+**说明:** 脚本执行报错 AI 分析-评分
+
+**数据列:**
+
+| 序号 | 名称 | 数据类型 | 长度 | 小数位 | 允许空值 | 主键 | 默认值 | 说明 |
+| :---: | :---: | :---: | :---: | :---: | :---: | :---: | :---: | :---: |
+| 1 | ID | bigint | 20 | 0 | N | Y | | 主键 ID |
+| 2 | LABEL | varchar | 256 | 0 | N | N | | 任务 ID |
+| 3 | ARCHIVE | bit | 1 | 0 | N | N | 0 | 是否已归档 |
+| 4 | CREATE_TIME | datetime | 19 | 0 | N | N | CURRENT_TIMESTAMP | 创建时间 |
+| 5 | UPDATE_TIME | datetime | 19 | 0 | N | N | CURRENT_TIMESTAMP | 更新时间 |
+| 6 | GOOD_USERS | text | 65535 | 0 | Y | N | | 赞的人 |
+| 7 | BAD_USERS | text | 65535 | 0 | Y | N | | 踩的人 |
+| 8 | AI_MSG | text | 65535 | 0 | Y | N | | 大模型生成的内容 |
+| 9 | SYSTEM_MSG | text | 65535 | 0 | Y | N | | Promptforsystem |
+| 10 | USER_MSG | text | 65535 | 0 | Y | N | | Promptforuser |
+
**表名:** T_PLUGIN_GITHUB_CHECK
**说明:**
diff --git a/docs/overview/db/devops_ci_process.md b/docs/overview/db/devops_ci_process.md
index 26fcaa288af..8f714dcff53 100644
--- a/docs/overview/db/devops_ci_process.md
+++ b/docs/overview/db/devops_ci_process.md
@@ -427,6 +427,7 @@
| 11 | CONDITIONS | mediumtext | 16777215 | 0 | Y | N | | 状况 |
| 12 | CHECK_IN | mediumtext | 16777215 | 0 | Y | N | | 准入检查配置 |
| 13 | CHECK_OUT | mediumtext | 16777215 | 0 | Y | N | | 准出检查配置 |
+| 14 | STAGE_ID_FOR_USER | varchar | 64 | 0 | Y | N | | 当前 stageId 阶段 ID(用户可编辑) |
**表名:** T_PIPELINE_BUILD_SUMMARY
@@ -834,7 +835,7 @@
| 24 | SUCCESS_WECHAT_GROUP_MARKDOWN_FLAG | bit | 1 | 0 | N | N | b'0' | 成功的企业微信群通知转为 Markdown 格式开关 |
| 25 | FAIL_WECHAT_GROUP_MARKDOWN_FLAG | bit | 1 | 0 | N | N | b'0' | 失败的企业微信群通知转为 Markdown 格式开关 |
| 26 | MAX_PIPELINE_RES_NUM | int | 10 | 0 | Y | N | 500 | 保存流水线编排的最大个数 |
-| 27 | MAX_CON_RUNNING_QUEUE_SIZE | int | 10 | 0 | Y | N | 50 | 并发构建数量限制 |
+| 27 | MAX_CON_RUNNING_QUEUE_SIZE | int | 10 | 0 | Y | N | | 并发构建数量限制,为 null 时表示取系统默认值 |
| 28 | BUILD_NUM_RULE | varchar | 512 | 0 | Y | N | | 构建号生成规则 |
| 29 | CONCURRENCY_GROUP | varchar | 255 | 0 | Y | N | | 并发时,设定的 group |
| 30 | CONCURRENCY_CANCEL_IN_PROGRESS | bit | 1 | 0 | Y | N | b'0' | 并发时,是否相同 group 取消正在执行的流水线 |
@@ -885,6 +886,7 @@
| 31 | FAIL_CONTENT | longtext | 2147483647 | 0 | Y | N | | |
| 32 | SUCCESS_WECHAT_GROUP_MARKDOWN_FLAG | bit | 1 | 0 | N | N | b'0' | |
| 33 | FAIL_WECHAT_GROUP_MARKDOWN_FLAG | bit | 1 | 0 | Y | N | b'0' | |
+| 34 | MAX_CON_RUNNING_QUEUE_SIZE | int | 10 | 0 | Y | N | | 并发构建数量限制,值为-1 时表示取系统默认值。 |
**表名:** T_PIPELINE_STAGE_TAG
diff --git a/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/ServiceGroupResource.kt b/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/ServiceGroupResource.kt
deleted file mode 100644
index 440ecb2523b..00000000000
--- a/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/ServiceGroupResource.kt
+++ /dev/null
@@ -1,77 +0,0 @@
-/*
- * Tencent is pleased to support the open source community by making BK-CI 蓝鲸持续集成平台 available.
- *
- * Copyright (C) 2019 THL A29 Limited, a Tencent company. All rights reserved.
- *
- * BK-CI 蓝鲸持续集成平台 is licensed under the MIT license.
- *
- * A copy of the MIT License is included in this file.
- *
- *
- * Terms of the MIT License:
- * ---------------------------------------------------
- * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
- * documentation files (the "Software"), to deal in the Software without restriction, including without limitation the
- * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to
- * permit persons to whom the Software is furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
- * the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
- * LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
- * NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
- * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
- */
-
-package com.tencent.devops.auth.api
-
-import com.tencent.devops.auth.pojo.dto.GroupDTO
-import com.tencent.devops.common.api.auth.AUTH_HEADER_USER_ID
-import com.tencent.devops.common.api.pojo.Result
-import io.swagger.v3.oas.annotations.tags.Tag
-import io.swagger.v3.oas.annotations.Operation
-import io.swagger.v3.oas.annotations.Parameter
-import javax.ws.rs.Consumes
-import javax.ws.rs.HeaderParam
-import javax.ws.rs.POST
-import javax.ws.rs.Path
-import javax.ws.rs.PathParam
-import javax.ws.rs.Produces
-import javax.ws.rs.core.MediaType
-
-@Tag(name = "AUTH_GROUP", description = "权限-用户组")
-@Path("/service/auth/group")
-@Produces(MediaType.APPLICATION_JSON)
-@Consumes(MediaType.APPLICATION_JSON)
-interface ServiceGroupResource {
-
- @POST
- @Path("/projectCodes/{projectCode}/")
- @Operation(summary = "项目下添加指定组")
- fun createGroup(
- @Parameter(description = "用户名", required = true)
- @HeaderParam(AUTH_HEADER_USER_ID)
- userId: String,
- @Parameter(description = "项目标识", required = true)
- @PathParam("projectCode")
- projectCode: String,
- @Parameter(description = "用户组信息", required = true)
- groupInfo: GroupDTO
- ): Result
-
- @POST
- @Path("/projectCodes/{projectCode}/batchCreate")
- @Operation(summary = "项目下添加指定组")
- fun batchCreateGroup(
- @Parameter(description = "用户名", required = true)
- @HeaderParam(AUTH_HEADER_USER_ID)
- userId: String,
- @Parameter(description = "项目标识", required = true)
- @PathParam("projectCode")
- projectCode: String,
- @Parameter(description = "用户组信息", required = true)
- groupInfos: List
- ): Result
-}
diff --git a/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/ServiceUserGroupResource.kt b/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/ServiceUserGroupResource.kt
deleted file mode 100644
index a297c2c1c29..00000000000
--- a/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/ServiceUserGroupResource.kt
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * Tencent is pleased to support the open source community by making BK-CI 蓝鲸持续集成平台 available.
- *
- * Copyright (C) 2019 THL A29 Limited, a Tencent company. All rights reserved.
- *
- * BK-CI 蓝鲸持续集成平台 is licensed under the MIT license.
- *
- * A copy of the MIT License is included in this file.
- *
- *
- * Terms of the MIT License:
- * ---------------------------------------------------
- * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
- * documentation files (the "Software"), to deal in the Software without restriction, including without limitation the
- * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to
- * permit persons to whom the Software is furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
- * the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
- * LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
- * NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
- * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
- * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
- */
-
-package com.tencent.devops.auth.api
-
-import com.tencent.devops.common.api.auth.AUTH_HEADER_USER_ID
-import com.tencent.devops.common.api.pojo.Result
-import io.swagger.v3.oas.annotations.tags.Tag
-import io.swagger.v3.oas.annotations.Operation
-import io.swagger.v3.oas.annotations.Parameter
-import javax.ws.rs.Consumes
-import javax.ws.rs.POST
-import javax.ws.rs.Path
-import javax.ws.rs.PathParam
-import javax.ws.rs.Produces
-import javax.ws.rs.core.MediaType
-
-@Tag(name = "AUTH_USER_GROUP", description = "权限-用户-用户组")
-@Path("/service/auth/userGroup")
-@Produces(MediaType.APPLICATION_JSON)
-@Consumes(MediaType.APPLICATION_JSON)
-interface ServiceUserGroupResource {
-
- @POST
- @Path("/users/{userId}/groupIds/{groupId}")
- @Operation(summary = "添加用户到指定组")
- fun addUser2Group(
- @Parameter(description = "用户名", required = true)
- @PathParam(AUTH_HEADER_USER_ID)
- userId: String,
- @Parameter(description = "用户组Id", required = true)
- @PathParam("groupId")
- groupId: Int
- ): Result
-}
diff --git a/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/migrate/OpAuthMigrateResource.kt b/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/migrate/OpAuthMigrateResource.kt
index 868c8d533cc..98d9fb98965 100644
--- a/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/migrate/OpAuthMigrateResource.kt
+++ b/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/migrate/OpAuthMigrateResource.kt
@@ -165,4 +165,12 @@ interface OpAuthMigrateResource {
@Parameter(description = "迁移项目", required = true)
projectCodes: List
): Result
+
+ @POST
+ @Path("/enablePipelineListPermissionControl")
+ @Operation(summary = "开启流水线列表权限控制")
+ fun enablePipelineListPermissionControl(
+ @Parameter(description = "项目", required = true)
+ projectCodes: List
+ ): Result
}
diff --git a/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/callback/OpCallBackResource.kt b/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/op/OpCallBackResource.kt
similarity index 98%
rename from src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/callback/OpCallBackResource.kt
rename to src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/op/OpCallBackResource.kt
index 363eecb272f..26167b0f38b 100644
--- a/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/callback/OpCallBackResource.kt
+++ b/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/op/OpCallBackResource.kt
@@ -25,7 +25,7 @@
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
-package com.tencent.devops.auth.api.callback
+package com.tencent.devops.auth.api.op
import com.tencent.devops.auth.pojo.IamCallBackInfo
import com.tencent.devops.auth.pojo.IamCallBackInterfaceDTO
diff --git a/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/open/OpenPermissionAuthResource.kt b/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/open/OpenPermissionAuthResource.kt
new file mode 100644
index 00000000000..9ccfe984dae
--- /dev/null
+++ b/src/backend/ci/core/auth/api-auth/src/main/kotlin/com/tencent/devops/auth/api/open/OpenPermissionAuthResource.kt
@@ -0,0 +1,374 @@
+/*
+ * Tencent is pleased to support the open source community by making BK-CI 蓝鲸持续集成平台 available.
+ *
+ * Copyright (C) 2019 THL A29 Limited, a Tencent company. All rights reserved.
+ *
+ * BK-CI 蓝鲸持续集成平台 is licensed under the MIT license.
+ *
+ * A copy of the MIT License is included in this file.
+ *
+ *
+ * Terms of the MIT License:
+ * ---------------------------------------------------
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation the
+ * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to
+ * permit persons to whom the Software is furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
+ * the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
+ * LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+ * NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
+ * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+package com.tencent.devops.auth.api.open
+
+import com.tencent.devops.common.api.auth.AUTH_HEADER_DEVOPS_BK_TOKEN
+import com.tencent.devops.common.api.auth.AUTH_HEADER_DEVOPS_USER_ID
+import com.tencent.devops.common.api.auth.AUTH_HEADER_GIT_TYPE
+import com.tencent.devops.common.api.pojo.Result
+import com.tencent.devops.common.auth.api.AuthPermission
+import com.tencent.devops.common.auth.api.pojo.AuthResourceInstance
+import io.swagger.v3.oas.annotations.Operation
+import io.swagger.v3.oas.annotations.Parameter
+import io.swagger.v3.oas.annotations.tags.Tag
+import javax.ws.rs.Consumes
+import javax.ws.rs.DELETE
+import javax.ws.rs.GET
+import javax.ws.rs.HeaderParam
+import javax.ws.rs.POST
+import javax.ws.rs.PUT
+import javax.ws.rs.Path
+import javax.ws.rs.PathParam
+import javax.ws.rs.Produces
+import javax.ws.rs.QueryParam
+import javax.ws.rs.core.MediaType
+
+@Tag(name = "AUTH_OPEN_PERMISSION", description = "权限--权限校验以及资源操作相关接口")
+@Path("/open/service/auth/permission")
+@Produces(MediaType.APPLICATION_JSON)
+@Consumes(MediaType.APPLICATION_JSON)
+@SuppressWarnings("LongParameterList")
+interface OpenPermissionAuthResource {
+
+ @GET
+ @Path("/projects/{projectCode}/action/validate")
+ @Operation(summary = "校验用户是否有具体操作的权限")
+ fun validateUserActionPermission(
+ @HeaderParam(AUTH_HEADER_DEVOPS_USER_ID)
+ @Parameter(description = "待校验用户ID", required = true)
+ userId: String,
+ @HeaderParam(AUTH_HEADER_DEVOPS_BK_TOKEN)
+ @Parameter(description = "认证token", required = true)
+ token: String,
+ @HeaderParam(AUTH_HEADER_GIT_TYPE)
+ @Parameter(description = "系统类型")
+ type: String? = null,
+ @QueryParam("action")
+ @Parameter(description = "资源类型", required = true)
+ action: String
+ ): Result
+
+ @GET
+ @Path("/projects/{projectCode}/resource/validate")
+ @Operation(summary = "校验用户是否有具体资源的操作权限")
+ fun validateUserResourcePermission(
+ @HeaderParam(AUTH_HEADER_DEVOPS_USER_ID)
+ @Parameter(description = "待校验用户ID", required = true)
+ userId: String,
+ @HeaderParam(AUTH_HEADER_DEVOPS_BK_TOKEN)
+ @Parameter(description = "认证token", required = true)
+ token: String,
+ @HeaderParam(AUTH_HEADER_GIT_TYPE)
+ @Parameter(description = "系统类型")
+ type: String? = null,
+ @QueryParam("action")
+ @Parameter(description = "资源类型", required = true)
+ action: String,
+ @QueryParam("projectCode")
+ @Parameter(description = "项目编码", required = true)
+ projectCode: String,
+ // 此处resourceCode实际为resourceType
+ @QueryParam("resourceCode")
+ @Parameter(description = "资源类型", required = false)
+ resourceCode: String?
+ ): Result
+
+ @GET
+ @Path("/projects/{projectCode}/relation/validate")
+ @Operation(summary = "校验用户是否有具体资源实例的操作权限")
+ fun validateUserResourcePermissionByRelation(
+ @HeaderParam(AUTH_HEADER_DEVOPS_USER_ID)
+ @Parameter(description = "待校验用户ID", required = true)
+ userId: String,
+ @HeaderParam(AUTH_HEADER_DEVOPS_BK_TOKEN)
+ @Parameter(description = "认证token", required = true)
+ token: String,
+ @HeaderParam(AUTH_HEADER_GIT_TYPE)
+ @Parameter(description = "系统类型")
+ type: String? = null,
+ @QueryParam("action")
+ @Parameter(description = "action类型", required = true)
+ action: String,
+ @PathParam("projectCode")
+ @Parameter(description = "项目Code", required = true)
+ projectCode: String,
+ @QueryParam("resourceCode")
+ @Parameter(description = "资源code", required = true)
+ resourceCode: String,
+ @QueryParam("resourceType")
+ @Parameter(description = "资源类型", required = true)
+ resourceType: String,
+ @QueryParam("relationResourceType")
+ @Parameter(description = "关联资源,一般为Project", required = false)
+ relationResourceType: String? = null
+ ): Result
+
+ @POST
+ @Path("/projects/{projectCode}/instance/validate")
+ @Operation(summary = "校验用户是否有具体资源实例的操作权限")
+ fun validateUserResourcePermissionByInstance(
+ @HeaderParam(AUTH_HEADER_DEVOPS_USER_ID)
+ @Parameter(description = "待校验用户ID", required = true)
+ userId: String,
+ @HeaderParam(AUTH_HEADER_DEVOPS_BK_TOKEN)
+ @Parameter(description = "认证token", required = true)
+ token: String,
+ @HeaderParam(AUTH_HEADER_GIT_TYPE)
+ @Parameter(description = "系统类型")
+ type: String? = null,
+ @QueryParam("action")
+ @Parameter(description = "action类型", required = true)
+ action: String,
+ @PathParam("projectCode")
+ @Parameter(description = "项目Code", required = true)
+ projectCode: String,
+ resource: AuthResourceInstance
+ ): Result
+
+ @POST
+ @Path("/projects/{projectCode}/relation/validate/batch")
+ @Operation(summary = "批量校验用户是否有具体资源实例的操作权限")
+ fun batchValidateUserResourcePermissionByRelation(
+ @HeaderParam(AUTH_HEADER_DEVOPS_USER_ID)
+ @Parameter(description = "待校验用户ID", required = true)
+ userId: String,
+ @HeaderParam(AUTH_HEADER_DEVOPS_BK_TOKEN)
+ @Parameter(description = "认证token", required = true)
+ token: String,
+ @HeaderParam(AUTH_HEADER_GIT_TYPE)
+ @Parameter(description = "系统类型")
+ type: String? = null,
+ @PathParam("projectCode")
+ @Parameter(description = "项目Code", required = true)
+ projectCode: String,
+ @QueryParam("resourceCode")
+ @Parameter(description = "资源code", required = true)
+ resourceCode: String,
+ @QueryParam("resourceType")
+ @Parameter(description = "资源类型", required = true)
+ resourceType: String,
+ @QueryParam("relationResourceType")
+ @Parameter(description = "关联资源,一般为Project", required = false)
+ relationResourceType: String? = null,
+ @Parameter(description = "action类型列表", required = true)
+ action: List
+ ): Result
+
+ @GET
+ @Path("/projects/{projectCode}/action/instanceAndParent")
+ @Operation(summary = "获取用户所拥有指定权限下的指定类型资源和类型父资源code列表")
+ fun getUserResourceAndParentByPermission(
+ @HeaderParam(AUTH_HEADER_DEVOPS_USER_ID)
+ @Parameter(description = "待校验用户ID", required = true)
+ userId: String,
+ @HeaderParam(AUTH_HEADER_DEVOPS_BK_TOKEN)
+ @Parameter(description = "认证token", required = true)
+ token: String,
+ @HeaderParam(AUTH_HEADER_GIT_TYPE)
+ @Parameter(description = "系统类型")
+ type: String? = null,
+ @QueryParam("action")
+ @Parameter(description = "action类型")
+ action: String,
+ @PathParam("projectCode")
+ @Parameter(description = "项目Code", required = true)
+ projectCode: String,
+ @QueryParam("resourceType")
+ @Parameter(description = "资源类型")
+ resourceType: String
+ ): Result