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

changefeedccl: fix pubsub v2 unit tests on AWS #101130

Merged
merged 1 commit into from
Apr 10, 2023

Conversation

samiskin
Copy link
Contributor

@samiskin samiskin commented Apr 10, 2023

Resolves #100968
Resolves #100969
Resolves #100970
Resolves #100971
Resolves #100972
Resolves #100973
Resolves #100974
Resolves #100985
Resolves #100986
Resolves #100987
Resolves #100988
Resolves #101014
Resolves #101015
Resolves #101016
Resolves #101017
Resolves #101018
Resolves #101019
Resolves #101020
Resolves #101030
Resolves #101031
Resolves #101032
Resolves #101033
Resolves #101034
Resolves #101035
Resolves #101036
Resolves #101040
Resolves #101041
Resolves #101042
Resolves #101043
Resolves #101044
Resolves #101045
Resolves #101062
Resolves #101063
Resolves #101064
Resolves #101065
Resolves #101066
Resolves #101067
Resolves #101079
Resolves #101080
Resolves #101081
Resolves #101082
Resolves #101083
Resolves #101084
Resolves #101085
Resolves #101086
Resolves #101099
Resolves #101100
Resolves #101106
Resolves #101107
Resolves #101113
Resolves #101114
Resolves #101115

The pubsub V2 tests would fail with

failed to start feed for job 0: pq: opening client: google: could not find
default credentials. See
https://developers.google.com/accounts/docs/application-default-credentials for
more information

only on release-23.1 test runs because every other test was running on google cloud machines, where you didn't need to even have gcloud installed for it to work. This happens only on the initial attempt to initialize a PubsubClient when the GRPCConn is not overriden.

This PR fixes it by skipping initialization entirely so that we don't have to deal with errors like this or having ensure the old connection is cleaned up before setting the mock one.

Release note: None

The pubsub V2 tests would fail with
```
failed to start feed for job 0: pq: opening client: google: could not find
default credentials. See
https://developers.google.com/accounts/docs/application-default-credentials for
more information
```
only on release-23.1 test runs because every other test was running on google
cloud machines, where you didn't need to even have `gcloud` installed for it to
work.  This happens only on the initial attempt to initialize a PubsubClient
when the GRPCConn is not overriden.

This PR fixes it by skipping initialization entirely so that we don't have to
deal with errors like this or having ensure the old connection is cleaned up
before setting the mock one.

Release note: None

<what was there before: Previously, ...>
<why it needed to change: This was inadequate because ...>
<what you did about it: To address this, this patch ...>
@samiskin samiskin requested a review from a team as a code owner April 10, 2023 17:16
@samiskin samiskin requested review from jayshrivastava and removed request for a team April 10, 2023 17:16
@cockroach-teamcity
Copy link
Member

This change is Reviewable

@samiskin samiskin added the backport-23.1.x Flags PRs that need to be backported to 23.1 label Apr 10, 2023
@samiskin
Copy link
Contributor Author

bors r+

@craig
Copy link
Contributor

craig bot commented Apr 10, 2023

Build failed (retrying...):

@samiskin
Copy link
Contributor Author

bors r+

@craig
Copy link
Contributor

craig bot commented Apr 10, 2023

Already running a review

@craig
Copy link
Contributor

craig bot commented Apr 10, 2023

Build failed (retrying...):

@craig
Copy link
Contributor

craig bot commented Apr 10, 2023

Build succeeded:

@craig craig bot merged commit 9c55b61 into cockroachdb:master Apr 10, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment