Below is the pom.xml -> in eclipse facing with Xpack Plugin error. PLease guide.
try {
esClient = new PreBuiltXPackTransportClient(settings); //--XPACK plugin error
for (String h : hosts) {
esClient.addTransportAddress(new InetSocketTransportAddress(new InetSocketAddress(h,port)));
}
<dependency>
<groupId>org.elasticsearch</groupId>
<artifactId>elasticsearch</artifactId>
<version>${elasticsearch.version}</version>
</dependency>
<dependency>
<groupId>org.elasticsearch.client</groupId>
<artifactId>x-pack-transport</artifactId>
<version>${elasticsearch.version}</version>
</dependency>
<dependency>
<groupId>org.elasticsearch.client</groupId>
<artifactId>transport</artifactId>
<version>${elasticsearch.version}</version>
</dependency>