-
- {{item.content}}...
+
+
{{$t('load_test.download_log_file')}}
@@ -14,17 +16,40 @@
name: "LogDetails",
data() {
return {
- logContent: null,
+ resource: [],
+ logContent: [],
result: {},
- id: ''
+ id: '',
+ page: 1,
+ pageCount: 1,
+ loading: false,
}
},
+
+ computed: {
+ disabled() {
+ return this.loading || this.page > this.pageCount;
+ }
+ },
+
methods: {
- initTableData() {
- this.result = this.$get("/performance/report/log/" + this.id).then(res => {
- this.logContent = res.data.data;
- }).catch(() => {
- this.logContent = null;
+ getResource() {
+ this.result = this.$get("/performance/report/log/resource/" + this.id, data => {
+ this.resource = data.data;
+ })
+ },
+ load(resourceId) {
+ if (this.loading || this.page > this.pageCount) return;
+ this.loading = true;
+ let url = "/performance/report/log/" + this.id + "/" + resourceId + "/" + this.page;
+ this.$get(url, res => {
+ let data = res.data;
+ this.pageCount = data.pageCount;
+ data.listObject.forEach(log => {
+ this.logContent.push(log);
+ })
+ this.page++;
+ this.loading = false;
})
},
downloadLogFile(item) {
@@ -53,16 +78,16 @@
},
watch: {
report: {
- handler(val){
+ handler(val) {
let status = val.status;
this.id = val.id;
if (status === "Completed") {
- this.initTableData();
+ this.getResource();
} else {
- this.logContent = null;
+ this.resource = [];
}
},
- deep:true
+ deep: true
}
},
props: ['report']
@@ -75,4 +100,16 @@
overflow: auto;
}
+ .infinite-list {
+ height: 500px;
+ padding: 0;
+ margin: 0;
+ list-style: none;
+ overflow: auto
+ }
+
+ .infinite-list-item {
+ overflow: hidden;
+ }
+
From 989c07280aca23eedbd84ec5f30eed4efadfb4f8 Mon Sep 17 00:00:00 2001
From: q4speed
Date: Tue, 2 Jun 2020 14:06:45 +0800
Subject: [PATCH 10/31] keepalive
---
frontend/src/business/components/api/test/model/JMX.js | 1 +
1 file changed, 1 insertion(+)
diff --git a/frontend/src/business/components/api/test/model/JMX.js b/frontend/src/business/components/api/test/model/JMX.js
index b34255f822..791ac9a0a1 100644
--- a/frontend/src/business/components/api/test/model/JMX.js
+++ b/frontend/src/business/components/api/test/model/JMX.js
@@ -231,6 +231,7 @@ export class HTTPSamplerProxy extends DefaultTestElement {
}
this.boolProp("HTTPSampler.follow_redirects", this.request.follow, true);
+ this.boolProp("HTTPSampler.use_keepalive", this.request.keepalive, true);
}
}
From 445d90c955e364364bd2339520a8b34cd6db42a6 Mon Sep 17 00:00:00 2001
From: chenjianxing
Date: Tue, 2 Jun 2020 14:09:24 +0800
Subject: [PATCH 11/31] =?UTF-8?q?=E6=80=A7=E8=83=BD=E6=B5=8B=E8=AF=95?=
=?UTF-8?q?=E5=8F=AA=E8=AF=BB=E9=A1=B5=E9=9D=A2?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../components/MsTableOperatorButton.vue | 9 +++----
.../components/PerformanceAdvancedConfig.vue | 26 +++++++++----------
.../components/PerformanceBasicConfig.vue | 15 ++++++++---
.../components/PerformancePressureConfig.vue | 20 ++++++++++++--
.../view/comonents/TestPlanTestCaseEdit.vue | 4 +--
.../comonents/test/PerformanceTestDetail.vue | 16 ++++++++----
.../comonents/test/PerformanceTestResult.vue | 22 +++++++++-------
7 files changed, 73 insertions(+), 39 deletions(-)
diff --git a/frontend/src/business/components/common/components/MsTableOperatorButton.vue b/frontend/src/business/components/common/components/MsTableOperatorButton.vue
index 8b03620d11..2e885e09b8 100644
--- a/frontend/src/business/components/common/components/MsTableOperatorButton.vue
+++ b/frontend/src/business/components/common/components/MsTableOperatorButton.vue
@@ -16,11 +16,6 @@
export default {
name: "MsTableOperatorButton",
components: {MsTipButton, MsTableButton},
- data() {
- return{
- disabled: false
- }
- },
props: {
icon: {
type: String,
@@ -33,6 +28,10 @@
tip: {
type: String
},
+ disabled: {
+ type: Boolean,
+ default: false
+ },
isTesterPermission: {
type: Boolean,
default: false
diff --git a/frontend/src/business/components/performance/test/components/PerformanceAdvancedConfig.vue b/frontend/src/business/components/performance/test/components/PerformanceAdvancedConfig.vue
index dcc1894a33..655817ea13 100644
--- a/frontend/src/business/components/performance/test/components/PerformanceAdvancedConfig.vue
+++ b/frontend/src/business/components/performance/test/components/PerformanceAdvancedConfig.vue
@@ -4,7 +4,7 @@
{{$t('load_test.domain_bind')}}
- {{$t('commons.add')}}
+ {{$t('commons.add')}}
@@ -19,7 +19,7 @@
-
@@ -77,7 +77,7 @@
{{$t('load_test.params')}}
- {{$t('commons.add')}}
+ {{$t('commons.add')}}
@@ -92,7 +92,7 @@
{{ row.value }}-->
-
@@ -154,7 +154,7 @@
{{$t('load_test.connect_timeout')}}
-
+
ms
@@ -169,7 +169,7 @@
{{$t('load_test.custom_http_code')}}
-
@@ -196,7 +196,7 @@
props: {
readOnly: {
type: Boolean,
- default: true
+ default: false
},
testId: String,
},
diff --git a/frontend/src/business/components/performance/test/components/PerformanceBasicConfig.vue b/frontend/src/business/components/performance/test/components/PerformanceBasicConfig.vue
index 15336c2b7d..8d3ecd1f60 100644
--- a/frontend/src/business/components/performance/test/components/PerformanceBasicConfig.vue
+++ b/frontend/src/business/components/performance/test/components/PerformanceBasicConfig.vue
@@ -10,6 +10,7 @@
:before-upload="beforeUpload"
:http-request="handleUpload"
:on-exceed="handleExceed"
+ :disabled="isReadOnly"
:file-list="fileList">
@@ -41,9 +42,9 @@
-
-
@@ -56,7 +57,15 @@
export default {
name: "PerformanceBasicConfig",
- props: ["testPlan"],
+ props: {
+ testPlan: {
+ type: Object
+ },
+ isReadOnly: {
+ type: Boolean,
+ default: false
+ }
+ },
data() {
return {
result: {},
diff --git a/frontend/src/business/components/performance/test/components/PerformancePressureConfig.vue b/frontend/src/business/components/performance/test/components/PerformancePressureConfig.vue
index 558057d6e0..ebc465b4ee 100644
--- a/frontend/src/business/components/performance/test/components/PerformancePressureConfig.vue
+++ b/frontend/src/business/components/performance/test/components/PerformancePressureConfig.vue
@@ -8,6 +8,7 @@
{{$t('load_test.select_resource_pool')}}