Open
Conversation
- Add tika-pipes-elasticsearch plugin with ElasticsearchClient, ElasticsearchEmitter, and PF4J plugin wiring. - Add Elasticsearch integration tests with Testcontainers. - Refactor shared logic in OpenSearchClient. Co-authored-by: Cursor <cursoragent@cursor.com>
Adds an Elasticsearch-compatible emitter and pipes reporter as a new tika-pipes plugin, avoiding use of the trademarked "Elasticsearch" name in class and package identifiers (plugin id: es-emitter). Key changes: - New plugin: tika-pipes-elasticsearch with ESEmitter, ESPipesReporter, ESEmitterConfig, ESEmitterFactory, ESPipesPlugin; all classes under org.apache.tika.pipes.{emitter,reporter,plugin}.es packages - ESClient talks directly to the _bulk REST endpoint using Apache HttpClient (ASL v2), avoiding the SSPL-licensed ES Java client - Reporter writes per-document parse status (PARSE_SUCCESS, PARSE_SUCCESS_WITH_EXCEPTION, EMIT_SUCCESS, OOM/TIMEOUT) to a dedicated ES index, mirroring the OpenSearch reporter - HttpClientFactory: add verifySsl flag (default false preserves existing trust-all behaviour); when true uses JVM default trust store and hostname verification; copy() propagates the flag - VectorSerializer: switch to BIG_ENDIAN byte order to match ES 9.3+ dense_vector base64 format (big-endian IEEE 754 float32) - Security: fix JSON field injection in ESClient.isValidJson by using JsonParser with explicit trailing-token check; override ESEmitterConfig.toString() to redact apiKey from logs - Integration tests: 6 Docker-based tests (Testcontainers, ES 9.3.0) covering basic FS→ES pipeline, reporter validation, RMETA/PARENT_CHILD attachment strategies, upsert, and kNN vector search; vector test uses base64 on ES >= 9.3, falls back to float-array bulk indexing on older versions - Documentation: ES emitter and reporter sections in pipes/index.adoc with configuration tables and SSL warning Co-authored-by: Cursor <cursoragent@cursor.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Thanks for your contribution to Apache Tika! Your help is appreciated!
Before opening the pull request, please verify that
TIKA-XXXX)[TIKA-XXXX] Issue or pull request title)./mvnw clean testmainbranch. If there are conflicts, please try to rebase the pull request branch on top of a freshly pulledmainbranchtika-bom/pom.xml.We will be able to faster integrate your pull request if these conditions are met. If you have any questions how to fix your problem or about using Tika in general, please sign up for the Tika mailing list. Thanks!