Java API
This section describes the Java APIs supported by Elasticsearch. All elasticsearch operations are performed using the client object. Essentially, all operations are performed in parallel.
In addition, operations in the client are likely to accumulate and execute through bulk.
Maven
Elasticsearch is hosted in the MAVEN repository. For example, you can define the latest version in Pom.xml.
<dependency> <groupId>org.elasticsearch</groupId> <artifactId>elasticsearch</artifactId> <version>${es.version}</version></dependency>
Deploying in the JBoss EAP6 module
The Elasticsearch and Lucene classes must be in the same JBoss module, and you should define them as follows module.xml
.
<?xml version= "1.0" encoding= "UTF-8"?><ModuleName="Org.elasticsearch" ><Resources><!--Elasticsearch--<Resource-rootPath="Elasticsearch-1.4.1.jar"/><!--Lucene--<Resource-rootPath="Lucene-core-4.10.2.jar"/><Resource-rootPath="Lucene-analyzers-common-4.10.2.jar"/><Resource-rootPath="Lucene-queries-4.10.2.jar"/><Resource-rootPath="Lucene-memory-4.10.2.jar"/><Resource-rootPath="Lucene-highlighter-4.10.2.jar"/><Resource-rootPath="Lucene-queryparser-4.10.2.jar"/><Resource-rootPath="Lucene-sandbox-4.10.2.jar"/><Resource-rootPath="Lucene-suggest-4.10.2.jar"/><Resource-rootPath="Lucene-misc-4.10.2.jar"/><Resource-rootPath="Lucene-join-4.10.2.jar"/><Resource-rootPath="Lucene-grouping-4.10.2.jar"/><Resource-rootPath="Lucene-spatial-4.10.2.jar"/><Resource-rootPath="Lucene-expressions-4.10.2.jar"/><!--Insert Other resources here--</Resources><Dependencies><ModuleName="Sun.jdk"export="True" ><Imports><include path= "Sun/misc/Unsafe"/ > </imports> </module> <module Name= "org.apache.log4j"/> < Module name= "org.apache.commons.logging"/> <module name=" Javax.api "/> </dependencies> </MODULE>
Elasticsearch Chinese API (i)