Marvel: Fix compilation issues in tests
Original commit: elastic/x-pack-elasticsearch@9ffc4c501b
This commit is contained in:
parent
7147354525
commit
4e1d44110b
|
@ -45,7 +45,7 @@ public class MarvelPlugin extends Plugin {
|
|||
public static final String ENABLED = NAME + ".enabled";
|
||||
public static final Setting<String> INDEX_MARVEL_VERSION_SETTING = new Setting<>("index.marvel.plugin.version", "", Function.identity(), false, Setting.Scope.INDEX);
|
||||
public static final Setting<String> INDEX_MARVEL_TEMPLATE_VERSION_SETTING = new Setting<>("index.marvel.template.version", "", Function.identity(), false, Setting.Scope.INDEX);
|
||||
private static final String TRIBE_NAME_SETTING = "tribe.name";
|
||||
public static final String TRIBE_NAME_SETTING = "tribe.name";
|
||||
|
||||
private final Settings settings;
|
||||
private final boolean enabled;
|
||||
|
|
|
@ -14,7 +14,6 @@ import org.elasticsearch.marvel.shield.MarvelShieldIntegration;
|
|||
import org.elasticsearch.marvel.test.MarvelIntegTestCase;
|
||||
import org.elasticsearch.plugins.PluginInfo;
|
||||
import org.elasticsearch.test.ESIntegTestCase.ClusterScope;
|
||||
import org.elasticsearch.tribe.TribeService;
|
||||
import org.elasticsearch.xpack.XPackPlugin;
|
||||
|
||||
import static org.elasticsearch.test.ESIntegTestCase.Scope.TEST;
|
||||
|
@ -43,14 +42,14 @@ public class MarvelPluginTests extends MarvelIntegTestCase {
|
|||
}
|
||||
|
||||
public void testMarvelEnabledOnTribeNode() {
|
||||
internalCluster().startNode(Settings.builder().put(MarvelPlugin.ENABLED, true).put(TribeService.TRIBE_NAME, "t1").build());
|
||||
internalCluster().startNode(Settings.builder().put(MarvelPlugin.ENABLED, true).put(MarvelPlugin.TRIBE_NAME_SETTING, "t1").build());
|
||||
assertPluginIsLoaded();
|
||||
assertServiceIsBound(AgentService.class);
|
||||
assertServiceIsBound(MarvelShieldIntegration.class);
|
||||
}
|
||||
|
||||
public void testMarvelDisabledOnTribeNode() {
|
||||
internalCluster().startNode(Settings.builder().put(TribeService.TRIBE_NAME, "t1").build());
|
||||
internalCluster().startNode(Settings.builder().put(MarvelPlugin.TRIBE_NAME_SETTING, "t1").build());
|
||||
assertPluginIsLoaded();
|
||||
assertServiceIsNotBound(AgentService.class);
|
||||
assertServiceIsBound(MarvelShieldIntegration.class);
|
||||
|
|
Loading…
Reference in New Issue