You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Migrate policy evaluation consumers to read from CAS instead of inline predicate #2950
In #2949 we introduced PolicyEvaluationBundle CAS storage: during attestation push, policy evaluations are serialized as a protobuf bundle, uploaded to CAS, and referenced from the attestation predicate via policyEvaluationsRef (a ResourceDescriptor with digest and media type). The inline policyEvaluations field in the predicate is now marked as deprecated.
Problem
Today, all consumers read policy evaluations from the inline policyEvaluations field embedded in the attestation predicate JSON stored in the database. This is the field we want to eventually remove to reduce attestation envelope bloat.
Update GetPolicyEvaluations() (or its callers) to:
Check if policyEvaluationsRef exists in the predicate
If yes, download the PolicyEvaluationBundle from CAS using the digest, deserialize, and return
If no ref (older attestations), fall back to the inline policyEvaluations field
Once all consumers have migrated, the inline policyEvaluations field can be stripped or reduced from the predicate during rendering, completing the attestation size reduction.
Considerations
The control plane needs CAS download capabilities (already available via pkg/blobmanager/ Downloader interface)
CAS downloads add latency; caching should be considered for frequently accessed attestations
Backward compatibility with older attestations that only have inline data must be preserved
Activity
feat: resolve policy evaluations from CAS in workflow-run View API
feat: resolve policy evaluations from CAS in workflow-run View API
feat: resolve policy evaluations from CAS in workflow-run View API
feat: resolve policy evaluations from CAS in workflow-run View API