ExecuteQuery() protected method

protected ExecuteQuery ( IQuery context, Deveel.Data.Sql.SqlQuery query ) : IQueryResponse[]
context IQuery
query Deveel.Data.Sql.SqlQuery
return IQueryResponse[]
Example #1
0
            private IMessageEnvelope ProcessQuery(IDictionary <string, object> metadata, QueryExecuteRequest request)
            {
                try {
                    connector.AssertNotDisposed();
                    connector.AssertAuthenticated();

                    // TODO: use the timeout ...
                    var queryResonse = connector.ExecuteQuery(request.CommitId, request.Query);
                    return(connector.CreateEnvelope(metadata, new QueryExecuteResponse(queryResonse)));
                } catch (Exception ex) {
                    // TODO: Log the error ...
                    return(CreateErrorResponse(metadata, ex));
                }
            }
            private IMessageEnvelope ProcessQuery(IDictionary <string, object> metadata, QueryExecuteRequest request)
            {
                try {
                    connector.AssertNotDisposed();
                    connector.AssertAuthenticated();

                    // TODO: use the timeout ...
                    var queryResonse = connector.ExecuteQuery(request.Query.Text, request.Query.Parameters);
                    return(connector.CreateEnvelope(metadata, new QueryExecuteResponse(queryResonse)));
                } catch (Exception ex) {
                    connector.Logger.Error(connector, "Error while processing a query request.");
                    connector.Logger.Error(connector, ex);
                    return(CreateErrorResponse(metadata, ex));
                }
            }