public QueryResult query(QueryRequest queryRequest)
throws AmazonServiceException, AmazonClientException {
ExecutionContext executionContext = createExecutionContext(queryRequest);
AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics();
Request<QueryRequest> request = marshall(queryRequest,
new QueryRequestMarshaller(),
executionContext.getAwsRequestMetrics());
// Binds the request metrics to the current request.
request.setAWSRequestMetrics(awsRequestMetrics);
Unmarshaller<QueryResult, JsonUnmarshallerContext> unmarshaller = new QueryResultJsonUnmarshaller();
JsonResponseHandler<QueryResult> responseHandler = new JsonResponseHandler<QueryResult>(unmarshaller);