You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mrunit.apache.org by "Ryan Chapin (JIRA)" <ji...@apache.org> on 2016/01/14 14:59:39 UTC

[jira] [Commented] (MRUNIT-217) MapReduceDriver does not seem to work with MultipleOutput

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

Ryan Chapin commented on MRUNIT-217:
------------------------------------

[~dbeech], just wondering if anyone has had a chance to take a look at the patch.  Thanks!

> MapReduceDriver does not seem to work with MultipleOutput
> ---------------------------------------------------------
>
>                 Key: MRUNIT-217
>                 URL: https://issues.apache.org/jira/browse/MRUNIT-217
>             Project: MRUnit
>          Issue Type: Question
>    Affects Versions: 1.1.0
>            Reporter: mathieu lavoie
>            Assignee: Ryan Chapin
>         Attachments: MRUNIT-217.patch
>
>
> Hi,
> I'm having an issue running a test with org.apache.hadoop.mrunit.mapreduce.MapReduceDriver using a reducer with multiple outputs. It seems like the generated results is always empty.
> It seems to work just fine for the ReduceDriver but not for the MapReduceDriver.
> The field:
> {noformat}
>   protected MockMultipleOutputs mos
> {noformat}
> Is set in the ReduceDriver using a mock but the MapReduceDriver is not aware of it. Therefore the TestDriver thinks that there is no result.
> Am I missing something ?
> Here is a snippet of the configuration of my test:
> {noformat}
> @RunWith(PowerMockRunner.class)
> @PrepareForTest({StandardMetricsByListenerReducer.class})
> public class StandardMetricsByListenerMapReduceTest {
>     private MapReduceDriver<Object, Text, StandardMetricsDayKeyWritable, StandardMetricsValueWriteable, StandardMetricsDayKeyWritable, StandardMetricsValueWriteable> mapReduceDriver;
>     @Before
>     public void setup() throws Exception {
>         StandardMetricsByListenerMapper mapper = new StandardMetricsByListenerMapper();
>         StandardMetricsByListenerReducer reducer = new StandardMetricsByListenerReducer();
>         mapReduceDriver = MapReduceDriver.newMapReduceDriver(mapper, reducer);
>     }
> }
> {noformat}
> Thanks



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