Skip to content

scrapes pod container statuses when waiting for more to become available - #21257

Merged
vmuzikar merged 1 commit into
keycloak:mainfrom
shawkins:iss10285
Jun 30, 2023
Merged

scrapes pod container statuses when waiting for more to become available#21257
vmuzikar merged 1 commit into
keycloak:mainfrom
shawkins:iss10285

Conversation

@shawkins

Copy link
Copy Markdown
Contributor

The pros of this:

  • will add has error messages from the pod status for what we would consider error conditions that are unlikely to resolve naturally

The cons of this:

  • is very specific to container statuses, and is not using the conditions or phases - could try to harvest / copy whatever logic is in the deployment controller to mimic what is done for deployments.
  • related to the first point is that I could not find a definitive list of reasons, so instead it will look for reasons containing err or crashloopbackoff. This is so that normal reasons like podinitializing do not show up. However this may miss some reasons.
  • it needs to be specific and stable as to keep unnecessary status changes and modifications of the lastTransitionTime to a minimum.
  • adds a bit of a performance hit to the status logic as we're fetching the pods each time. We could consider being informed on them instead.

Closes #10285

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.

Now that #20906 is merged, should we update it in this PR, or as a follow-up? Both works for me.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Updated it as part of this pr.

@ghost ghost left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Unreported flaky test detected, please review

@ghost

ghost commented Jun 30, 2023

Copy link
Copy Markdown

Unreported flaky test detected

If the below flaky tests below are affected by the changes, please review and update the changes accordingly. Otherwise, a maintainer should report the flaky tests prior to merging the PR.

org.keycloak.testsuite.ui.account2.DeviceActivityTest#clientsTest

Keycloak CI - Account Console IT (firefox)

java.lang.AssertionError: Expected DeviceActivityPage but was Keycloak Account Management (https://localhost:8543/auth/realms/test/account/#/security/device-activity&state=c61585b3-6e72-4b29-bd5d-c5e05d2a9594&session_state=ff547c34-e536-4a1a-81f2-047b5fd6da19&code=7f417522-e76b-431a-b039-2ad5e9e5143a.ff547c34-e536-4a1a-81f2-047b5fd6da19.61684334-9fb5-4889-97be-addae011932e)
	at org.junit.Assert.fail(Assert.java:89)
	at org.junit.Assert.assertTrue(Assert.java:42)
	at org.keycloak.testsuite.page.AbstractPage.assertCurrent(AbstractPage.java:110)
	at jdk.internal.reflect.GeneratedMethodAccessor101.invoke(Unknown Source)
...

Report flaky test

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Expose deployment errors in the status field of Keycloak CR

2 participants