Skip to content
This repository was archived by the owner on Feb 20, 2026. It is now read-only.

fix: Make aggregation query requests run properly inside a transaction - #1166

Merged
danieljbruce merged 5 commits into
googleapis:mainfrom
danieljbruce:1151-aggregate-queries-for-transactions
Oct 3, 2023
Merged

fix: Make aggregation query requests run properly inside a transaction#1166
danieljbruce merged 5 commits into
googleapis:mainfrom
danieljbruce:1151-aggregate-queries-for-transactions

Conversation

@danieljbruce

Copy link
Copy Markdown
Contributor

Changes:

This PR ensures that transaction reads work for run aggregation query requests. Currently, when a user uses the transaction object to run an aggregation query request then the aggregation query request does not run inside the transaction. This fix ensures that the request does run inside a transaction.

Fixes #1151

When doing a readOnly transaction, the code should do reads from a consistent snapshot so that if a write is done mid-transaction then that doesn’t affect the read value.
This code change ensures transactions that run aggregate queries actually make the request as an aggregate query.
Verify run query results at a particular time so that we know what data we are working with for the rest of the aggregate query tests.
@danieljbruce
danieljbruce requested review from a team October 2, 2023 14:24
@product-auto-label product-auto-label Bot added size: s Pull request size is small. api: datastore Issues related to the googleapis/nodejs-datastore API. labels Oct 2, 2023
@product-auto-label product-auto-label Bot added size: m Pull request size is medium. and removed size: s Pull request size is small. labels Oct 2, 2023
@danieljbruce danieljbruce added the owlbot:run Add this label to trigger the Owlbot post processor. label Oct 3, 2023
@gcf-owl-bot gcf-owl-bot Bot removed the owlbot:run Add this label to trigger the Owlbot post processor. label Oct 3, 2023
@danieljbruce
danieljbruce merged commit 263804b into googleapis:main Oct 3, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

api: datastore Issues related to the googleapis/nodejs-datastore API. size: m Pull request size is medium.

2 participants