Skip to content

Conversation

@erezrokah
Copy link
Member

Summary

Extracted from #8156.
The new SDK adds a new test:

  1. Create initial scheme and write stuff
  2. Add a new column
  3. Migrate to new schema
  4. Write more stuff
  5. Validate new stuff was created

BiqQuery can have a few minutes delay until the schema is updated, so the new test fails when validating the new data (the data is missing the new column).
This PR adds a test configuration to wait additional time for schema propagation. Another option is to skip the test

@erezrokah erezrokah requested review from a team, amanenk and hermanschaaf and removed request for a team and amanenk February 19, 2023 15:43
@yevgenypats
Copy link
Contributor

Looks good but seems tests still fail, is it because of the timeout? I would prefer the delay instead of failing the tests

@erezrokah
Copy link
Member Author

Looks good but seems tests still fail, is it because of the timeout? I would prefer the delay instead of failing the tests

I'm taking another look, there might be an additional issue regarding comparison order similar to cloudquery/plugin-sdk#565 and cloudquery/plugin-sdk#561

@erezrokah erezrokah changed the title feat(deps): Update BigQuery plugin-sdk to v1.38.1 feat(deps): Update BigQuery plugin-sdk to v1.38.2 Feb 20, 2023
@erezrokah erezrokah force-pushed the feat/update_bigquery_sdk branch from 9b0c257 to 997f04e Compare February 20, 2023 13:19
@erezrokah erezrokah force-pushed the feat/update_bigquery_sdk branch from 997f04e to a876057 Compare February 20, 2023 13:21
@erezrokah erezrokah self-assigned this Feb 20, 2023
@erezrokah erezrokah added the automerge Automatically merge once required checks pass label Feb 21, 2023
@hermanschaaf
Copy link
Member

hermanschaaf commented Feb 21, 2023

Looks like the tests are now failing @erezrokah:

--- FAIL: TestPlugin (368.79s)
    --- FAIL: TestPlugin/TestMigrateAppend (246.12s)
        --- FAIL: TestPlugin/TestMigrateAppend/add_column (123.29s)
            plugin_testing_migrate.go:67: 
                	Error Trace:	/home/runner/work/cloudquery/cloudquery/plugins/destination/bigquery/client/plugin_testing_migrate.go:67
                	            				/home/runner/work/cloudquery/cloudquery/plugins/destination/bigquery/client/plugin_testing_migrate.go:119
                	Error:      	[]schema.CQTypes{schema.CQTypes{(*schema.Text)(0xc0004c07b0), (*schema.Timestamptz)(0xc0000886e0), (*schema.UUID)(0xc000044780), (*schema.UUID)(0xc000044798), (*schema.Bool)(0xc00040661e)}, schema.CQTypes{(*schema.Text)(0xc0004c07c8), (*schema.Timestamptz)(0xc000088700), (*schema.UUID)(0xc0000447b0), (*schema.UUID)(0xc0000447c8), (*schema.Bool)(0xc00040662e)}} does not contain schema.CQTypes{(*schema.Text)(0xc00029c0d8), (*schema.Timestamptz)(0xc0001fe1a0), (*schema.UUID)(0xc0002d60a8), (*schema.UUID)(0xc0002d61e0), (*schema.Bool)(0xc00003e98e)}
                	Test:       	TestPlugin/TestMigrateAppend/add_column

@erezrokah
Copy link
Member Author

Looks like the tests are now failing @erezrokah:

Yeah, I think I'll either need to increase the wait time or use an emulator. It's already quite slow to test, so I'll try the emulator

@erezrokah erezrokah removed the automerge Automatically merge once required checks pass label Feb 21, 2023
@erezrokah erezrokah marked this pull request as draft February 21, 2023 10:41
@erezrokah
Copy link
Member Author

Tried the emulator but ran into goccy/bigquery-emulator#150

@erezrokah
Copy link
Member Author

erezrokah commented Feb 22, 2023

I'll give the test delay one more go. If it doesn't work we'll have to disable some of the tests otherwise they will take too long

@erezrokah erezrokah force-pushed the feat/update_bigquery_sdk branch from 021984d to 0cff5ed Compare February 22, 2023 17:28
@erezrokah erezrokah added the automerge Automatically merge once required checks pass label Feb 22, 2023
@erezrokah
Copy link
Member Author

Decided to skip the migrate test for now

@erezrokah erezrokah force-pushed the feat/update_bigquery_sdk branch from 0f5042f to 425ccad Compare February 22, 2023 17:30
@erezrokah erezrokah force-pushed the feat/update_bigquery_sdk branch from a7561d6 to de2abb2 Compare February 22, 2023 17:31
@erezrokah erezrokah changed the title feat(deps): Update BigQuery plugin-sdk to v1.38.2 feat(deps): Update BigQuery plugin-sdk to v1.39.0 Feb 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

automerge Automatically merge once required checks pass

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants