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

Bump cloud.google.com/go/spanner from 1.42.0 to 1.45.1-0.20230421054906-c65254ce3c22 #2957

Merged

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Apr 10, 2023

Bumps cloud.google.com/go/spanner from 1.42.0 to 1.45.0.

Release notes

Sourced from cloud.google.com/go/spanner's releases.

spanner: v1.45.0

1.45.0 (2023-04-10)

Features

  • spanner/spansql: Add support for missing DDL syntax for ALTER CHANGE STREAM (#7429) (d34fe02)
  • spanner/spansql: Support fine-grained access control DDL syntax (#6691) (a7edf6b)
  • spanner/spansql: Support grant/revoke view, change stream, table function (#7533) (9c61215)
  • spanner: Add x-goog-spanner-route-to-leader header to Spanner RPC contexts for RW/PDML transactions. (#7500) (fcab05f)
  • spanner: Adding new fields for Serverless analytics (69067f8)
  • spanner: Enable custom decoding for list value (#7463) (3aeadcd)
  • spanner: Update iam and longrunning deps (91a1f78)

Bug Fixes

  • spanner/spansql: Fix SQL for CREATE CHANGE STREAM TableName; case (#7514) (fc5fd86)
  • spanner: Correcting the proto field Id for field data_boost_enabled (00fff3a)
Commits
  • c43900b chore(main): release spanner 1.45.0 (#7462)
  • 688d4ab fix: deadlock with inline begin transaction when first statement response is ...
  • 7afc98a chore(internal/postprocessor): add MoveSnippets to main.go (#7523)
  • a6c6701 refactor(bigquery): amend name for MaxTimeTravel on datasets (#7707)
  • 22a666c feat(bigquery): expose dataset MaxTimeTravelHours (#7706)
  • 3b8bfb4 feat(bigquery/storage/managedwriter): expose connection multiplexing as exper...
  • e660af8 chore: cleanup gapicgen a bit (#7703)
  • 4fedc34 chore(storage): handle object metadata (grpc) (#7688)
  • 2a5c165 chore: onboard compute to owlbot (#7705)
  • 7a9e211 feat(bigquery): Add Iceberg as DataFormat option. (#7155)
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

@dependabot dependabot bot requested a review from a team as a code owner April 10, 2023 22:07
@dependabot dependabot bot requested a review from getagit April 10, 2023 22:07
@dependabot dependabot bot added dependencies Pull requests that update a dependency file go Pull requests that update Go code labels Apr 10, 2023
@dependabot dependabot bot requested review from hickford and pphaneuf April 10, 2023 22:07
@dependabot dependabot bot force-pushed the dependabot/go_modules/cloud.google.com/go/spanner-1.45.0 branch from aab8bb8 to dc71ff5 Compare April 11, 2023 14:43
@roger2hk
Copy link
Contributor

/gcbrun

2 similar comments
@roger2hk
Copy link
Contributor

/gcbrun

@roger2hk
Copy link
Contributor

/gcbrun

@roger2hk
Copy link
Contributor

We are hitting another obstacle. The error cannot use a closed transaction comes from these lines.

https://github.com/googleapis/google-cloud-go/blob/69362ceb59c35f8c29869e018a5d5847cb9d69aa/spanner/transaction.go#L553-L556

@mhutchinson
Copy link
Contributor

mhutchinson commented Apr 12, 2023

Thanks for looking into this @roger2hk. It looks like this is deep inside the internals of the spanner transaction. What I'm seeing is the transaction being released which marks it as closed.

Within our code, the transaction has state txNew before ls.begin (https://github.com/google/trillian/blob/master/storage/cloudspanner/log_storage.go#L205), but has txClosed afterwards. This causes the function invoked on line 209 to then fail.

What I haven't yet determined is whether this is a bug in the spanner library, or whether we've always been doing something wrong here and it's only coming to light now.

(edit: what I should have added is that in the previous version of the spanner library the tx state was always txActive)

@mhutchinson
Copy link
Contributor

mhutchinson commented Apr 12, 2023

https://github.com/google/trillian/blob/master/storage/cloudspanner/tree_storage.go#L108

Before stx.Query the state of stx is txNew, after the call to Query it is txInit, and after the call to rows.Do is complete it is txClosed. This is because the RowIterator.Stop method calls release, which leads to this odd little bit of code that suggests what it thinks it is doing is explicitly starting a transaction (where AFAICT, it is actually closing it): https://github.com/googleapis/google-cloud-go/blob/69362ceb59c35f8c29869e018a5d5847cb9d69aa/spanner/transaction.go#L1293

(edit: git blame shows this bit of code is only 2 days old: googleapis/google-cloud-go#7712)

@mhutchinson
Copy link
Contributor

Out of curiosity I synced to the commit before that PR. At that version, the tests timeout due to the deadlock that the PR fixes. go get cloud.google.com/go/spanner@7afc98a698a0857c33f14c94a72ae2510919537d

It looks like there are a lot of big breaking changes going into this library at the current time. We need to step back and determine whether we get actively involved in this, or whether we stay with the current working version of this library, let the dust settle from these changes, and then hope that things are working again.

@roger2hk
Copy link
Contributor

Thanks @rahul2393 for looking into this.

@roger2hk roger2hk force-pushed the dependabot/go_modules/cloud.google.com/go/spanner-1.45.0 branch from 63a6ade to 3f56694 Compare April 21, 2023 12:41
@roger2hk
Copy link
Contributor

/gcbrun

@roger2hk roger2hk changed the title Bump cloud.google.com/go/spanner from 1.42.0 to 1.45.0 Bump cloud.google.com/go/spanner from 1.42.0 to 1.45.1-0.20230421054906-c65254ce3c22 Apr 21, 2023
@roger2hk
Copy link
Contributor

Issue fixed in googleapis/google-cloud-go#7809 but 1.45.1 is not yet released (googleapis/google-cloud-go#7767).

@mhutchinson Please review to see if it's good to go.

@roger2hk
Copy link
Contributor

v1.45.1 was just released by @Rahul2923. I will let Dependabot handle the remaining upgrade.

@roger2hk roger2hk merged commit 4d4e40c into master Apr 21, 2023
@roger2hk roger2hk deleted the dependabot/go_modules/cloud.google.com/go/spanner-1.45.0 branch April 21, 2023 12:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file go Pull requests that update Go code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants