← Back to Pull requests

Greenfield: Prepopulate direct KRM types, identity, and judgement queue for CloudDeployRelease #15886

Closed
unknown closed this pull request without merging on Nov 17, 2026 20:29 UTC
View on GitHub
unknown unknown commented on Nov 17, 2026 01:16 UTC
Author

Prepopulate direct KRM types, identity, reference, CRD, and judgement_queue.yaml for CloudDeployRelease under clouddeploy.cnrm.cloud.google.com/v1alpha1 following Greenfield Step 1a (.gemini/skills/kcc-direct-greenfield-types-implementer/prepopulate/SKILL.md):

  • Configured apis/clouddeploy/generate.sh with generate-types --prepopulate-resource --allow-non-declarative, generate-identity, and updated generate-mapper with --prepopulate-resource for CloudDeployRelease:Release.

  • Generated direct KRM types in apis/clouddeploy/v1alpha1/clouddeployrelease_types.go, types.generated.go, and deepcopy methods.

  • Generated deterministic IdentityV2 and refs.Ref implementations along with conformance unit tests (clouddeployrelease_identity.generated.go, clouddeployrelease_reference.generated.go, clouddeployrelease_identity_generated_test.go).

  • Emitted CRD manifest config/crds/resources/apiextensions.k8s.io_v1_customresourcedefinition_clouddeployreleases.clouddeploy.cnrm.cloud.google.com.yaml.

  • Added CloudDeployRelease to BLOCKED_KINDS in dev/tasks/build-release-bundle.

  • Recorded open review items in apis/clouddeploy/judgement_queue.yaml with reason: untriaged-bulk-generation with status: open for Step 1b triage.

  • Added clouddeployreleases.clouddeploy.cnrm.cloud.google.com to knownInvalidCRDs in tests/apichecks/crds_test.go due to output-only message TargetArtifact.

  • Synchronized tests/apichecks/testdata/exceptions/ golden files (alpha-missingfields.txt, no_refs_in_status.txt, refs_not_representable.txt, spec_dislike_etag.txt).

  • Documented service learnings in .gemini/journals/clouddeploy.md.
  • Fixes #15879

    ``release-note
    NONE
    `

    Review Instructions

    Use .gemini/skills/reviewgen-greenfield-new-types/SKILL.md to conduct the review.

    KCC Greenfield Step 1 (Prepopulate) Auto-Review Results


    Trigger criteria matched: Yes
    generate.sh & Flags Check: Pass - (generate-types --prepopulate-resource --allow-non-declarative, generate-identity, generate-mapper --prepopulate-resource, GA proto google.cloud.deploy.v1)
    Judgement Queue Open Check: Pass - (
    apis/clouddeploy/judgement_queue.yaml contains reason: untriaged-bulk-generation with status: open and zero premature resolutions)
    Mechanical Output & Idempotency: Pass - (./apis/clouddeploy/generate.sh produces zero uncommitted diffs; generated files are pure mechanical output)
    Release Bundle Blocklist (
    BLOCKED_KINDS): Pass - (CloudDeployRelease added in alphabetical order to BLOCKED_KINDS in dev/tasks/build-release-bundle)
    Mapper Compilation & apichecks: Pass - (apis/clouddeploy/... and pkg/controller/direct/clouddeploy/... build cleanly and all unit and apichecks tests pass)

    Detailed Findings / Actions Required:


    None. All Greenfield Step 1a criteria and invariants are satisfied.

    This pull request was generated by an AI coding agent.

    <sub>🤖 Agent session</sub>

    <!-- factory:task-output kind=Change task=recipe-fix-20261117-001205-ef9f -->

    ---

    Greenfield: Triage judgement queue and finalize direct KRM types and identity for CloudDeployRelease

    Triaged apis/clouddeploy/judgement_queue.yaml and finalized direct KRM types, identity, and references for CloudDeployRelease under clouddeploy.cnrm.cloud.google.com/v1alpha1 following Greenfield Step 1b:

  • Resolved all open review items in apis/clouddeploy/judgement_queue.yaml for CloudDeployRelease.

  • Reused apis/clouddeploy/v1beta1/clouddeploydeliverypipeline_reference.go (DeliveryPipelineRef), updating it to implement refs.Ref while preserving NormalizedExternal for backwards compatibility.

  • Replaced projectRef and location in CloudDeployReleaseSpec with a single required and immutable spec.parentRef *v1beta1.DeliveryPipelineRef per Case B child resource conventions.

  • Removed top-level labels from CloudDeployReleaseSpec (reconciled via metadata.labels) and moved etag to CloudDeployReleaseObservedState.

  • Updated documentation URL to https://cloud.google.com/deploy/docs/reference/rest/v1/projects.locations.deliveryPipelines.releases and stripped all guess annotations.

  • Accepted skaffoldConfigURI as reference-not-representable (GCS archive path) and verified message-map-derived fields.

  • Regenerated types, identity, deepcopy, CRD, and mapper code via ./apis/clouddeploy/generate.sh.

  • Removed clouddeployreleases from spec_dislike_etag.txt and updated alpha-missingfields.txt.

  • Added comprehensive unit tests in apis/clouddeploy/v1alpha1/clouddeployrelease_identity_test.go`.
  • Fixes #15896

    This pull request was generated by an AI coding agent.

    <!-- factory:group-step issue=15896 -->

    Diff: 608 lines (+456 / -152) across 7 files Reviewer: ada-coder-bot Review duration: 1152m
    All Vouch review confidence checks passed
    Residual risk 0.34 = Change Risk (0.78) × (1 − Review Confidence (0.57)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.78 · 608 lines diff across 7 files
    0.78
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    56%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.384
    Shallow Review Depth shallow_review_depth
    0.289
    Sensitive Paths sensitive_paths
    0.078
    Ai Authored ai_authored
    0.050
    Real PR Conversation Timeline
    1 comments
    "Review active on #15886"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 56.8% reviewed sensitive_module
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 78.3% (HIGH) · Higher = larger blast radius
    78.3%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 56.8% · Lower = rushed or shallow review
    56.8%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 33.9% · Safe to merge
    33.9%