我使用的是Springboot2.3.1版本和chaos monkey,它在latencyActive和exceptionsActive上运行良好。
<dependency>
<groupId>de.codecentric</groupId>
<artifactId>chaos-monkey-spring-boot</artifactId>
<version>2.2.0</version>
</dependency>在两次攻击失败后
终止应用程序
chaos.monkey.assaults.killApplicationActive=true
chaos.monkey.assaults.level=3内存
chaos.monkey.assaults.memoryActive=true
chaos.monkey.assaults.memoryMillisecondsHoldFilledMemory=90000
chaos.monkey.assaults.memoryMillisecondsWaitNextIncrease=1000
chaos.monkey.assaults.memoryFillIncrementFraction=90.15
chaos.monkey.assaults.memoryFillTargetFraction=90.25发布于 2020-12-25 06:05:26
App kill和memory kill攻击需要将属性runtimeAssaultCronExpression设置为有效的cron表达式,如“*”。默认情况下,它被设置为"OFF“
请参阅文档:https://codecentric.github.io/chaos-monkey-spring-boot/2.2.0/#_appkiller_assault
发布于 2021-01-15 22:43:31
使用"chaos.monkey.assaults.runtime.scope.assault.cron.expression“的属性值作为cron表达式,如*/1 *?或任何有效的cron表达式,以在计划上启用混沌猴子运行时攻击。
否则使用属性值为OFF (也是默认值)
链接:https://codecentric.github.io/chaos-monkey-spring-boot/2.1.0/#configuration https://www.programmersought.com/article/11861551911/
https://stackoverflow.com/questions/62803738
复制相似问题