diff --git a/backend/src/main/java/io/metersphere/base/domain/LoadTestReport.java b/backend/src/main/java/io/metersphere/base/domain/LoadTestReport.java index b4aa2228f0..fa183b844a 100644 --- a/backend/src/main/java/io/metersphere/base/domain/LoadTestReport.java +++ b/backend/src/main/java/io/metersphere/base/domain/LoadTestReport.java @@ -33,5 +33,11 @@ public class LoadTestReport implements Serializable { private String testName; + private Long testStartTime; + + private Long testEndTime; + + private Long testDuration; + private static final long serialVersionUID = 1L; } \ No newline at end of file diff --git a/backend/src/main/java/io/metersphere/base/domain/LoadTestReportExample.java b/backend/src/main/java/io/metersphere/base/domain/LoadTestReportExample.java index fa2c691f6d..d3bb349f3c 100644 --- a/backend/src/main/java/io/metersphere/base/domain/LoadTestReportExample.java +++ b/backend/src/main/java/io/metersphere/base/domain/LoadTestReportExample.java @@ -1063,6 +1063,186 @@ public class LoadTestReportExample { addCriterion("test_name not between", value1, value2, "testName"); return (Criteria) this; } + + public Criteria andTestStartTimeIsNull() { + addCriterion("test_start_time is null"); + return (Criteria) this; + } + + public Criteria andTestStartTimeIsNotNull() { + addCriterion("test_start_time is not null"); + return (Criteria) this; + } + + public Criteria andTestStartTimeEqualTo(Long value) { + addCriterion("test_start_time =", value, "testStartTime"); + return (Criteria) this; + } + + public Criteria andTestStartTimeNotEqualTo(Long value) { + addCriterion("test_start_time <>", value, "testStartTime"); + return (Criteria) this; + } + + public Criteria andTestStartTimeGreaterThan(Long value) { + addCriterion("test_start_time >", value, "testStartTime"); + return (Criteria) this; + } + + public Criteria andTestStartTimeGreaterThanOrEqualTo(Long value) { + addCriterion("test_start_time >=", value, "testStartTime"); + return (Criteria) this; + } + + public Criteria andTestStartTimeLessThan(Long value) { + addCriterion("test_start_time <", value, "testStartTime"); + return (Criteria) this; + } + + public Criteria andTestStartTimeLessThanOrEqualTo(Long value) { + addCriterion("test_start_time <=", value, "testStartTime"); + return (Criteria) this; + } + + public Criteria andTestStartTimeIn(List values) { + addCriterion("test_start_time in", values, "testStartTime"); + return (Criteria) this; + } + + public Criteria andTestStartTimeNotIn(List values) { + addCriterion("test_start_time not in", values, "testStartTime"); + return (Criteria) this; + } + + public Criteria andTestStartTimeBetween(Long value1, Long value2) { + addCriterion("test_start_time between", value1, value2, "testStartTime"); + return (Criteria) this; + } + + public Criteria andTestStartTimeNotBetween(Long value1, Long value2) { + addCriterion("test_start_time not between", value1, value2, "testStartTime"); + return (Criteria) this; + } + + public Criteria andTestEndTimeIsNull() { + addCriterion("test_end_time is null"); + return (Criteria) this; + } + + public Criteria andTestEndTimeIsNotNull() { + addCriterion("test_end_time is not null"); + return (Criteria) this; + } + + public Criteria andTestEndTimeEqualTo(Long value) { + addCriterion("test_end_time =", value, "testEndTime"); + return (Criteria) this; + } + + public Criteria andTestEndTimeNotEqualTo(Long value) { + addCriterion("test_end_time <>", value, "testEndTime"); + return (Criteria) this; + } + + public Criteria andTestEndTimeGreaterThan(Long value) { + addCriterion("test_end_time >", value, "testEndTime"); + return (Criteria) this; + } + + public Criteria andTestEndTimeGreaterThanOrEqualTo(Long value) { + addCriterion("test_end_time >=", value, "testEndTime"); + return (Criteria) this; + } + + public Criteria andTestEndTimeLessThan(Long value) { + addCriterion("test_end_time <", value, "testEndTime"); + return (Criteria) this; + } + + public Criteria andTestEndTimeLessThanOrEqualTo(Long value) { + addCriterion("test_end_time <=", value, "testEndTime"); + return (Criteria) this; + } + + public Criteria andTestEndTimeIn(List values) { + addCriterion("test_end_time in", values, "testEndTime"); + return (Criteria) this; + } + + public Criteria andTestEndTimeNotIn(List values) { + addCriterion("test_end_time not in", values, "testEndTime"); + return (Criteria) this; + } + + public Criteria andTestEndTimeBetween(Long value1, Long value2) { + addCriterion("test_end_time between", value1, value2, "testEndTime"); + return (Criteria) this; + } + + public Criteria andTestEndTimeNotBetween(Long value1, Long value2) { + addCriterion("test_end_time not between", value1, value2, "testEndTime"); + return (Criteria) this; + } + + public Criteria andTestDurationIsNull() { + addCriterion("test_duration is null"); + return (Criteria) this; + } + + public Criteria andTestDurationIsNotNull() { + addCriterion("test_duration is not null"); + return (Criteria) this; + } + + public Criteria andTestDurationEqualTo(Long value) { + addCriterion("test_duration =", value, "testDuration"); + return (Criteria) this; + } + + public Criteria andTestDurationNotEqualTo(Long value) { + addCriterion("test_duration <>", value, "testDuration"); + return (Criteria) this; + } + + public Criteria andTestDurationGreaterThan(Long value) { + addCriterion("test_duration >", value, "testDuration"); + return (Criteria) this; + } + + public Criteria andTestDurationGreaterThanOrEqualTo(Long value) { + addCriterion("test_duration >=", value, "testDuration"); + return (Criteria) this; + } + + public Criteria andTestDurationLessThan(Long value) { + addCriterion("test_duration <", value, "testDuration"); + return (Criteria) this; + } + + public Criteria andTestDurationLessThanOrEqualTo(Long value) { + addCriterion("test_duration <=", value, "testDuration"); + return (Criteria) this; + } + + public Criteria andTestDurationIn(List values) { + addCriterion("test_duration in", values, "testDuration"); + return (Criteria) this; + } + + public Criteria andTestDurationNotIn(List values) { + addCriterion("test_duration not in", values, "testDuration"); + return (Criteria) this; + } + + public Criteria andTestDurationBetween(Long value1, Long value2) { + addCriterion("test_duration between", value1, value2, "testDuration"); + return (Criteria) this; + } + + public Criteria andTestDurationNotBetween(Long value1, Long value2) { + addCriterion("test_duration not between", value1, value2, "testDuration"); + return (Criteria) this; + } } public static class Criteria extends GeneratedCriteria { diff --git a/backend/src/main/java/io/metersphere/base/mapper/LoadTestReportMapper.xml b/backend/src/main/java/io/metersphere/base/mapper/LoadTestReportMapper.xml index 469bb62a95..89d05f97bc 100644 --- a/backend/src/main/java/io/metersphere/base/mapper/LoadTestReportMapper.xml +++ b/backend/src/main/java/io/metersphere/base/mapper/LoadTestReportMapper.xml @@ -16,6 +16,9 @@ + + + @@ -82,7 +85,8 @@ id, test_id, `name`, create_time, update_time, `status`, user_id, trigger_mode, file_id, - max_users, avg_response_time, tps, project_id, test_name + max_users, avg_response_time, tps, project_id, test_name, test_start_time, test_end_time, + test_duration description, load_configuration, jmx_content @@ -140,13 +144,15 @@ create_time, update_time, `status`, user_id, trigger_mode, file_id, max_users, avg_response_time, tps, - project_id, test_name, description, + project_id, test_name, test_start_time, + test_end_time, test_duration, description, load_configuration, jmx_content) values (#{id,jdbcType=VARCHAR}, #{testId,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{createTime,jdbcType=BIGINT}, #{updateTime,jdbcType=BIGINT}, #{status,jdbcType=VARCHAR}, #{userId,jdbcType=VARCHAR}, #{triggerMode,jdbcType=VARCHAR}, #{fileId,jdbcType=VARCHAR}, #{maxUsers,jdbcType=VARCHAR}, #{avgResponseTime,jdbcType=VARCHAR}, #{tps,jdbcType=VARCHAR}, - #{projectId,jdbcType=VARCHAR}, #{testName,jdbcType=VARCHAR}, #{description,jdbcType=LONGVARCHAR}, + #{projectId,jdbcType=VARCHAR}, #{testName,jdbcType=VARCHAR}, #{testStartTime,jdbcType=BIGINT}, + #{testEndTime,jdbcType=BIGINT}, #{testDuration,jdbcType=BIGINT}, #{description,jdbcType=LONGVARCHAR}, #{loadConfiguration,jdbcType=LONGVARCHAR}, #{jmxContent,jdbcType=LONGVARCHAR}) @@ -194,6 +200,15 @@ test_name, + + test_start_time, + + + test_end_time, + + + test_duration, + description, @@ -247,6 +262,15 @@ #{testName,jdbcType=VARCHAR}, + + #{testStartTime,jdbcType=BIGINT}, + + + #{testEndTime,jdbcType=BIGINT}, + + + #{testDuration,jdbcType=BIGINT}, + #{description,jdbcType=LONGVARCHAR}, @@ -309,6 +333,15 @@ test_name = #{record.testName,jdbcType=VARCHAR}, + + test_start_time = #{record.testStartTime,jdbcType=BIGINT}, + + + test_end_time = #{record.testEndTime,jdbcType=BIGINT}, + + + test_duration = #{record.testDuration,jdbcType=BIGINT}, + description = #{record.description,jdbcType=LONGVARCHAR}, @@ -339,6 +372,9 @@ tps = #{record.tps,jdbcType=VARCHAR}, project_id = #{record.projectId,jdbcType=VARCHAR}, test_name = #{record.testName,jdbcType=VARCHAR}, + test_start_time = #{record.testStartTime,jdbcType=BIGINT}, + test_end_time = #{record.testEndTime,jdbcType=BIGINT}, + test_duration = #{record.testDuration,jdbcType=BIGINT}, description = #{record.description,jdbcType=LONGVARCHAR}, load_configuration = #{record.loadConfiguration,jdbcType=LONGVARCHAR}, jmx_content = #{record.jmxContent,jdbcType=LONGVARCHAR} @@ -361,7 +397,10 @@ avg_response_time = #{record.avgResponseTime,jdbcType=VARCHAR}, tps = #{record.tps,jdbcType=VARCHAR}, project_id = #{record.projectId,jdbcType=VARCHAR}, - test_name = #{record.testName,jdbcType=VARCHAR} + test_name = #{record.testName,jdbcType=VARCHAR}, + test_start_time = #{record.testStartTime,jdbcType=BIGINT}, + test_end_time = #{record.testEndTime,jdbcType=BIGINT}, + test_duration = #{record.testDuration,jdbcType=BIGINT} @@ -408,6 +447,15 @@ test_name = #{testName,jdbcType=VARCHAR}, + + test_start_time = #{testStartTime,jdbcType=BIGINT}, + + + test_end_time = #{testEndTime,jdbcType=BIGINT}, + + + test_duration = #{testDuration,jdbcType=BIGINT}, + description = #{description,jdbcType=LONGVARCHAR}, @@ -435,6 +483,9 @@ tps = #{tps,jdbcType=VARCHAR}, project_id = #{projectId,jdbcType=VARCHAR}, test_name = #{testName,jdbcType=VARCHAR}, + test_start_time = #{testStartTime,jdbcType=BIGINT}, + test_end_time = #{testEndTime,jdbcType=BIGINT}, + test_duration = #{testDuration,jdbcType=BIGINT}, description = #{description,jdbcType=LONGVARCHAR}, load_configuration = #{loadConfiguration,jdbcType=LONGVARCHAR}, jmx_content = #{jmxContent,jdbcType=LONGVARCHAR} @@ -454,7 +505,10 @@ avg_response_time = #{avgResponseTime,jdbcType=VARCHAR}, tps = #{tps,jdbcType=VARCHAR}, project_id = #{projectId,jdbcType=VARCHAR}, - test_name = #{testName,jdbcType=VARCHAR} + test_name = #{testName,jdbcType=VARCHAR}, + test_start_time = #{testStartTime,jdbcType=BIGINT}, + test_end_time = #{testEndTime,jdbcType=BIGINT}, + test_duration = #{testDuration,jdbcType=BIGINT} where id = #{id,jdbcType=VARCHAR} \ No newline at end of file diff --git a/backend/src/main/java/io/metersphere/base/mapper/ext/ExtLoadTestReportMapper.xml b/backend/src/main/java/io/metersphere/base/mapper/ext/ExtLoadTestReportMapper.xml index a4e24dccff..73b6799ea8 100644 --- a/backend/src/main/java/io/metersphere/base/mapper/ext/ExtLoadTestReportMapper.xml +++ b/backend/src/main/java/io/metersphere/base/mapper/ext/ExtLoadTestReportMapper.xml @@ -66,7 +66,8 @@