# sonar.web.javaAdditionalOpts=-javaagent:/path/to/byteman-3.0.10/lib/byteman.jar=script:/path/to/user_indexer.btm,boot:/path/to/byteman-3.0.10/lib/byteman.jar # sonar.search.recovery.delayInMs=10000 # sonar.search.recovery.minAgeInMs=30000 RULE make indexing of users silently fail CLASS org.sonar.server.user.index.UserIndexer METHOD postCommit COMPILE AT ENTRY BIND logins:Collection = $logins IF logins.contains("error") DO RETURN ENDRULE RULE make indexing of users fail CLASS org.sonar.server.user.index.UserIndexer METHOD postCommit COMPILE AT ENTRY BIND logins:Collection = $logins IF logins.contains("crash") DO THROW new RuntimeException("Fail to index users to Elasticsearch because a user 'crash' has been given") ENDRULE