You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tika.apache.org by lewis john mcgibbney <le...@apache.org> on 2018/02/28 06:15:31 UTC

Unnecessary WARNING Logging?

Hi Folks,
I don't know when it was introduced, by I see the following, rather
annoying WARNING messages in many logs now.
I feel that these should not be WARNING e.g. what if I don't want any of
them to be initiated... which is exactly the case over when we use Tika in
Apache Any23.
Does anyone have objections if I turn this logging off?... or was there
some other primary motivation for every application to log this message?
Thanks,
Lewis

Feb 28, 2018 6:09:55 AM
org.apache.tika.config.InitializableProblemHandler$3
handleInitializableProblem
WARNING: JBIG2ImageReader not loaded. jbig2 files will be ignored
See https://pdfbox.apache.org/2.0/dependencies.html#jai-image-io
for optional dependencies.
TIFFImageWriter not loaded. tiff files will not be processed
See https://pdfbox.apache.org/2.0/dependencies.html#jai-image-io
for optional dependencies.
J2KImageReader not loaded. JPEG2000 files will not be processed.
See https://pdfbox.apache.org/2.0/dependencies.html#jai-image-io
for optional dependencies.

Feb 28, 2018 6:09:55 AM
org.apache.tika.config.InitializableProblemHandler$3
handleInitializableProblem
WARNING: org.xerial's sqlite-jdbc is not loaded.
Please provide the jar on your classpath to parse sqlite files.
See tika-parsers/pom.xml for the correct version.


-- 
http://home.apache.org/~lewismc/
http://people.apache.org/keys/committer/lewismc

Fwd: Unnecessary WARNING Logging?

Posted by lewis john mcgibbney <le...@apache.org>.
Hi Folks,
See below for solution to annoying Tika logging

From: Nick Burch <ap...@gagravarr.org>
To: dev@tika.apache.org
Cc:
Bcc:
Date: Wed, 28 Feb 2018 08:03:53 +0000 (GMT)
Subject: Re: Unnecessary WARNING Logging?
On Tue, 27 Feb 2018, lewis john mcgibbney wrote:

> I don't know when it was introduced, by I see the following, rather
> annoying WARNING messages in many logs now.
>

IIRC we're changing those to ignore in Tika 2.x, but as we always warned
for missing parsers / missing parser classes in 1.x we can't really change
the default without surprising people

I feel that these should not be WARNING e.g. what if I don't want any of
> them to be initiated... which is exactly the case over when we use Tika in
> Apache Any23.
>

Just set the load error handler to ignore, and you won't be notified of
anything missing. (It's then up to you to ensure you didn't miss any
classes or jars you wanted!)

eg in a Tika config:
<properties>
  <service-loader loadErrorHandler="IGNORE"/>
</properties>

See also https://tika.apache.org/1.17/configuring.html#Load_Error_Handling


---------- Forwarded message ----------
From: lewis john mcgibbney <le...@apache.org>
Date: Tue, Feb 27, 2018 at 10:15 PM
Subject: Unnecessary WARNING Logging?
To: dev@tika.apache.org


Hi Folks,
I don't know when it was introduced, by I see the following, rather
annoying WARNING messages in many logs now.
I feel that these should not be WARNING e.g. what if I don't want any of
them to be initiated... which is exactly the case over when we use Tika in
Apache Any23.
Does anyone have objections if I turn this logging off?... or was there
some other primary motivation for every application to log this message?
Thanks,
Lewis

Feb 28, 2018 6:09:55 AM
org.apache.tika.config.InitializableProblemHandler$3
handleInitializableProblem
WARNING: JBIG2ImageReader not loaded. jbig2 files will be ignored
See https://pdfbox.apache.org/2.0/dependencies.html#jai-image-io
for optional dependencies.
TIFFImageWriter not loaded. tiff files will not be processed
See https://pdfbox.apache.org/2.0/dependencies.html#jai-image-io
for optional dependencies.
J2KImageReader not loaded. JPEG2000 files will not be processed.
See https://pdfbox.apache.org/2.0/dependencies.html#jai-image-io
for optional dependencies.

Feb 28, 2018 6:09:55 AM
org.apache.tika.config.InitializableProblemHandler$3
handleInitializableProblem
WARNING: org.xerial's sqlite-jdbc is not loaded.
Please provide the jar on your classpath to parse sqlite files.
See tika-parsers/pom.xml for the correct version.


-- 
http://home.apache.org/~lewismc/
http://people.apache.org/keys/committer/lewismc



-- 
http://home.apache.org/~lewismc/
http://people.apache.org/keys/committer/lewismc

Re: Unnecessary WARNING Logging?

Posted by Nick Burch <ap...@gagravarr.org>.
On Tue, 27 Feb 2018, lewis john mcgibbney wrote:
> I don't know when it was introduced, by I see the following, rather
> annoying WARNING messages in many logs now.

IIRC we're changing those to ignore in Tika 2.x, but as we always warned 
for missing parsers / missing parser classes in 1.x we can't really change 
the default without surprising people

> I feel that these should not be WARNING e.g. what if I don't want any of
> them to be initiated... which is exactly the case over when we use Tika in
> Apache Any23.

Just set the load error handler to ignore, and you won't be notified of 
anything missing. (It's then up to you to ensure you didn't miss any 
classes or jars you wanted!)

eg in a Tika config:
<properties>
   <service-loader loadErrorHandler="IGNORE"/>
</properties>

See also https://tika.apache.org/1.17/configuring.html#Load_Error_Handling

Nick