This closes Excluded Elasticsearch and Solr Auto Configuration from Registry
Excluding these configurations avoids unexpected runtime behavior when running Registry with the Apache Ranger plugin
@@ -22,7 +22,10 @@ import org.apache.nifi.registry.hook.Event;
import org.apache.nifi.registry.hook.EventType;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.SpringApplication;
+import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.SpringBootApplication;
+import org.springframework.boot.autoconfigure.elasticsearch.ElasticsearchRestClientAutoConfiguration;
+import org.springframework.boot.autoconfigure.solr.SolrAutoConfiguration;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.context.event.ApplicationReadyEvent;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
@@ -41,6 +44,12 @@ import java.util.Properties;
*
* WebMvcAutoConfiguration is excluded because our web app is using Jersey in place of SpringMVC
*/
+@EnableAutoConfiguration(
+ exclude = {
+ ElasticsearchRestClientAutoConfiguration.class,
+ SolrAutoConfiguration.class
+ }
+)
@SpringBootApplication
public class NiFiRegistryApiApplication extends SpringBootServletInitializer {
