On Thu, 27 Aug 2015, Mikhail Titov wrote:
On Wed, Aug 26, 2015 at 6:11 AM, Nick Burch
<apache-5Jw25rjQhWFrovVCs/[email protected]> wrote:
You probably shouldn't be defining additional mimetypes to
DefaultParser.
I had an impression that indeed there should be no explicit definition
and new types should be hooked up to a default parser automatically via
the service loader. But my point is, it is not enough with 1.10 if and
only if default parser in config is wrapped.
If you have a new parser with a service file definition, which offers
mimetypes via getSupportedTypes, and a config that uses DefaultParser,
then your parser will be auto-detected and auto-registered
Give it child parsers that support those additional
mimetypes. If there's no child parser registered for a given mimetype,
then binding another mime type to DefaultParser won't help
That is another point of confusion. I thought that Tika somehow
enumerates parsers and registers things on its own using
getSupportedTypes() but apparently I have to be more explicit.
With a service file entry for it, DefaultParser will do so. See the
troubleshooting page for help if that isn't working for you
Nick