$builder = $this->modelsManager->createBuilder();
$builder->from('Koogua\Model\Entity\Thread');
$paginator = new QueryBuilderPaginator([
'builder' => $builder,
'limit' => $limit,
'page' => $page,
]);
$page = $paginator->getPaginate();
two queries will be executed, one for total count , one for items.
is there some ways to cache the queries ?