Merge remote-tracking branch 'origin/master' into master
This commit is contained in:
commit
dd2c688a23
|
@ -141,6 +141,7 @@ public class APIBackendListenerClient extends AbstractBackendListenerClient impl
|
||||||
requestResult.setBody(result.getSamplerData());
|
requestResult.setBody(result.getSamplerData());
|
||||||
requestResult.setHeaders(result.getRequestHeaders());
|
requestResult.setHeaders(result.getRequestHeaders());
|
||||||
requestResult.setRequestSize(result.getSentBytes());
|
requestResult.setRequestSize(result.getSentBytes());
|
||||||
|
requestResult.setStartTime(result.getStartTime());
|
||||||
requestResult.setTotalAssertions(result.getAssertionResults().length);
|
requestResult.setTotalAssertions(result.getAssertionResults().length);
|
||||||
requestResult.setSuccess(result.isSuccessful());
|
requestResult.setSuccess(result.isSuccessful());
|
||||||
requestResult.setError(result.getErrorCount());
|
requestResult.setError(result.getErrorCount());
|
||||||
|
|
|
@ -16,6 +16,8 @@ public class RequestResult {
|
||||||
|
|
||||||
private long requestSize;
|
private long requestSize;
|
||||||
|
|
||||||
|
private long startTime;
|
||||||
|
|
||||||
private int error;
|
private int error;
|
||||||
|
|
||||||
private boolean success;
|
private boolean success;
|
||||||
|
|
|
@ -2,10 +2,13 @@
|
||||||
<div class="request-result">
|
<div class="request-result">
|
||||||
<div @click="active">
|
<div @click="active">
|
||||||
<el-row :gutter="10" type="flex" align="middle" class="info">
|
<el-row :gutter="10" type="flex" align="middle" class="info">
|
||||||
<el-col :span="16">
|
<el-col :span="12">
|
||||||
<i class="icon el-icon-arrow-right" :class="{'is-active': isActive}"/>
|
<i class="icon el-icon-arrow-right" :class="{'is-active': isActive}"/>
|
||||||
{{scenarioName}}
|
{{scenarioName}}
|
||||||
</el-col>
|
</el-col>
|
||||||
|
<el-col :span="4">
|
||||||
|
{{$t('api_report.start_time')}}
|
||||||
|
</el-col>
|
||||||
<el-col :span="2">
|
<el-col :span="2">
|
||||||
{{$t('api_report.response_time')}}
|
{{$t('api_report.response_time')}}
|
||||||
</el-col>
|
</el-col>
|
||||||
|
@ -20,17 +23,20 @@
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
<el-row :gutter="10" type="flex" align="middle" class="info">
|
<el-row :gutter="10" type="flex" align="middle" class="info">
|
||||||
<el-col :span="4">
|
<el-col :span="2">
|
||||||
<div class="method">
|
<div class="method">
|
||||||
{{request.method}}
|
{{request.method}}
|
||||||
</div>
|
</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="12">
|
<el-col :span="10">
|
||||||
<div class="name">{{request.name}}</div>
|
<div class="name">{{request.name}}</div>
|
||||||
<el-tooltip effect="dark" :content="request.url" placement="bottom" :open-delay="800">
|
<el-tooltip effect="dark" :content="request.url" placement="bottom" :open-delay="800">
|
||||||
<div class="url">{{request.url}}</div>
|
<div class="url">{{request.url}}</div>
|
||||||
</el-tooltip>
|
</el-tooltip>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
<el-col :span="4">
|
||||||
|
{{request.startTime | timestampFormatDate(true) }}
|
||||||
|
</el-col>
|
||||||
<el-col :span="2">
|
<el-col :span="2">
|
||||||
<div class="time">
|
<div class="time">
|
||||||
{{request.responseResult.responseTime}}
|
{{request.responseResult.responseTime}}
|
||||||
|
|
|
@ -10,7 +10,7 @@ const options = function (value, array) {
|
||||||
return value;
|
return value;
|
||||||
};
|
};
|
||||||
|
|
||||||
const timestampFormatDate = function (timestamp) {
|
const timestampFormatDate = function (timestamp, showMs) {
|
||||||
if (!timestamp) {
|
if (!timestamp) {
|
||||||
return timestamp
|
return timestamp
|
||||||
}
|
}
|
||||||
|
@ -34,7 +34,14 @@ const timestampFormatDate = function (timestamp) {
|
||||||
let s = date.getSeconds();
|
let s = date.getSeconds();
|
||||||
s = s < 10 ? ('0' + s) : s;
|
s = s < 10 ? ('0' + s) : s;
|
||||||
|
|
||||||
return y + '-' + MM + '-' + d + ' ' + h + ':' + m + ':' + s
|
let format = y + '-' + MM + '-' + d + ' ' + h + ':' + m + ':' + s;
|
||||||
|
|
||||||
|
if (showMs === true) {
|
||||||
|
let ms = date.getMilliseconds();
|
||||||
|
format += ':' + ms
|
||||||
|
}
|
||||||
|
|
||||||
|
return format
|
||||||
};
|
};
|
||||||
|
|
||||||
const filters = {
|
const filters = {
|
||||||
|
|
|
@ -598,6 +598,7 @@ export default {
|
||||||
scenario_name: "Scenario name",
|
scenario_name: "Scenario name",
|
||||||
response_time: "Response time(ms)",
|
response_time: "Response time(ms)",
|
||||||
latency: "Latency",
|
latency: "Latency",
|
||||||
|
start_time: "Start Time",
|
||||||
request_size: "Request Size",
|
request_size: "Request Size",
|
||||||
response_size: "Response Size",
|
response_size: "Response Size",
|
||||||
response_code: "Response Code",
|
response_code: "Response Code",
|
||||||
|
|
|
@ -598,6 +598,7 @@ export default {
|
||||||
delete_confirm: '确认删除报告: ',
|
delete_confirm: '确认删除报告: ',
|
||||||
delete_batch_confirm: '确认批量删除报告',
|
delete_batch_confirm: '确认批量删除报告',
|
||||||
scenario_name: "场景名称",
|
scenario_name: "场景名称",
|
||||||
|
start_time: "开始时间",
|
||||||
response_time: "响应时间(ms)",
|
response_time: "响应时间(ms)",
|
||||||
latency: "网络延迟",
|
latency: "网络延迟",
|
||||||
request_size: "请求大小",
|
request_size: "请求大小",
|
||||||
|
|
|
@ -598,6 +598,7 @@ export default {
|
||||||
delete_confirm: '確認刪除報告: ',
|
delete_confirm: '確認刪除報告: ',
|
||||||
delete_batch_confirm: '確認批量刪除報告',
|
delete_batch_confirm: '確認批量刪除報告',
|
||||||
scenario_name: "場景名稱",
|
scenario_name: "場景名稱",
|
||||||
|
start_time: "開始時間",
|
||||||
response_time: "響應時間(ms)",
|
response_time: "響應時間(ms)",
|
||||||
latency: "網絡延遲",
|
latency: "網絡延遲",
|
||||||
request_size: "請求大小",
|
request_size: "請求大小",
|
||||||
|
|
Loading…
Reference in New Issue