You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@nutch.apache.org by "Prakhar Chaube (Jira)" <ji...@apache.org> on 2021/11/30 14:36:00 UTC
[jira] [Updated] (NUTCH-2911) Add cleanup call in Fetcher.java
[ https://issues.apache.org/jira/browse/NUTCH-2911?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Prakhar Chaube updated NUTCH-2911:
----------------------------------
Patch Info: Patch Available
Description:
Fetcher's inner class, FetcherRun overrides Hadoop Mapper's run().
Even though Nutch's FetcherRun doesn't need an explicit call the Mapper's cleanup() (Which is a blank function), it would increase the readability and completeness of the run Method to do so.
Ideally, every implementation of Mapper is supposed to do the following tasks:
1. Perform Setup
2. Call map on the data set
3. Perform cleanups.
Moreover, in case a custom Fetcher is written extending Fetcher.java cleanup could get easily missed out.
PR for Fix: [here|https://github.com/apache/nutch/pull/708]
was:
Fetcher's inner class, FetcherRun overrides Hadoop Mapper's run().
Even though Nutch's FetcherRun doesn't need an explicit call the Mapper's cleanup() (Which is a blank function), it would increase the readability and completeness of the run Method to do so.
Ideally, every implementation of Mapper is supposed to do the following tasks:
1. Perform Setup
2. Call map on the data set
3. Perform cleanups.
Moreover, in case a custom Fetcher is written extending Fetcher.java cleanup could get easily missed out.
> Add cleanup call in Fetcher.java
> --------------------------------
>
> Key: NUTCH-2911
> URL: https://issues.apache.org/jira/browse/NUTCH-2911
> Project: Nutch
> Issue Type: Improvement
> Components: fetcher
> Reporter: Prakhar Chaube
> Priority: Minor
> Labels: improvement
>
> Fetcher's inner class, FetcherRun overrides Hadoop Mapper's run().
> Even though Nutch's FetcherRun doesn't need an explicit call the Mapper's cleanup() (Which is a blank function), it would increase the readability and completeness of the run Method to do so.
> Ideally, every implementation of Mapper is supposed to do the following tasks:
> 1. Perform Setup
> 2. Call map on the data set
> 3. Perform cleanups.
> Moreover, in case a custom Fetcher is written extending Fetcher.java cleanup could get easily missed out.
> PR for Fix: [here|https://github.com/apache/nutch/pull/708]
--
This message was sent by Atlassian Jira
(v8.20.1#820001)