class QueryExecutor {

    public <T extends ActionRequest> Action resolve(T request) throws QueryStoreException {
        Action action;
        try {
            action = analyticsLoader.getAction(request);
        } catch (Exception e) {
            logger.error("Error resolving action: ", e);
            throw new QueryStoreException(QueryStoreException.ErrorCode.ACTION_RESOLUTION_ERROR,
                    "Error resolving action for: " + request.getClass().getCanonicalName(), e);
        }
        if (null == action) {
            throw new QueryStoreException(QueryStoreException.ErrorCode.UNRESOLVABLE_OPERATION,
                    "No resolvable action could be found for: " + request.getClass().getCanonicalName());
        }
        return action;
    }

    public  QueryExecutor(AnalyticsLoader analyticsLoader, ExecutorService executorService);

}