Repository: giraph Updated Branches: refs/heads/trunk 8eb1f763d -> 3793c9ef6
http://git-wip-us.apache.org/repos/asf/giraph/blob/3793c9ef/giraph-core/src/test/java/org/apache/giraph/partition/TestPartitionStores.java ---------------------------------------------------------------------- diff --git a/giraph-core/src/test/java/org/apache/giraph/partition/TestPartitionStores.java b/giraph-core/src/test/java/org/apache/giraph/partition/TestPartitionStores.java index 3bb35eb..a7451bc 100644 --- a/giraph-core/src/test/java/org/apache/giraph/partition/TestPartitionStores.java +++ b/giraph-core/src/test/java/org/apache/giraph/partition/TestPartitionStores.java @@ -30,6 +30,7 @@ import org.apache.giraph.conf.GiraphConstants; import org.apache.giraph.conf.ImmutableClassesGiraphConfiguration; import org.apache.giraph.edge.EdgeFactory; import org.apache.giraph.graph.BasicComputation; +import org.apache.giraph.graph.GraphTaskManager; import org.apache.giraph.graph.Vertex; import org.apache.giraph.io.formats.IdWithValueTextOutputFormat; import org.apache.giraph.io.formats.IntIntNullTextVertexInputFormat; @@ -166,6 +167,9 @@ public class TestPartitionStores { ServerData<IntWritable, IntWritable, NullWritable> serverData = new ServerData<>(serviceWorker, conf, context); Mockito.when(serviceWorker.getServerData()).thenReturn(serverData); + GraphTaskManager<IntWritable, IntWritable, NullWritable> + graphTaskManager = new GraphTaskManager<>(context); + Mockito.when(serviceWorker.getGraphTaskManager()).thenReturn(graphTaskManager); DiskBackedPartitionStore<IntWritable, IntWritable, NullWritable> partitionStore = @@ -192,6 +196,9 @@ public class TestPartitionStores { ServerData<IntWritable, IntWritable, NullWritable> serverData = new ServerData<>(serviceWorker, conf, context); Mockito.when(serviceWorker.getServerData()).thenReturn(serverData); + GraphTaskManager<IntWritable, IntWritable, NullWritable> + graphTaskManager = new GraphTaskManager<>(context); + Mockito.when(serviceWorker.getGraphTaskManager()).thenReturn(graphTaskManager); DiskBackedPartitionStore<IntWritable, IntWritable, NullWritable> partitionStore = @@ -307,6 +314,9 @@ public class TestPartitionStores { ServerData<IntWritable, IntWritable, NullWritable> serverData = new ServerData<>(serviceWorker, conf, context); Mockito.when(serviceWorker.getServerData()).thenReturn(serverData); + GraphTaskManager<IntWritable, IntWritable, NullWritable> + graphTaskManager = new GraphTaskManager<>(context); + Mockito.when(serviceWorker.getGraphTaskManager()).thenReturn(graphTaskManager); DiskBackedPartitionStore<IntWritable, IntWritable, NullWritable> store = http://git-wip-us.apache.org/repos/asf/giraph/blob/3793c9ef/giraph-rexster/giraph-rexster-io/src/main/java/org/apache/giraph/rexster/io/RexsterVertexOutputFormat.java ---------------------------------------------------------------------- diff --git a/giraph-rexster/giraph-rexster-io/src/main/java/org/apache/giraph/rexster/io/RexsterVertexOutputFormat.java b/giraph-rexster/giraph-rexster-io/src/main/java/org/apache/giraph/rexster/io/RexsterVertexOutputFormat.java index 9af00e0..0e8d83e 100644 --- a/giraph-rexster/giraph-rexster-io/src/main/java/org/apache/giraph/rexster/io/RexsterVertexOutputFormat.java +++ b/giraph-rexster/giraph-rexster-io/src/main/java/org/apache/giraph/rexster/io/RexsterVertexOutputFormat.java @@ -186,7 +186,7 @@ public class RexsterVertexOutputFormat<I extends WritableComparable, String id = context.getTaskAttemptID().toString(); String zkBasePath = ZooKeeperManager.getBasePath(getConf()) + BspService.BASE_DIR + "/" + - getConf().get("mapred.job.id", "Unknown Job"); + getConf().getJobId(); prepareBarrier(zkBasePath); enterBarrier(zkBasePath, id); checkBarrier(zkBasePath, context);
