mgnipy.V2.mgnifier.query_executor module#
- class QueryExecutor(query_set, client=None)[source]#
Bases:
objectResponsible for executing the queries defined in a QuerySet, handling pagination, concurrency limits, and result caching.
This class provides both synchronous and asynchronous methods to retrieve metadata pages from the MGnify API, with built-in support for concurrency control to protect the server. It also tracks successful page retrievals and allows for resuming or continuing iterations based on previously retrieved pages.
The QueryExecutor is designed to work closely with a QuerySet, using its query definitions and caching mechanisms to efficiently retrieve and store results. It includes helper methods for initializing API clients, parsing responses, and managing iteration state.
- Parameters:
query_set (QuerySet)
client (Optional[Client | AuthenticatedClient])