crunch-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chao Shi (JIRA)" <>
Subject [jira] [Commented] (CRUNCH-351) Improve performance of Shard#shard on large records
Date Sun, 23 Feb 2014 10:22:19 GMT


Chao Shi commented on CRUNCH-351:

bq. About the use of the random long as the key, I was thinking it might be even better to
use a limited-range int as the generated key..

OK, let me switch to int32.

bq. Also on the subject of the random key generation, is there any drawback to using a constant
value as the seed for the Random? If not, it might be better to just use a constant to avoid
the dependency on the MapReduce framework.

I think a constant random seed is effectively same as using a increasing key and passing records
to reducers in round-robin. The general drawback is that all mapper will produce the same
sequence. For this particular problem, I think using the round-robin approach is OK and simpler.

> Improve performance of Shard#shard on large records
> ---------------------------------------------------
>                 Key: CRUNCH-351
>                 URL:
>             Project: Crunch
>          Issue Type: Improvement
>            Reporter: Chao Shi
>            Assignee: Chao Shi
>         Attachments: crunch-351.patch
>     This avoids sorting on the input data, which may be long and make
>     shuffle phase slow. The improvement is to sort on pseudo-random numbers.

This message was sent by Atlassian JIRA

View raw message