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

fix: prefer events v1 over v1beta1 #416

Merged
merged 1 commit into from
Nov 11, 2022
Merged

Conversation

eddycharly
Copy link
Contributor

@eddycharly eddycharly commented Nov 10, 2022

What this PR does / why we need it:

This PR gives preference to events v1 over v1beta1 and falls back to v1beta1 if v1 didn't work.

Fixes #373
Fixes #414

Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>
@eddycharly eddycharly marked this pull request as ready for review November 10, 2022 16:52
@chipzoller
Copy link

Also fixes #414

t.Logger.Log("Trying with events eventsv1 API...")
err = t.collectEventsV1(cl, namespace)
t.Logger.Log("Trying with events eventsv1beta1 API...")
err = t.collectEventsBeta1(cl, namespace)
if err != nil {
t.Logger.Log("Trying with events corev1 API...")
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should the log message be changed?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I changed the log message according to the logic change.

@eddycharly eddycharly requested review from iblancasa and removed request for kensipe, kaiwalyajoshi and asekretenko November 10, 2022 18:38
Copy link
Member

@kensipe kensipe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@kensipe kensipe merged commit 62c2940 into kudobuilder:main Nov 11, 2022
@eddycharly eddycharly deleted the fix-events branch November 11, 2022 21:14
iblancasa pushed a commit to iblancasa/kuttl that referenced this pull request Nov 17, 2022
Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com>
Signed-off-by: Israel Blancas <iblancasa@gmail.com>
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.

events.k8s.io/v1beta1 removal in Kubernetes 1.25 events.k8s.io/v1beta1 Event is deprecated
4 participants