MCPcopy Create free account
hub / github.com/apache/nutch / randomBatchId

Method randomBatchId

src/java/org/apache/nutch/crawl/GeneratorJob.java:186–190  ·  view source on GitHub ↗

Generates a random batch id @return random batch id

()

Source from the content-addressed store, hash-verified

184 * @return random batch id
185 */
186 public static String randomBatchId() {
187 long curTime = System.currentTimeMillis();
188 int randomSeed = Math.abs(new Random().nextInt());
189 return (curTime / 1000) + "-" + randomSeed;
190 }
191
192 /**
193 * Runs generator

Callers 1

runMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected