You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tika.apache.org by Grant Ingersoll <gs...@apache.org> on 2008/11/12 17:23:03 UTC

Thread Safety

Hi,

Is AutoDetectParser thread-safe and/or all the other parsers?

-Grant

Re: Thread Safety

Posted by Jukka Zitting <ju...@gmail.com>.
Hi,

On Thu, Nov 13, 2008 at 4:22 PM, Grant Ingersoll <gs...@apache.org> wrote:
> Is it costly to create a Parser?  I suspect it isn't if you already have the
> config, which I do.

Correct, they are just simple instances. Almost all the work is done
in the parse() method.

BR,

Jukka Zitting

Re: Thread Safety

Posted by Grant Ingersoll <gs...@apache.org>.
Is it costly to create a Parser?  I suspect it isn't if you already  
have the config, which I do.

On Nov 13, 2008, at 8:51 AM, Jukka Zitting wrote:

> Hi,
>
> On Wed, Nov 12, 2008 at 5:23 PM, Grant Ingersoll  
> <gs...@apache.org> wrote:
>> Is AutoDetectParser thread-safe and/or all the other parsers?
>
> Yes. Once initialized, a parser instance should be immutable and thus
> fully thread-safe.
>
> BR,
>
> Jukka Zitting



Re: Thread Safety

Posted by Jukka Zitting <ju...@gmail.com>.
Hi,

On Wed, Nov 12, 2008 at 5:23 PM, Grant Ingersoll <gs...@apache.org> wrote:
> Is AutoDetectParser thread-safe and/or all the other parsers?

Yes. Once initialized, a parser instance should be immutable and thus
fully thread-safe.

BR,

Jukka Zitting