Skip to content

feat: update API sources and regenerate - #9849

Open
JoeWang1127 wants to merge 4 commits into
mainfrom
update-sources-googleapis
Open

JoeWang1127 wants to merge 4 commits into
mainfrom
update-sources-googleapis

Conversation

@JoeWang1127

@JoeWang1127 JoeWang1127 commented Nov 10, 2026 •

Copy link
Copy Markdown
Contributor

Update googleapis sources to a74d0502444d12c07abc7ed95f90ebb52950e918 and regenerate all libraries.

Why Chronicle was updated with Backstory protos

The updated googleapis sources introduce new dependencies in the Chronicle API (google.cloud.chronicle.v1), where protos (e.g. Watchlist and EntityServiceClient) reference unversioned Backstory protos (backstory/entity.proto and associated UDM proto definitions).

Because PHP does not maintain a standalone google/backstory client package, the backstory proto definitions are generated and bundled directly within the Chronicle component (google/cloud-chronicle):

  • Configured additional_protos: [path: backstory] in librarian.yaml for Chronicle.
  • Updated Chronicle/owlbot.py to copy generated backstory protos into Chronicle/src/Backstory and Chronicle/metadata/Backstory.
  • Added PSR-4 autoloading for Google\Backstory\ and GPBMetadata\Backstory\ in Chronicle/composer.json and the root composer.json to avoid Class "GPBMetadata\Backstory\Entity" not found errors during runtime and test execution.
  • Excluded Chronicle/src/Backstory from phpcs-ruleset.xml and .php-cs-fixer.dist.php to align with the repository's rules for generated unversioned proto code.

Debug Info

System Details

  • OS: Linux x86_64
  • PHP: 8.2
  • Librarian version: v0.52.0

Commands Executed

  • librarian update sources.googleapis
  • librarian install
  • librarian generate --all
  • librarian tidy
  • git add .
  • git commit -m "feat: update API sources and regenerate"

@JoeWang1127
JoeWang1127 marked this pull request as ready for review November 10, 2026 16:24
@JoeWang1127
JoeWang1127 requested review from a team as code owners November 10, 2026 16:24
@snippet-bot

snippet-bot Bot commented Nov 10, 2026 •

Copy link
Copy Markdown

Here is the summary of changes.

You are about to add 104 region tags.

This comment is generated by snippet-bot.
If you find problems with this result, please file an issue at:
https://github.com/googleapis/repo-automation-bots/issues.
To update this comment, add snippet-bot:force-run label or use the checkbox below:

  • Refresh this comment

@JoeWang1127
JoeWang1127 enabled auto-merge (squash) November 10, 2026 22:08
Comment thread Chronicle/owlbot.py
Comment on lines +36 to +39
backstory_proto_src = src / "backstory/proto/src"
if backstory_proto_src.is_dir():
s.move([backstory_proto_src / "Google/Backstory"], dest / "src/Backstory")
s.move([backstory_proto_src / "GPBMetadata/Backstory"], dest / "metadata/Backstory")

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 this occasionally when we don't feel like it is necessary to create a new package (and incur all the overhead involved with maintaining it). As these are unversioned, they would be similar to the "CommonProtos" that we have for other components (CloudCommonProtos, CommonProtos, GeoCommonProtos, ShoppingCommonProtos). So I'd say what we have here is FINE as long as we don't expect to have other components using Backstory. If we DO, then I'd say we should split this into a new package (such as ChronicleCommonProtos`).

The good news is, with composer magic, we can always consolidate today and split this out into a separate package later on, without breaking anybody.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants