ignite-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sboi...@apache.org
Subject [32/47] ignite git commit: IGNITE-358: Hadoop: added InputSplit to HadoopV1Reporter. This closes #3059.
Date Tue, 21 Nov 2017 12:10:26 GMT
IGNITE-358: Hadoop: added InputSplit to HadoopV1Reporter. This closes #3059.


Project: http://git-wip-us.apache.org/repos/asf/ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/ignite/commit/64ffa3d4
Tree: http://git-wip-us.apache.org/repos/asf/ignite/tree/64ffa3d4
Diff: http://git-wip-us.apache.org/repos/asf/ignite/diff/64ffa3d4

Branch: refs/heads/ignite-zk
Commit: 64ffa3d4ebc4e56f91e05836642fed2824d192f7
Parents: cbd7e39
Author: Konstantin Dudkov <kdudkov@ya.ru>
Authored: Fri Nov 17 16:09:10 2017 +0300
Committer: devozerov <vozerov@gridgain.com>
Committed: Fri Nov 17 16:09:10 2017 +0300

----------------------------------------------------------------------
 .../internal/processors/hadoop/impl/v1/HadoopV1MapTask.java  | 6 +++---
 .../internal/processors/hadoop/impl/v1/HadoopV1Reporter.java | 8 ++++++--
 2 files changed, 9 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/64ffa3d4/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/impl/v1/HadoopV1MapTask.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/impl/v1/HadoopV1MapTask.java
b/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/impl/v1/HadoopV1MapTask.java
index 2172ff2..039c5cd 100644
--- a/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/impl/v1/HadoopV1MapTask.java
+++ b/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/impl/v1/HadoopV1MapTask.java
@@ -27,10 +27,10 @@ import org.apache.hadoop.mapred.RecordReader;
 import org.apache.hadoop.mapred.Reporter;
 import org.apache.hadoop.util.ReflectionUtils;
 import org.apache.ignite.IgniteCheckedException;
-import org.apache.ignite.internal.processors.hadoop.HadoopFileBlock;
-import org.apache.ignite.internal.processors.hadoop.HadoopMapperUtils;
 import org.apache.ignite.hadoop.HadoopInputSplit;
+import org.apache.ignite.internal.processors.hadoop.HadoopFileBlock;
 import org.apache.ignite.internal.processors.hadoop.HadoopJobEx;
+import org.apache.ignite.internal.processors.hadoop.HadoopMapperUtils;
 import org.apache.ignite.internal.processors.hadoop.HadoopTaskCancelledException;
 import org.apache.ignite.internal.processors.hadoop.HadoopTaskContext;
 import org.apache.ignite.internal.processors.hadoop.HadoopTaskInfo;
@@ -83,7 +83,7 @@ public class HadoopV1MapTask extends HadoopV1Task {
 
             assert nativeSplit != null;
 
-            Reporter reporter = new HadoopV1Reporter(taskCtx);
+            Reporter reporter = new HadoopV1Reporter(taskCtx, nativeSplit);
 
             HadoopV1OutputCollector collector = null;
 

http://git-wip-us.apache.org/repos/asf/ignite/blob/64ffa3d4/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/impl/v1/HadoopV1Reporter.java
----------------------------------------------------------------------
diff --git a/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/impl/v1/HadoopV1Reporter.java
b/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/impl/v1/HadoopV1Reporter.java
index f3229e2..8f13ff9 100644
--- a/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/impl/v1/HadoopV1Reporter.java
+++ b/modules/hadoop/src/main/java/org/apache/ignite/internal/processors/hadoop/impl/v1/HadoopV1Reporter.java
@@ -30,13 +30,17 @@ public class HadoopV1Reporter implements Reporter {
     /** Context. */
     private final HadoopTaskContext ctx;
 
+    /** Input split */
+    private final InputSplit split;
+
     /**
      * Creates new instance.
      *
      * @param ctx Context.
      */
-    public HadoopV1Reporter(HadoopTaskContext ctx) {
+    public HadoopV1Reporter(HadoopTaskContext ctx, InputSplit split) {
         this.ctx = ctx;
+        this.split = split;
     }
 
     /** {@inheritDoc} */
@@ -66,7 +70,7 @@ public class HadoopV1Reporter implements Reporter {
 
     /** {@inheritDoc} */
     @Override public InputSplit getInputSplit() throws UnsupportedOperationException {
-        throw new UnsupportedOperationException("reporter has no input"); // TODO
+        return split;
     }
 
     /** {@inheritDoc} */


Mime
View raw message