Skip to content

Support numeric project number in GCP Batch service configuration#5275

Merged
PauloVLB merged 3 commits into
masterfrom
hotfix-add-project-number
May 13, 2026
Merged

Support numeric project number in GCP Batch service configuration#5275
PauloVLB merged 3 commits into
masterfrom
hotfix-add-project-number

Conversation

@PauloVLB
Copy link
Copy Markdown
Collaborator

@PauloVLB PauloVLB commented May 13, 2026

For context: b/512799286

Description

The GCP Batch API parent field does not support domain-scoped project IDs containing colons (e.g., google.com:clusterfuzz), leading to 400 parent field is invalid parser errors. Using the numeric project ID (project number) instead bypasses this routing issue.

This PR introduces support for configuring a numeric project ID via a new project-number attribute in the batch configuration.

Changes

  • Added a project_number field to BatchWorkloadSpec (defaulting to None).
  • Updated _get_specs_from_config to read project-number from configuration.
  • Fall back to the standard project string if project-number is not provided.
  • Construct the GCP Batch API parent resource path using the resolved project_number when present.

@PauloVLB PauloVLB requested a review from a team as a code owner May 13, 2026 21:34
@PauloVLB PauloVLB requested review from ViniciustCosta and decoNR May 13, 2026 21:37
@PauloVLB PauloVLB merged commit 1ff3109 into master May 13, 2026
10 checks passed
@PauloVLB PauloVLB deleted the hotfix-add-project-number branch May 13, 2026 22:00
@PauloVLB PauloVLB changed the title add project number from batch.yaml for creating batch jobs Support numeric project number in GCP Batch service configuration May 14, 2026
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