You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@nutch.apache.org by "Julien Nioche (JIRA)" <ji...@apache.org> on 2013/07/05 16:28:07 UTC

[jira] [Created] (NUTCH-1604) ProtocolFactory not thread-safe

Julien Nioche created NUTCH-1604:
------------------------------------

             Summary: ProtocolFactory not thread-safe
                 Key: NUTCH-1604
                 URL: https://issues.apache.org/jira/browse/NUTCH-1604
             Project: Nutch
          Issue Type: Bug
            Reporter: Julien Nioche


The method getProtocol() should be synchronized otherwise the Fetcher threads can access it around the same time and query the cache before it's had a chance of being populated properly. This would happen for a handful of calls until the subsequent ones get the cache but this should be fixed nonetheless e.g. when we want a guarantee that the same Protocol instance will be called for the same fetching session.
The other Factor classes which use the same cache mechanism would suffer from the same problem.    

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira