Skip to content

Commit

Permalink
Fix genNode to fill version and time in right field.
Browse files Browse the repository at this point in the history
  • Loading branch information
colorant committed May 7, 2013
1 parent a3575dd commit 2687b73
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/main/java/com/facebook/LinkBench/NodeLoader.java
Original file line number Diff line number Diff line change
Expand Up @@ -167,8 +167,9 @@ private void displayAndResetStats() {
private void genNode(Random rng, long id1, ArrayList<Node> nodeLoadBuffer,
int bulkLoadBatchSize) {
int dataLength = (int)nodeDataLength.choose(rng);
Node node = new Node(id1, LinkStore.DEFAULT_NODE_TYPE, System.currentTimeMillis(),
1, nodeDataGen.fill(rng, new byte[dataLength]));
Node node = new Node(id1, LinkStore.DEFAULT_NODE_TYPE, 1,
(int)(System.currentTimeMillis()/1000),
nodeDataGen.fill(rng, new byte[dataLength]));
nodeLoadBuffer.add(node);
if (nodeLoadBuffer.size() >= bulkLoadBatchSize) {
loadNodes(nodeLoadBuffer);
Expand Down

0 comments on commit 2687b73

Please sign in to comment.