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

Make KubernetesClientErrorHandler always throw a RuntimeException #19871

Merged
merged 1 commit into from
Sep 3, 2021

Conversation

iocanel
Copy link
Contributor

@iocanel iocanel commented Sep 2, 2021

Resolves: #19870

@quarkus-bot
Copy link

quarkus-bot bot commented Sep 2, 2021

Thanks for your pull request!

The title of your pull request does not follow our editorial rules. Could you have a look?

  • title should preferably start with an uppercase character (if it makes sense!)
  • title should not start with chore/docs/feat/fix/refactor but be a proper sentence

This message is automatically generated by a bot.

@geoand geoand changed the title fix: KubernetesClientErrorHandler always throws a RuntimeException Prevent RuntimeException from KubernetesClientErrorHandler Sep 2, 2021
@geoand geoand changed the title Prevent RuntimeException from KubernetesClientErrorHandler Make KubernetesClientErrorHandler always throw a RuntimeException Sep 2, 2021
@geoand
Copy link
Contributor

geoand commented Sep 2, 2021

Are there any potential side effects to always throwing the exception?

Copy link
Contributor

@gastaldi gastaldi left a comment

Choose a reason for hiding this comment

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

That makes sense. I'm curious about @geoand's question too

@iocanel
Copy link
Contributor Author

iocanel commented Sep 3, 2021

Are there any potential side effects to always throwing the exception?

Yes, the build breaks and the users get's the stack trace of the exception.
With the current behavior the error becomes an NPE (unless its an SSLSomethingException) without any indication of what might be wrong.

I feel that when a user requests an operation (in this case container image build) and this cannot be done for any reason, the build should immediately fail. If not random things might happen later on, that are hard for users to decipher.

@iocanel iocanel merged commit 47a92b4 into quarkusio:main Sep 3, 2021
@quarkus-bot quarkus-bot bot added this to the 2.3 - main milestone Sep 3, 2021
@gsmet
Copy link
Member

gsmet commented Sep 6, 2021

@geoand @iocanel should we backport this one for 2.2.2.Final?

@geoand
Copy link
Contributor

geoand commented Sep 6, 2021 via email

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.

Potential NPE when deploying on Kubernetes / Openshift
4 participants