Skip to content

Fix validation issue of lastModifier for configuration and routes - #6072

Merged
knative-prow-robot merged 2 commits into
knative:masterfrom
savitaashture:issue-5964
Nov 27, 2019
Merged

Fix validation issue of lastModifier for configuration and routes#6072
knative-prow-robot merged 2 commits into
knative:masterfrom
savitaashture:issue-5964

Conversation

@savitaashture

Copy link
Copy Markdown
Contributor

Fixes #5964

Proposed Changes

  • add changes to configuration and routes to validate serving.knative.dev/creator and serving.knative.dev/lastModifier when ownerReference is nil

Release Note

None

@googlebot googlebot added the cla: yes Indicates the PR's author has signed the CLA. label Nov 20, 2019
@knative-prow-robot knative-prow-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. area/API API objects and controllers labels Nov 20, 2019

@knative-prow-robot knative-prow-robot left a comment

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.

@savitaashture: 0 warnings.

Details

In response to this:

Fixes #5964

Proposed Changes

  • add changes to configuration and routes to validate serving.knative.dev/creator and serving.knative.dev/lastModifier when ownerReference is nil

Release Note

None

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@vagababov vagababov left a comment

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.

Please add unit tests.

original := apis.GetBaseline(ctx).(*Configuration)
errs = errs.Also(apis.ValidateCreatorAndModifier(original.Spec, c.Spec, original.GetAnnotations(),
c.GetAnnotations(), serving.GroupName).ViaField("metadata.annotations"))
if c.OwnerReferences == nil {

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.

I think all those deserve a comment

@knative-prow-robot knative-prow-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Nov 24, 2019
@savitaashture

Copy link
Copy Markdown
Contributor Author

@vagababov
Handled review comments would you mind to have a look again please

@vagababov vagababov left a comment

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.

/lgtm
/approve

@knative-prow-robot knative-prow-robot added the lgtm Indicates that a PR is ready to be merged. label Nov 25, 2019
@dgerd

dgerd commented Nov 27, 2019

Copy link
Copy Markdown

/approve

@knative-prow-robot

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: dgerd, savitaashture, vagababov

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@knative-prow-robot knative-prow-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Nov 27, 2019
@knative-prow-robot
knative-prow-robot merged commit 2c32e73 into knative:master Nov 27, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by an approver from all required OWNERS files. area/API API objects and controllers cla: yes Indicates the PR's author has signed the CLA. lgtm Indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Configuration webhook invalid value 'lastModifier'

5 participants