Skip to content

Add missing fields to properly list partitioned tables - #4306

Closed
vvviiimmm wants to merge 3 commits into
googleapis:masterfrom
vvviiimmm:partitioned-tables-info
Closed

Add missing fields to properly list partitioned tables#4306
vvviiimmm wants to merge 3 commits into
googleapis:masterfrom
vvviiimmm:partitioned-tables-info

Conversation

@vvviiimmm

Copy link
Copy Markdown

While getting the list of tables (list endpoint) the information about partitioning and creation time is getting lost. Somewhat related to #3097.

@vvviiimmm
vvviiimmm requested a review from a teamJanuary 8, 2019 15:36
@googlebotgooglebot added the cla: yes This human has signed the Contributor License Agreement. label Jan 8, 2019
@JesseLovelaceJesseLovelace added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Jan 8, 2019
@yoshi-kokoroyoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Jan 8, 2019
@JesseLovelaceJesseLovelace added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Jan 9, 2019
@yoshi-kokoroyoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Jan 9, 2019

@JesseLovelaceJesseLovelace left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the pr! Could you add a simple test?

@JesseLovelaceJesseLovelace added needs tests api: bigquery Issues related to the BigQuery API. labels Jan 9, 2019
@vvviiimmm

Copy link
Copy Markdown
Author

Added a unit test but since everything is mocked it doesn't actually call HttpBigQueryRpc.listTables (nor as any other listTables test). Please let me know if there is any other way to properly test this change.

@JesseLovelace

Copy link
Copy Markdown
Contributor

There's a non-mocked integration test for list tables in ITBigQueryTest which you could add to, or write a new IT based on it

@vvviiimmm

Copy link
Copy Markdown
Author

Thanks. I wasn't able to run the ITBigQueryTests due to ITBigQueryTest.beforeClass throws java.lang.IllegalArgumentException: A project ID is required for this service but could not be determined from the builder or the environment. Please set a project ID using the builder.. Trying things with a builder didn't help, getting null pointer exceptions. Are there any prerequisite for executing integration tests?

@JesseLovelace

Copy link
Copy Markdown
Contributor

You'll need to set the environment variables GOOGLE_CLOUD_PROJECT and GOOGLE_APPLICATION_CREDENTIALS to specify the project for the test to run on and the credentials json file for that account

@chingor13

Copy link
Copy Markdown
Contributor

The BigtableIT tests may require configuration via system properties. For CI, we set them here. We set bigtable.env, bigtable.project, bigtable.instance, and bigtable.bigtable.

@vvviiimmm

Copy link
Copy Markdown
Author

Thanks guys, I found the env variables needed but obviously I don't have credentials to access that project so the test fails on 401 Unauthorized

@JesseLovelaceJesseLovelace added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Jan 22, 2019
@yoshi-kokoroyoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Jan 22, 2019
@JesseLovelace

Copy link
Copy Markdown
Contributor

The idea would be to use your own project instead to test, setting the values of the environment variables to be your own project and credentials

@JustinBeckwithJustinBeckwith added the 🚨 critical P0 critical issue. Requires immediate fix label Feb 7, 2019
@yoshi-automationyoshi-automation added 🚨 critical P0 critical issue. Requires immediate fix and removed 🚨 critical P0 critical issue. Requires immediate fix labels Feb 7, 2019
@sduskis

Copy link
Copy Markdown
Contributor

@vvviiimmm, please run the following command to clean up the code formatting:

mvn com.coveo:fmt-maven-plugin:format

@sduskissduskis added status: blocked Resolving the issue is dependent on other work. and removed 🚨 critical P0 critical issue. Requires immediate fix labels Feb 11, 2019
@sduskis

Copy link
Copy Markdown
Contributor

@vvviiimmm, please run the following command to clean up the code formatting:

mvn com.coveo:fmt-maven-plugin:format

@pmakanipmakani added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Feb 14, 2019
@yoshi-kokoroyoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Feb 14, 2019
@codecov

codecovBot commented Feb 14, 2019

Copy link
Copy Markdown

Codecov Report

Merging #4306 into master will decrease coverage by <.01%.
The diff coverage is 0%.

Impacted file tree graph

@@ Coverage Diff @@## master #4306 +/- ##
============================================
- Coverage 49.17% 49.16% -0.01% - Complexity 20988 21915 +927 
============================================
Files 1996 2078 +82 Lines 194629 207084 +12455 Branches 21796 24084 +2288 ============================================
+ Hits 95702 101813 +6111 - Misses 90817 97128 +6311 - Partials 8110 8143 +33
Impacted FilesCoverage ΔComplexity Δ
.../google/cloud/bigquery/spi/v2/HttpBigQueryRpc.java6.92% <0%> (-0.71%)2 <0> (ø)
...loud/bigtable/data/v2/internal/RequestContext.java33.33% <0%> (-66.67%)2% <0%> (ø)
...le/cloud/bigtable/data/v2/models/InstanceName.java0% <0%> (-28.13%)0% <0%> (-7%)
.../cloud/scheduler/v1beta1/CloudSchedulerClient.java54.54% <0%> (-20.46%)35% <0%> (+4%)
...om/google/cloud/bigtable/data/v2/models/Query.java68.36% <0%> (-9.14%)23% <0%> (+3%)
...om/google/cloud/grpc/BaseGrpcServiceException.java68.42% <0%> (-9%)3% <0%> (ø)
...ble/data/v2/stub/EnhancedBigtableStubSettings.java93.19% <0%> (-5.94%)15% <0%> (+2%)
...com/google/cloud/compute/v1/stub/SnapshotStub.java11.11% <0%> (-5.56%)1% <0%> (ø)
...le/cloud/compute/v1/stub/InstanceTemplateStub.java11.11% <0%> (-5.56%)1% <0%> (ø)
...src/main/java/com/google/cloud/bigquery/JobId.java94.73% <0%> (-5.27%)10% <0%> (+1%)
... and 1611 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 395b016...c339196. Read the comment docs.

@JustinBeckwith

Copy link
Copy Markdown
Contributor

@JesseLovelace@kolea2 is this something we should:

  • accept as is?
  • try to fix it up?
  • close it out?

@sduskis

Copy link
Copy Markdown
Contributor

@JesseLovelace, can you please finish this review?

@sduskissduskis left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We do need an IT request for this.

@pmakani, can you please raise a new PR with this change, and add something to the IT test to test this change?

@pmakani

Copy link
Copy Markdown

@sduskis sure, i will add that to IT test and raise a new PR.

@sduskis

Copy link
Copy Markdown
Contributor

This is replaced by #4701 which includes these changes + integration tests

@sduskissduskis closed this Mar 20, 2019
chingor13 pushed a commit that referenced this pull request Mar 24, 2026
* chore: Add gcp resource name span attribute
* Update google-cloud-spanner/src/test/java/com/google/cloud/spanner/OpenTelemetrySpanTest.java
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
* chore: Add gcp resource name span attribute
---------
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api: bigqueryIssues related to the BigQuery API.cla: yesThis human has signed the Contributor License Agreement.needs testsstatus: blockedResolving the issue is dependent on other work.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants

@vvviiimmm@JesseLovelace@chingor13@sduskis@JustinBeckwith@pmakani@googlebot@yoshi-automation@yoshi-kokoro