-
Notifications
You must be signed in to change notification settings - Fork 101
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
fix: read time should be used for transaction reads #1171
fix: read time should be used for transaction reads #1171
Commits on Sep 7, 2023
-
Allow datastore projectId to be fetched from clien
Latency is caused by the call to getProjectId from Google auth. This change allows the project id to be retrieved if it is set in the client at creation time thereby reducing call latency.
Configuration menu - View commit details
-
Copy full SHA for b66827e - Browse repository at this point
Copy the full SHA b66827eView commit details
Commits on Sep 20, 2023
-
Create a file for mocking out commits
A test file is created where we mock out commit in the Gapic layer. The mock allows us to get the results passed to the commit endpoint in the Gapic layer.
Configuration menu - View commit details
-
Copy full SHA for 684c469 - Browse repository at this point
Copy the full SHA 684c469View commit details
Commits on Sep 21, 2023
-
Create a test to measure latency of call.
To prove that the change works to reduce latency, a test is written. The test checks to see that the amount of time that passes between the time when the initial call is made in the user’s code and the time when the call reaches the gapic layer is sufficiently small. It will be a very small amount of time if the program does not need to do an auth lookup.
Configuration menu - View commit details
-
Copy full SHA for 1ec6ed2 - Browse repository at this point
Copy the full SHA 1ec6ed2View commit details -
Run the linter so that spacing in the PR gets fixed for some of the lines of code.
Configuration menu - View commit details
-
Copy full SHA for 40213ca - Browse repository at this point
Copy the full SHA 40213caView commit details -
Add license header to top of test file
The license header needs to be added to the top of the new test file that is used for mocking out commit.
Configuration menu - View commit details
-
Copy full SHA for 57e3b13 - Browse repository at this point
Copy the full SHA 57e3b13View commit details -
This is going to be a test for investigating the latency of the client.
Configuration menu - View commit details
-
Copy full SHA for af56d91 - Browse repository at this point
Copy the full SHA af56d91View commit details
Commits on Sep 22, 2023
-
Add a test for the mock server
Measure the latency between the original call and the mock server.
Configuration menu - View commit details
-
Copy full SHA for 72f9492 - Browse repository at this point
Copy the full SHA 72f9492View commit details -
Configuration menu - View commit details
-
Copy full SHA for 194e109 - Browse repository at this point
Copy the full SHA 194e109View commit details -
Do check external to function after async call. Add log for call time.
Configuration menu - View commit details
-
Copy full SHA for 22d5f54 - Browse repository at this point
Copy the full SHA 22d5f54View commit details
Commits on Sep 25, 2023
-
Other mock doesn’t require lazy client initialization.
Configuration menu - View commit details
-
Copy full SHA for 81f5956 - Browse repository at this point
Copy the full SHA 81f5956View commit details
Commits on Oct 13, 2023
-
Eliminate code from the mock file
Eliminate the fake datastore client because we need to do assertion checks that are specific to each test. This means there is no point in defining runQuery once in a mock because each test will mock it out differently.
Configuration menu - View commit details
-
Copy full SHA for dc9dbb7 - Browse repository at this point
Copy the full SHA dc9dbb7View commit details -
Start off by adding read time to read options
Add the code change that will add read time to read options for transactions. # Conflicts: # test/transaction.ts
Configuration menu - View commit details
-
Copy full SHA for 0ad0a57 - Browse repository at this point
Copy the full SHA 0ad0a57View commit details -
Update the test to use transactions
The idea is to test that read time got passed along for transactions specifically. This will be necessary for snapshot reads to work.
Configuration menu - View commit details
-
Copy full SHA for e795c3a - Browse repository at this point
Copy the full SHA e795c3aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 851877c - Browse repository at this point
Copy the full SHA 851877cView commit details -
The before hook is not necessary. Just mock out the data client at the start.
Configuration menu - View commit details
-
Copy full SHA for b9bfd79 - Browse repository at this point
Copy the full SHA b9bfd79View commit details -
Remove unnecessary cherry picked files
Files were cherry-picked that weren’t helpful for solving the problem. Remove them.
Configuration menu - View commit details
-
Copy full SHA for 617b013 - Browse repository at this point
Copy the full SHA 617b013View commit details -
Configuration menu - View commit details
-
Copy full SHA for 4a32ad3 - Browse repository at this point
Copy the full SHA 4a32ad3View commit details -
Configuration menu - View commit details
-
Copy full SHA for 8f74353 - Browse repository at this point
Copy the full SHA 8f74353View commit details
Commits on Oct 18, 2023
-
Update the test so that it is run as a transaction
Right now, providing a transaction id is necessary to run the request as a transaction.
Configuration menu - View commit details
-
Copy full SHA for 4c9445c - Browse repository at this point
Copy the full SHA 4c9445cView commit details -
The integration test looks at the data from the snapshot read time for transactions and ensures that the read has no data thereby exercising the read time parameter.
Configuration menu - View commit details
-
Copy full SHA for 32729e1 - Browse repository at this point
Copy the full SHA 32729e1View commit details
Commits on Oct 30, 2023
-
Merge branch 'main' of https://github.com/googleapis/nodejs-datastore …
…into not-use-read-time-for-run-tx # Conflicts: # system-test/datastore.ts
Configuration menu - View commit details
-
Copy full SHA for 6ef2800 - Browse repository at this point
Copy the full SHA 6ef2800View commit details -
Fix the indents in the system test folder
Configuration menu - View commit details
-
Copy full SHA for 1354b47 - Browse repository at this point
Copy the full SHA 1354b47View commit details
Commits on Apr 4, 2024
-
Configuration menu - View commit details
-
Copy full SHA for 80ca7ec - Browse repository at this point
Copy the full SHA 80ca7ecView commit details -
Configuration menu - View commit details
-
Copy full SHA for 136f1b7 - Browse repository at this point
Copy the full SHA 136f1b7View commit details -
Merge branch 'not-use-read-time-for-run-tx' of https://github.com/dan…
…ieljbruce/nodejs-datastore into not-use-read-time-for-run-tx
Configuration menu - View commit details
-
Copy full SHA for 280244d - Browse repository at this point
Copy the full SHA 280244dView commit details -
beginTransaction needs to be mocked out now that a transaction will begin if runQuery is called.
Configuration menu - View commit details
-
Copy full SHA for 95d0d54 - Browse repository at this point
Copy the full SHA 95d0d54View commit details -
Add a sleep. Instead of changing the current test, add a new test because it means the reader of the PR can be sure that test coverage wasn’t reduced which is better.
Configuration menu - View commit details
-
Copy full SHA for aa4f125 - Browse repository at this point
Copy the full SHA aa4f125View commit details -
Modify the test so that sleeps are long enough to create predictable results and tests actually check for the right values.
Configuration menu - View commit details
-
Copy full SHA for b78b091 - Browse repository at this point
Copy the full SHA b78b091View commit details -
Replace with less precise assert
The test setup sometimes prepares before data with 0 entries and sometimes prepares before data with 1 entry so a less restrictive test is required in order for it to consistently pass.
Configuration menu - View commit details
-
Copy full SHA for cc72220 - Browse repository at this point
Copy the full SHA cc72220View commit details