<T> CosmosPagedFlux<T> executeCosmosQueryAsync(String containerName, SqlQuerySpec sqlQuerySpec,
      CosmosQueryRequestOptions cosmosQueryRequestOptions, Class<T> classType) {
    azureMetrics.documentQueryCount.inc();
    // Check for null value of partition key.
    if (cosmosQueryRequestOptions.getPartitionKey() != null && !Utils.isNullOrEmpty(
        cosmosQueryRequestOptions.getPartitionKey().toString())) {
      logger.debug("Running query on partition {}: {}", cosmosQueryRequestOptions.getPartitionKey().toString(),
          sqlQuerySpec.getQueryText());
    } else {
      logger.debug("Running query on partition {}", sqlQuerySpec.getQueryText());
    }

    CosmosAsyncContainer cosmosAsyncContainer = cosmosAsyncDatabase.getContainer(containerName);
    return cosmosAsyncContainer.queryItems(sqlQuerySpec, cosmosQueryRequestOptions, classType);
  }
Utility method to call Cosmos document query method and record the query time.
@param containerName collection link of the collection to execute query on.
@param sqlQuerySpec the DocumentDB query to execute.
@param cosmosQueryRequestOptions {@link CosmosQueryRequestOptions} object specifying the options associated with the method.
@param classType type of Class.
@return {@link CosmosPagedFlux} containing the query response.
ambry-cloud/src/main/java/com/github/ambry/cloud/azure/CosmosDataAccessor.java