()
| 48 | } |
| 49 | |
| 50 | private void runTotal() { |
| 51 | String query = |
| 52 | " {\n" |
| 53 | + " var(func: uid(%s)) {\n" |
| 54 | + " b as bal\n" |
| 55 | + " }\n" |
| 56 | + " total() {\n" |
| 57 | + " bal: sum(val(b))\n" |
| 58 | + " }\n" |
| 59 | + " }"; |
| 60 | query = String.format(query, String.join(",", uids)); |
| 61 | Transaction txn = dgraphClient.newTransaction(); |
| 62 | Response resp = txn.query(query); |
| 63 | logger.debug("\nresponse json: {}\n", resp.getJson().toStringUtf8()); |
| 64 | logger.debug("Runs: {}. Aborts: {}\n", runs.get(), aborts.get()); |
| 65 | } |
| 66 | |
| 67 | private void runTotalInLoop() { |
| 68 | while (true) { |
no test coverage detected