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,
                OpenSearchEmitter.AttachmentStrategy attachmentStrategy,
                OpenSearchEmitter.UpdateStrategy updateStrategy,
                String embeddedFileFieldName) | 
| Modifier and Type | Method and Description | 
|---|---|
| void | emitDocument(String emitKey,
            List<Metadata> metadataList) | 
| void | emitDocuments(List<? extends EmitData> emitData) | 
| protected static String | metadataToJsonContainerInsert(Metadata metadata,
                             OpenSearchEmitter.AttachmentStrategy attachmentStrategy) | 
| protected static String | metadataToJsonEmbeddedInsert(Metadata metadata,
                            OpenSearchEmitter.AttachmentStrategy attachmentStrategy,
                            String emitKey,
                            String embeddedFileFieldName) | 
| JsonResponse | postJson(String url,
        String json) | 
protected final String openSearchUrl
protected final org.apache.http.client.HttpClient httpClient
protected OpenSearchClient(String openSearchUrl, org.apache.http.client.HttpClient httpClient, OpenSearchEmitter.AttachmentStrategy attachmentStrategy, OpenSearchEmitter.UpdateStrategy updateStrategy, String embeddedFileFieldName)
public void emitDocuments(List<? extends EmitData> emitData) throws IOException, TikaClientException
IOExceptionTikaClientExceptionpublic void emitDocument(String emitKey, List<Metadata> metadataList) throws IOException, TikaClientException
IOExceptionTikaClientExceptionprotected static String metadataToJsonContainerInsert(Metadata metadata, OpenSearchEmitter.AttachmentStrategy attachmentStrategy) throws IOException
IOExceptionprotected static String metadataToJsonEmbeddedInsert(Metadata metadata, OpenSearchEmitter.AttachmentStrategy attachmentStrategy, String emitKey, String embeddedFileFieldName) throws IOException
IOExceptionpublic JsonResponse postJson(String url, String json) throws IOException
IOExceptionCopyright © 2007–2022 The Apache Software Foundation. All rights reserved.