[ 
https://issues.apache.org/jira/browse/NUTCH-1941?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Asitang Mishra updated NUTCH-1941:
----------------------------------
    Attachment: NUTCH-1941-ITR2.patch

Added: NUTCH-1941-ITR2.patch
This patch makes changes to the HttpBase class( A single instance of this is 
used by different fetcher threads. So, have made the getter of the agentname 
synchronized)
The function rotateAgentName rotates the name of the agent every x urls 
fetched. The value of x is determined randomly between 1 and 50 (can use a 
different value here).
The list of names to rotate from come from a file "agent.txt" which should be 
kept in the nutch/runtime/local folder in your nutch installation.
Each line in this file should contain an agent name. 

> Optional rolling http.agent.name's
> ----------------------------------
>
>                 Key: NUTCH-1941
>                 URL: https://issues.apache.org/jira/browse/NUTCH-1941
>             Project: Nutch
>          Issue Type: New Feature
>          Components: fetcher, protocol
>            Reporter: Lewis John McGibbney
>            Priority: Trivial
>         Attachments: NUTCH-1941-ITR2.patch, NUTCH-1941-ver1.patch, 
> agent.names.txt, nutch.patch
>
>
> In some scenarios, even whilst adhering to fetcher.crawl.delay, web admins 
> can block your fetcher based merely on your crawler name. 
> I propose the ability to implement rolling http.agent.name's which could be 
> substituted every 5 seconds for example. This would mean that successive 
> requests to the same domain would be sent with different http.agent.name. 
> This behavior should be off by default.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to