Support Apache Tika 4.0.0 (tika-parsers-standard-package no longer publishes a JAR, only a POM aggregator)
Expected Behavior
spring-ai-tika-document-reader should work with Apache Tika 4.x (released 2026-08-22), so that projects can upgrade
tika-core/tika-langdetect-optimaize/tika-parsers-standard-package to 4.0.0 without runtime errors or broken dependency resolution.
Current Behavior
Overriding tika-core and tika-langdetect-optimaize to 4.0.0 alone compiles, but fails at runtime with NoSuchMethodError / AbstractMethodError (e.g. in
org.gagravarr.tika.OggDetector, TesseractOCRParser), because tika-parsers-standard-package and its submodules, pulled in transitively by spring-ai-tika-document-reader, stay on
3.3.1 → mixed-version classpath.
Trying to fix that by also overriding tika-parsers-standard-package to 4.0.0 fails dependency resolution entirely:
Could not find artifact org.apache.tika:tika-parsers-standard-package:jar:4.0.0 in central
Checking Maven Central confirms tika-parsers-standard-package:4.0.0 only publishes a .pom (packaging pom), no .jar. Tika 4 reorganized its parser modules (pf4j-based plugins, per
the migration guide), so the "standard package" bundle no longer exists as a single JAR the way spring-ai-tika-document-reader currently depends on it. This can't be worked around from a
consuming project via dependency overrides alone; it likely requires spring-ai-tika-document-reader to depend on the new Tika 4 parser module structure directly.
Context
We use TikaDocumentReader for document ingestion (PDF/Office files) in a RAG pipeline and wanted to evaluate upgrading to Tika 4.0.0 for its newer parsers/fixes. We're currently blocked
on Spring AI's supported Tika version (3.3.1) until this is resolved.
- Spring AI: 2.0.1
- Java: 25
- No workaround found other than staying on Tika 3.x.
References:
- https://tika.apache.org/docs/4.0.x/migration-to-4x/index.html
- https://repo1.maven.org/maven2/org/apache/tika/tika-parsers-standard-package/4.0.0/
Happy to help testing a fix if useful.
Source: spring-projects/spring-ai