public class Chaos extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
ATTACK_ACTION_DELAY |
static String |
ATTACK_ACTION_FAULT |
| Modifier and Type | Method and Description |
|---|---|
void |
attack(AttackSchema attackInput,
AttackContext attackContext)
Attack the application.
|
void |
deregister()
Reset the application configuration.
|
static Chaos |
getInstance()
Get a Chaos instance.
|
void |
loadAttacks(List<AttackActionSchema> actionSchemas)
Set the application's attacks.
|
void |
register(AppConfig config)
Register the application and start the attacks loader.
|
void |
unloadAttacks()
Unload the application's loaded attacks.
|
public static final String ATTACK_ACTION_FAULT
public static final String ATTACK_ACTION_DELAY
public static Chaos getInstance()
public void register(AppConfig config) throws Exception
config - application configurationException - unable to register chaos middlewarepublic void deregister()
public void unloadAttacks()
public void loadAttacks(List<AttackActionSchema> actionSchemas)
actionSchemas - load attackspublic void attack(AttackSchema attackInput, AttackContext attackContext) throws Exception
attackInput - information about attack, if null loaded attacks will be
consideredattackContext - context of the attack (e.g url)Exception - throws exception if fault attack was performedCopyright © 2020. All rights reserved.