public class OpenSearchClient extends Object
| Modifier and Type | Field and Description |
|---|---|
protected org.apache.http.client.HttpClient |
httpClient |
protected String |
openSearchUrl |
| Modifier | Constructor and Description |
|---|---|
protected |
OpenSearchClient(String openSearchUrl,
org.apache.http.client.HttpClient httpClient) |
| Modifier and Type | Method and Description |
|---|---|
void |
emitDocument(String emitKey,
String routing,
Metadata metadata) |
JsonResponse |
postJson(String url,
String json) |
void |
writeBulkRequest(String id,
String routing,
StringWriter writer) |
void |
writeDoc(Metadata metadata,
StringWriter writer) |
protected final String openSearchUrl
protected final org.apache.http.client.HttpClient httpClient
protected OpenSearchClient(String openSearchUrl, org.apache.http.client.HttpClient httpClient)
public void emitDocument(String emitKey, String routing, Metadata metadata) throws IOException, TikaClientException
IOExceptionTikaClientExceptionpublic JsonResponse postJson(String url, String json) throws IOException
IOExceptionpublic void writeDoc(Metadata metadata, StringWriter writer) throws IOException
IOExceptionpublic void writeBulkRequest(String id, String routing, StringWriter writer) throws IOException
IOExceptionCopyright © 2007–2023 The Apache Software Foundation. All rights reserved.