Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: implement query profile #1365

Merged
merged 19 commits into from
Mar 25, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Prev Previous commit
Next Next commit
review feedback
  • Loading branch information
kolea2 committed Jan 18, 2024
commit f23e1ecdf732bd543b683ae915b6a582ed58c275
Original file line number Diff line number Diff line change
Expand Up @@ -485,7 +485,7 @@ interface TransactionCallable<T> {
@BetaApi
default <T> QueryResults<T> run(
Query<T> query, QueryProfile.QueryMode queryMode, ReadOption... options) {
throw new UnsupportedOperationException("not implemented");
throw new UnsupportedOperationException("Not implemented.");
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,8 @@ private void sendRequest() {
boolean isQueryPlan = actualResultType.getQueryType() == null && queryMode == QueryMode.PLAN;
Preconditions.checkState(
queryResultType.isAssignableFrom(actualResultType) || isQueryPlan,
"Unexpected result type " + actualResultType + " vs " + queryResultType);
"Unexpected result type or query mode. Result type: " + actualResultType + " vs " + queryResultType +", query mode: " + queryMode);

if (runQueryResponsePb.getStats().hasQueryPlan()
|| runQueryResponsePb.getStats().hasQueryStats()) {
this.resultSetStats = new ResultSetStats(runQueryResponsePb.getStats());
Expand Down