MCPcopy Create free account
hub / github.com/devaccuracy/ledgerforge / bucketedName

Function bucketedName

tests/loadtest/script.js:213–220  ·  view source on GitHub ↗
(base, buckets)

Source from the content-addressed store, hash-verified

211}
212
213function bucketedName(base, buckets) {
214 if (buckets <= 1) {
215 return base;
216 }
217
218 var shard = Math.floor(Math.random() * buckets) + 1;
219 return base + "-bucket-" + shard;
220}
221
222function postTxn(source, destination) {
223 var amount = Math.floor(Math.random() * (1000 - 100 + 1)) + 100; // 100..1000

Callers 2

hotSourceTrafficFunction · 0.85
hotDestinationTrafficFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected