Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support generate_name in the API server model #499

Merged
merged 12 commits into from
Jul 17, 2024
Merged

Conversation

marshtompsxd
Copy link
Collaborator

@marshtompsxd marshtompsxd commented Jun 25, 2024

This PR revises the API server model to allow resource creation requests that carry a generate_name rather than a name. For such requests, the API server will generate a unique name for the object and create the object with the generated name. Before the revision, such requests are rejected by our model. We do not specify the details on how the API server guarantees the uniqueness of the generated name, but rather use a trusted proof function saying that the generated name is different from any existing names. Note that this trusted proof is better written as a "spec ensures" once that gets supported by Verus.

We make this revision mainly to enable verifying Kubernetes core controllers such as the ReplicaSet controller that often creates pods with generate_name.

This revision breaks many proofs of the custom controllers we have built, but it is straightforward to fix these broken proofs. In most cases, we only need to say that there does not exist any create request that might create the "same" object.

@marshtompsxd marshtompsxd changed the title Add support for generate_name Support generate_name in the API server model Jul 17, 2024
@marshtompsxd marshtompsxd added this pull request to the merge queue Jul 17, 2024
Merged via the queue into main with commit 7248da5 Jul 17, 2024
14 checks passed
@marshtompsxd marshtompsxd deleted the xudong/generate-name branch August 17, 2024 14:52
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.

1 participant