Start the work of firing up X concurrent get requests.
()
| 630 | * Start the work of firing up X concurrent get requests. |
| 631 | */ |
| 632 | private void startFetch() { |
| 633 | prepareConcurrentMultiGetTasks(); |
| 634 | |
| 635 | // set the time of starting |
| 636 | fetch_start_time = System.currentTimeMillis(); |
| 637 | if (LOG.isDebugEnabled()) { |
| 638 | LOG.debug("Start to fetch data using multiget, there will be " + multi_get_wait_cnt |
| 639 | + " multigets to call"); |
| 640 | } |
| 641 | |
| 642 | for (int con_idx = 0; con_idx < concurrency_multi_get; ++con_idx) { |
| 643 | final List<MultiGetTask> con_mul_get_tasks = multi_get_tasks.get(con_idx); |
| 644 | final int task_index = multi_get_indexs.get(con_idx).incrementAndGet(); |
| 645 | |
| 646 | if (task_index < con_mul_get_tasks.size()) { |
| 647 | final MultiGetTask task = con_mul_get_tasks.get(task_index); |
| 648 | final MulGetCB mgcb = new MulGetCB(con_idx, task.getTSUIDs(), task.getGets()); |
| 649 | mgcb.fetch(); |
| 650 | } |
| 651 | } // end for |
| 652 | } |
| 653 | |
| 654 | /** |
| 655 | * Compiles the list of TSUIDs and GetRequests to send to execute against |
no test coverage detected