This has been in flux a bit lately but the last time I checked you had to intentionally load plugins by adding something like this to your test: /** * Enable plugin loading. */ @Override protected Settings nodeSettings(int nodeOrdinal) { return ImmutableSettings.builder().put(super.nodeSettings(nodeOrdinal)) .put("plugins." + PluginsService.LOAD_PLUGIN_FROM_CLASSPATH, true).build(); }
I imagine you could always set that to false. I believe it'd be important to add this annotation to your test though: @ElasticsearchIntegrationTest.ClusterScope(scope = ElasticsearchIntegrationTest.Scope.SUITE, transportClientRatio = 0.0) so that the cluster you build without your plugin doesn't get reused for other tests that need your plugin. Nik On Mon, Nov 3, 2014 at 12:50 PM, Laurent T. <lau.thou...@gmail.com> wrote: > Hi, > > I have an ES plugin that basically intercepts POST requests on a specific > path and builds ES queries depending on the post data before executing > these and returning a result. > I have some unit tests that create a local node to tests the queries. My > problem is that it loads my plugin which I do not want. > > Is there any way I can avoid that ? Perhaps with some specific settings ? > > Here's how I'm currently getting the test es client: > > NodeBuilder.nodeBuilder().local(true).node().client() > > > The reason I do not want it to load the plugin is that it creates two > instances of the plugin: one in the tests and one in the local node. > > Thanks > Regards, > > Laurent > > -- > You received this message because you are subscribed to the Google Groups > "elasticsearch" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to elasticsearch+unsubscr...@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/elasticsearch/57bbfb19-341c-4d39-9c90-218596406b75%40googlegroups.com > <https://groups.google.com/d/msgid/elasticsearch/57bbfb19-341c-4d39-9c90-218596406b75%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "elasticsearch" group. To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/elasticsearch/CAPmjWd2BeV9LOHyxLGcs2D5xP9axHh0tPE-X%2B0b%3DDTb%3D6z8_1A%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.