Package org.apache.nutch.crawl
Class URLPartitioner
- All Implemented Interfaces:
Configurable
Partition urls by host, domain name or IP depending on the value of the
parameter 'partition.url.mode' which can be 'byHost', 'byDomain' or 'byIP'
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetConf()intgetPartition(Text key, Writable value, int numReduceTasks) Hash by host or domain name or IP address.voidsetConf(Configuration conf)
-
Field Details
-
PARTITION_MODE_KEY
- See Also:
-
PARTITION_MODE_HOST
- See Also:
-
PARTITION_MODE_DOMAIN
- See Also:
-
PARTITION_MODE_IP
- See Also:
-
-
Constructor Details
-
URLPartitioner
public URLPartitioner()
-
-
Method Details
-
setConf
- Specified by:
setConfin interfaceConfigurable
-
getConf
- Specified by:
getConfin interfaceConfigurable
-
getPartition
Hash by host or domain name or IP address.- Specified by:
getPartitionin classPartitioner<Text,Writable>
-