nutch-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hudson (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (NUTCH-2625) ProtocolFactory.getProtocol(url) may create multiple plugin instances
Date Thu, 15 Nov 2018 10:45:01 GMT

    [ https://issues.apache.org/jira/browse/NUTCH-2625?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16687792#comment-16687792
] 

Hudson commented on NUTCH-2625:
-------------------------------

FAILURE: Integrated in Jenkins build Nutch-trunk #3589 (See [https://builds.apache.org/job/Nutch-trunk/3589/])
NUTCH-2625 ProtocolFactory.getProtocol(url) may create multiple plugin (snagel: [https://github.com/apache/nutch/commit/a6f533dfecd688a6c43212b0e826be9a2da5b4ce])
* (edit) src/java/org/apache/nutch/protocol/ProtocolFactory.java


> ProtocolFactory.getProtocol(url) may create multiple plugin instances
> ---------------------------------------------------------------------
>
>                 Key: NUTCH-2625
>                 URL: https://issues.apache.org/jira/browse/NUTCH-2625
>             Project: Nutch
>          Issue Type: Improvement
>          Components: protocol
>    Affects Versions: 1.15
>            Reporter: Sebastian Nagel
>            Assignee: Sebastian Nagel
>            Priority: Minor
>             Fix For: 1.16
>
>
> The method ProtocolFactory.getProtocol(URL url) may create unnecessarily multiple instances
of protocol plugins given the same configuration. The following snippets from a Fetcher using
100 FetcherThreads show that the setConf(conf) method of the protocol-okhttp plugin is called
100 times (once for each thread):
> {noformat}
> 2018-07-12 12:04:32,811 INFO [main] org.apache.nutch.fetcher.FetcherThread: FetcherThread
1 Using queue mode : byHost
> ... (skipped 98 repeated messages)
> 2018-07-12 12:04:33,136 INFO [main] org.apache.nutch.fetcher.FetcherThread: FetcherThread
1 Using queue mode : byHost
> ...
> 2018-07-12 12:04:37,493 INFO [FetcherThread] org.apache.nutch.protocol.RobotRulesParser:
robots.txt whitelist not configured.
> 2018-07-12 12:04:37,493 INFO [FetcherThread] org.apache.nutch.protocol.okhttp.OkHttp:
http.proxy.host = null
> ...
> 2018-07-12 12:04:37,494 INFO [FetcherThread] org.apache.nutch.protocol.okhttp.OkHttp:
http.enable.cookie.header = false
> ... (skipped 98 blocks of repeated messages)
> 2018-07-12 12:04:39,080 INFO [FetcherThread] org.apache.nutch.protocol.RobotRulesParser:
robots.txt whitelist not configured.
> 2018-07-12 12:04:39,080 INFO [FetcherThread] org.apache.nutch.protocol.okhttp.OkHttp:
http.proxy.host = null
> ...
> 2018-07-12 12:04:39,080 INFO [FetcherThread] org.apache.nutch.protocol.okhttp.OkHttp:
http.enable.cookie.header = false
> {noformat}
> The method ProtocolFactory.getProtocol(URL url) is synchronized, however each FetcherThread
holds its own instance of the ProtocolFactory.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message