From 13d90653fce98fc48b2c84f2182d8c73540d897f Mon Sep 17 00:00:00 2001
From: Svamei <41992090+Svamei@users.noreply.github.com>
Date: Thu, 30 Mar 2023 09:29:17 +0800
Subject: [PATCH] Complete the text translation of the 'Container Thread Pool'
module (#1139)
* Complete the text translation of the 'Thread Pool Monitor' page
* Complete the text translation of the 'Container Thread Pool' module
---
.../src/views/hippo4j/server/jetty/index.vue | 104 +++++++++--------
.../src/views/hippo4j/server/tomcat/index.vue | 104 ++++++++---------
.../views/hippo4j/server/undertow/index.vue | 106 +++++++++---------
3 files changed, 155 insertions(+), 159 deletions(-)
diff --git a/hippo4j-ui/src/views/hippo4j/server/jetty/index.vue b/hippo4j-ui/src/views/hippo4j/server/jetty/index.vue
index 6b4c9709..487ceac0 100755
--- a/hippo4j-ui/src/views/hippo4j/server/jetty/index.vue
+++ b/hippo4j-ui/src/views/hippo4j/server/jetty/index.vue
@@ -3,7 +3,7 @@
- 搜索
+ {{ $t('common.query') }}
-
+
{{ scope.$index + 1 }}
-
+
{{ scope.row.identify }}
-
+
{{ scope.row.active }}
-
+
{{ scope.row.coreSize }}
-
+
{{ scope.row.maximumSize }}
-
+
{{ scope.row.queueType }}
-
+
{{ scope.row.queueCapacity }}
-
+
{{ scope.row.rejectedName }}
-
+
{{ scope.row.keepAliveTime }}
- 查看
-
- 编辑
-
+ {{ $t('common.detail') }}
+ {{ $t('common.edit') }}
@@ -108,81 +106,81 @@
width="1000px"
>
-
+
- 当前负载
+ {{ $t('threadPoolInstance.CurrentLoad') }}
{{ runTimeTemp.currentLoad }}
- 峰值负载
+ {{ $t('threadPoolInstance.PeakLoad') }}
{{ runTimeTemp.peakLoad }}
- 剩余内存
+ {{ $t('threadPoolInstance.RemainingMemory') }}
{{ runTimeTemp.freeMemory }}
- 内存占比
+ {{ $t('threadPoolInstance.MemoryRatio') }}
{{ runTimeTemp.memoryProportion }}
-
+
- 核心线程
+ {{ $t('threadPool.coreSize') }}
{{ runTimeTemp.coreSize }}
- 当前线程
+ {{ $t('threadPoolInstance.currentSize') }}
{{ runTimeTemp.poolSize }}
- 最大线程
+ {{ $t('threadPool.maximumSize') }}
{{ runTimeTemp.maximumSize }}
- 活跃线程
+ {{ $t('threadPoolInstance.activeSize') }}
{{ runTimeTemp.activeSize }}
- 同存最大线程
+ {{ $t('threadPoolInstance.largestSize') }}
{{ runTimeTemp.largestPoolSize }}
-
+
- 队列容量
+ {{ $t('threadPool.queueCapacity') }}
{{ runTimeTemp.queueCapacity }}
- 队列元素
+ {{ $t('threadPoolInstance.queueCount') }}
{{ runTimeTemp.queueSize }}
- 队列剩余容量
+ {{ $t('threadPoolInstance.queueRemainingCapacity') }}
{{ runTimeTemp.queueRemainingCapacity }}
- 阻塞队列
+ {{ $t('threadPoolInstance.queueType') }}
{{ runTimeTemp.queueType }}
-
+
- 任务总量
+ {{ $t('threadPoolInstance.totalTask') }}
{{ runTimeTemp.completedTaskCount }}
- 最后更新时间
+ {{ $t('threadPoolInstance.lastUpdateTime') }}
{{ runTimeTemp.clientLastRefreshTime }}
- 拒绝策略
+ {{ $t('threadPool.rejectedHandler') }}
{{ runTimeTemp.rejectedName }}
@@ -190,11 +188,11 @@
@@ -206,7 +204,7 @@
label-position="left"
label-width="110px"
>
-
+
-
+
-
+
@@ -352,11 +350,11 @@ export default {
},
fetchData() {
if (!this.listQuery.tenantId) {
- this.$message.warning('租户不允许为空');
+ this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('tenantManage.tenant') }));
return;
}
if (!this.listQuery.itemId) {
- this.$message.warning('项目不允许为空');
+ this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('projectManage.item') }));
return;
}
this.listLoading = true;
@@ -474,7 +472,7 @@ export default {
if (valid) {
if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) {
this.$message({
- message: '最大线程必须大于等于核心线程',
+ message: this.$t('threadPool.threadsNumErrorTip'),
type: 'warning',
});
return;
@@ -482,7 +480,7 @@ export default {
const clientAddressList = [];
const tempData = {
corePoolSize: this.temp.coreSize,
- itemId: this.temp.itemId,
+ temId: this.temp.itemId,
tenantId: this.temp.tenantId,
maximumPoolSize: this.temp.maximumSize,
keepAliveTime: this.temp.keepAliveTime,
@@ -520,14 +518,14 @@ export default {
})
.catch((error) => {
console.log(error);
- this.$message.error('查询失败,请尝试刷新页面');
+ this.$message.error(this.$t('message.queryFailure'));
});
},
openDelConfirm(name) {
- return this.$confirm(`此操作将删除 ${name}, 是否继续?`, '提示', {
- confirmButtonText: '确定',
- cancelButtonText: '取消',
+ return this.$confirm(this.$t('message.deleteMessage', { name }), this.$t('common.hint'), {
+ confirmButtonText: this.$t('common.ok'),
+ cancelButtonText: this.$t('common.cancel'),
type: 'warning',
});
},
@@ -634,7 +632,7 @@ export default {
})
.catch((error) => {
console.log(error);
- this.$message.error('查询失败,请尝试刷新页面');
+ this.$message.error(this.$t('message.queryFailure'));
});
},
},
diff --git a/hippo4j-ui/src/views/hippo4j/server/tomcat/index.vue b/hippo4j-ui/src/views/hippo4j/server/tomcat/index.vue
index d9f8c015..b62d904f 100755
--- a/hippo4j-ui/src/views/hippo4j/server/tomcat/index.vue
+++ b/hippo4j-ui/src/views/hippo4j/server/tomcat/index.vue
@@ -3,7 +3,7 @@
- 搜索
+ {{ $t('common.query') }}
-
+
{{ scope.$index + 1 }}
-
+
{{ scope.row.identify }}
-
+
{{ scope.row.active }}
-
+
{{ scope.row.coreSize }}
-
+
{{ scope.row.maximumSize }}
-
+
{{ scope.row.queueType }}
-
+
{{ scope.row.queueCapacity }}
-
+
{{ scope.row.rejectedName }}
-
+
{{ scope.row.keepAliveTime }}
- 查看
- 编辑
+ {{ $t('common.detail') }}
+ {{ $t('common.edit') }}
@@ -106,81 +106,81 @@
width="1000px"
>
-
+
- 当前负载
+ {{ $t('threadPoolInstance.CurrentLoad') }}
{{ runTimeTemp.currentLoad }}
- 峰值负载
+ {{ $t('threadPoolInstance.PeakLoad') }}
{{ runTimeTemp.peakLoad }}
- 剩余内存
+ {{ $t('threadPoolInstance.RemainingMemory') }}
{{ runTimeTemp.freeMemory }}
- 内存占比
+ {{ $t('threadPoolInstance.MemoryRatio') }}
{{ runTimeTemp.memoryProportion }}
-
+
- 核心线程
+ {{ $t('threadPool.coreSize') }}
{{ runTimeTemp.coreSize }}
- 当前线程
+ {{ $t('threadPoolInstance.currentSize') }}
{{ runTimeTemp.poolSize }}
- 最大线程
+ {{ $t('threadPool.maximumSize') }}
{{ runTimeTemp.maximumSize }}
- 活跃线程
+ {{ $t('threadPoolInstance.activeSize') }}
{{ runTimeTemp.activeSize }}
- 同存最大线程
+ {{ $t('threadPoolInstance.largestSize') }}
{{ runTimeTemp.largestPoolSize }}
-
+
- 队列容量
+ {{ $t('threadPool.queueCapacity') }}
{{ runTimeTemp.queueCapacity }}
- 队列元素
+ {{ $t('threadPoolInstance.queueCount') }}
{{ runTimeTemp.queueSize }}
- 队列剩余容量
+ {{ $t('threadPoolInstance.queueRemainingCapacity') }}
{{ runTimeTemp.queueRemainingCapacity }}
- 阻塞队列
+ {{ $t('threadPoolInstance.queueType') }}
{{ runTimeTemp.queueType }}
-
+
- 任务总量
+ {{ $t('threadPoolInstance.totalTask') }}
{{ runTimeTemp.completedTaskCount }}
- 最后更新时间
+ {{ $t('threadPoolInstance.lastUpdateTime') }}
{{ runTimeTemp.clientLastRefreshTime }}
- 拒绝策略
+ {{ $t('threadPool.rejectedHandler') }}
{{ runTimeTemp.rejectedName }}
@@ -188,11 +188,11 @@
@@ -204,7 +204,7 @@
label-position="left"
label-width="110px"
>
-
+
-
+
-
+
-
+
@@ -272,7 +272,7 @@ export default {
UAT: 'warning',
PROD: 'danger',
};
- return statusMap[status];
+ return statusMap[status]
},
},
data() {
@@ -360,11 +360,11 @@ export default {
},
fetchData() {
if (!this.listQuery.tenantId) {
- this.$message.warning('租户不允许为空');
+ this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('tenantManage.tenant') }));
return;
}
if (!this.listQuery.itemId) {
- this.$message.warning('项目不允许为空');
+ this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('projectManage.item') }));
return;
}
this.listLoading = true;
@@ -482,7 +482,7 @@ export default {
if (valid) {
if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) {
this.$message({
- message: '最大线程必须大于等于核心线程',
+ message: this.$t('threadPool.threadsNumErrorTip'),
type: 'warning',
});
return;
@@ -528,14 +528,14 @@ export default {
})
.catch((error) => {
console.log(error);
- this.$message.error('查询失败,请尝试刷新页面');
+ this.$message.error(this.$t('message.queryFailure'));
});
},
openDelConfirm(name) {
- return this.$confirm(`此操作将删除 ${name}, 是否继续?`, '提示', {
- confirmButtonText: '确定',
- cancelButtonText: '取消',
+ return this.$confirm(this.$t('message.deleteMessage', { name }), this.$t('common.hint'), {
+ confirmButtonText: this.$t('common.ok'),
+ cancelButtonText: this.$t('common.cancel'),
type: 'warning',
});
},
@@ -642,7 +642,7 @@ export default {
})
.catch((error) => {
console.log(error);
- this.$message.error('查询失败,请尝试刷新页面');
+ this.$message.error(this.$t('message.queryFailure'));
});
},
},
diff --git a/hippo4j-ui/src/views/hippo4j/server/undertow/index.vue b/hippo4j-ui/src/views/hippo4j/server/undertow/index.vue
index bdf42073..840af455 100755
--- a/hippo4j-ui/src/views/hippo4j/server/undertow/index.vue
+++ b/hippo4j-ui/src/views/hippo4j/server/undertow/index.vue
@@ -3,7 +3,7 @@
- 搜索
+ {{ $t('common.query') }}
-
+
{{ scope.$index + 1 }}
-
+
{{ scope.row.identify }}
-
+
{{ scope.row.active }}
-
+
{{ scope.row.coreSize }}
-
+
{{ scope.row.maximumSize }}
-
+
{{ scope.row.queueType }}
-
+
{{ scope.row.queueCapacity }}
-
+
{{ scope.row.rejectedName }}
-
+
{{ scope.row.keepAliveTime }}
- 查看
-
- 编辑
-
+ {{ $t('common.detail') }}
+ {{ $t('common.edit') }}
@@ -108,81 +106,81 @@
width="1000px"
>
-
+
- 当前负载
+ {{ $t('threadPoolInstance.CurrentLoad') }}
{{ runTimeTemp.currentLoad }}
- 峰值负载
+ {{ $t('threadPoolInstance.PeakLoad') }}
{{ runTimeTemp.peakLoad }}
- 剩余内存
+ {{ $t('threadPoolInstance.RemainingMemory') }}
{{ runTimeTemp.freeMemory }}
- 内存占比
+ {{ $t('threadPoolInstance.MemoryRatio') }}
{{ runTimeTemp.memoryProportion }}
-
+
- 核心线程
+ {{ $t('threadPool.coreSize') }}
{{ runTimeTemp.coreSize }}
- 当前线程
+ {{ $t('threadPoolInstance.currentSize') }}
{{ runTimeTemp.poolSize }}
- 最大线程
+ {{ $t('threadPool.maximumSize') }}
{{ runTimeTemp.maximumSize }}
- 活跃线程
+ {{ $t('threadPoolInstance.activeSize') }}
{{ runTimeTemp.activeSize }}
- 同存最大线程
+ {{ $t('threadPoolInstance.largestSize') }}
{{ runTimeTemp.largestPoolSize }}
-
+
- 队列容量
+ {{ $t('threadPool.queueCapacity') }}
{{ runTimeTemp.queueCapacity }}
- 队列元素
+ {{ $t('threadPoolInstance.queueCount') }}
{{ runTimeTemp.queueSize }}
- 队列剩余容量
+ {{ $t('threadPoolInstance.queueRemainingCapacity') }}
{{ runTimeTemp.queueRemainingCapacity }}
- 阻塞队列
+ {{ $t('threadPoolInstance.queueType') }}
{{ runTimeTemp.queueType }}
-
+
- 任务总量
+ {{ $t('threadPoolInstance.totalTask') }}
{{ runTimeTemp.completedTaskCount }}
- 最后更新时间
+ {{ $t('threadPoolInstance.lastUpdateTime') }}
{{ runTimeTemp.clientLastRefreshTime }}
- 拒绝策略
+ {{ $t('threadPool.rejectedHandler') }}
{{ runTimeTemp.rejectedName }}
@@ -190,11 +188,11 @@
@@ -206,7 +204,7 @@
label-position="left"
label-width="110px"
>
-
+
-
+
-
+
-
+
@@ -362,11 +360,11 @@ export default {
},
fetchData() {
if (!this.listQuery.tenantId) {
- this.$message.warning('租户不允许为空');
+ this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('tenantManage.tenant') }));
return;
}
if (!this.listQuery.itemId) {
- this.$message.warning('项目不允许为空');
+ this.$message.warning(this.$t('message.emptyWarning', { name: this.$t('projectManage.item') }));
return;
}
this.listLoading = true;
@@ -484,7 +482,7 @@ export default {
if (valid) {
if (parseInt(this.temp.maximumSize) < parseInt(this.temp.coreSize)) {
this.$message({
- message: '最大线程必须大于等于核心线程',
+ message: this.$t('threadPool.threadsNumErrorTip'),
type: 'warning',
});
return;
@@ -492,7 +490,7 @@ export default {
const clientAddressList = [];
const tempData = {
corePoolSize: this.temp.coreSize,
- temId: this.temp.itemId,
+ itemId: this.temp.itemId,
tenantId: this.temp.tenantId,
maximumPoolSize: this.temp.maximumSize,
keepAliveTime: this.temp.keepAliveTime,
@@ -530,14 +528,14 @@ export default {
})
.catch((error) => {
console.log(error);
- this.$message.error('查询失败,请尝试刷新页面');
+ this.$message.error(this.$t('message.queryFailure'));
});
},
openDelConfirm(name) {
- return this.$confirm(`此操作将删除 ${name}, 是否继续?`, '提示', {
- confirmButtonText: '确定',
- cancelButtonText: '取消',
+ return this.$confirm(this.$t('message.deleteMessage', { name }), this.$t('common.hint'), {
+ confirmButtonText: this.$t('common.ok'),
+ cancelButtonText: this.$t('common.cancel'),
type: 'warning',
});
},
@@ -644,7 +642,7 @@ export default {
})
.catch((error) => {
console.log(error);
- this.$message.error('查询失败,请尝试刷新页面');
+ this.$message.error(this.$t('message.queryFailure'));
});
},
},