chore: migrate google-cloud-vectorsearch to librarian#8571
Conversation
There was a problem hiding this comment.
Code Review
This pull request enables generation for the Vector Search API by removing the skip_generate flag in librarian.yaml, deleting several configuration and documentation files, and updating the repository metadata. It also changes the default exported clients in packages/google-cloud-vectorsearch/src/index.ts from the stable v1 version to the v1beta version. Feedback was provided regarding this change, noting that switching the default export to a beta version is a breaking change for existing consumers. The reviewer recommended updating the configuration in librarian.yaml to use v1 as the default version instead of manually modifying the generated client files.
| const DataObjectSearchServiceClient = v1beta.DataObjectSearchServiceClient; | ||
| type DataObjectSearchServiceClient = v1beta.DataObjectSearchServiceClient; | ||
| const DataObjectServiceClient = v1beta.DataObjectServiceClient; | ||
| type DataObjectServiceClient = v1beta.DataObjectServiceClient; | ||
| const VectorSearchServiceClient = v1beta.VectorSearchServiceClient; | ||
| type VectorSearchServiceClient = v1beta.VectorSearchServiceClient; |
There was a problem hiding this comment.
Changing the default exported client from the stable v1 version to the beta v1beta version is a breaking change for existing consumers of this package.
Since v1 is already released and was previously the default export, we should preserve it as the default. To fix this, please update the default_version in librarian.yaml to v1 and regenerate the library:
nodejs:
default_version: v1References
- Do not manually edit generated TypeScript client files. Any changes or updates must be made upstream in the generator.
This addresses situations where .repo-metadata.json and index.ts effectively disagree on the default API version for a package. The fix favors the version in index.ts, for the sake of compatibility. Once this is merged, googleapis#8556, googleapis#8571 and googleapis#8480 should be regenerated. Fixes googleapis/librarian#6382
This addresses situations where .repo-metadata.json and index.ts effectively disagree on the default API version for a package. The fix favors the version in index.ts, for the sake of compatibility. Once this is merged, #8556, #8571 and #8480 should be regenerated. Fixes googleapis/librarian#6382
b726275 to
c2ba8e4
Compare
| "api_id": "vectorsearch.googleapis.com", | ||
| "api_shortname": "vectorsearch", | ||
| "client_documentation": "https://cloud.google.com/nodejs/docs/reference/vectorsearch/latest", | ||
| "default_version": "v1", |
There was a problem hiding this comment.
This change is due to the previous repo-metadata being out of date with respect to Bazel and index.ts
No description provided.