合并注释是否可以改善性能并增加Spring上下文的负载

时间:2018-12-05 12:42:45

标签: performance spring-boot

我已经创建了这个注释,并且在每个资源测试和服务测试中都使用了它。这样是否可以确保所有测试用例仅使用一个spring上下文?

@inherited
@documented
@target(TYPE)
@retention(RUNTIME)
@SpringBootTest(webEnvironment = RANDOM_PORT)
@AutoConfigureWebTestClient
@AutoConfigureWireMock(port = 8989)
public @interface ConnectorTest {

}

此外,我的服务测试中不需要@AutoConfigureWebTestClient。因此,添加更多的自动配置会影响性能吗?

0 个答案:

没有答案