refactor(性能测试): 开启异步方法处理测试结果
This commit is contained in:
parent
d1b110d2db
commit
1e2b9fe2e8
|
@ -10,6 +10,7 @@ import org.springframework.boot.autoconfigure.quartz.QuartzAutoConfiguration;
|
|||
import org.springframework.boot.context.properties.EnableConfigurationProperties;
|
||||
import org.springframework.boot.web.servlet.ServletComponentScan;
|
||||
import org.springframework.context.annotation.PropertySource;
|
||||
import org.springframework.scheduling.annotation.EnableAsync;
|
||||
import org.springframework.scheduling.annotation.EnableScheduling;
|
||||
|
||||
@SpringBootApplication(exclude = {
|
||||
|
@ -23,6 +24,7 @@ import org.springframework.scheduling.annotation.EnableScheduling;
|
|||
JmeterProperties.class
|
||||
})
|
||||
@EnableScheduling
|
||||
@EnableAsync(proxyTargetClass = true)
|
||||
//@PropertySource(value = {"file:c:\\opt\\metersphere\\conf\\metersphere.properties"}, encoding = "UTF-8", ignoreResourceNotFound = true)
|
||||
@PropertySource(value = {"file:/opt/metersphere/conf/metersphere.properties"}, encoding = "UTF-8", ignoreResourceNotFound = true)
|
||||
public class Application {
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
package io.metersphere.commons.consumer;
|
||||
|
||||
import io.metersphere.base.domain.LoadTestReport;
|
||||
import org.springframework.scheduling.annotation.Async;
|
||||
|
||||
public interface LoadTestFinishEvent {
|
||||
@Async
|
||||
void execute(LoadTestReport loadTestReport);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue