Coder Social home page Coder Social logo

Deployment of new version of application with OpenShift extension fails with `LabelSelectorRequirement(nil)}: field is immutable` about quarkus HOT 5 OPEN

yrodiere avatar yrodiere commented on August 18, 2024
Deployment of new version of application with OpenShift extension fails with `LabelSelectorRequirement(nil)}: field is immutable`

from quarkus.

Comments (5)

quarkus-bot avatar quarkus-bot commented on August 18, 2024

/cc @geoand (kubernetes,openshift), @iocanel (kubernetes,openshift)

from quarkus.

iocanel avatar iocanel commented on August 18, 2024

This might be related to a recent change that removes some selectors that are not needed.
You could possibly work around this by deleting the previous resource.

Meanwhile, I'll try to have a look and see if there is something else we can / need to do.

from quarkus.

yrodiere avatar yrodiere commented on August 18, 2024

You could possibly work around this by deleting the previous resource.

Right. But just to be clear, I'd need to do this on every deployment, because the problem occurs again on the next deployment. It's not just some old, stale resource definition causing trouble.

Meanwhile, I'll try to have a look and see if there is something else we can / need to do.

Thanks.

from quarkus.

iocanel avatar iocanel commented on August 18, 2024

I managed to reproduce the issue by changing the version of the application which ends up being used in the LabelSelector of Deployments.

This behavior is controlled by: https://quarkus.io/guides/all-config#quarkus-kubernetes_quarkus-openshift-add-version-to-label-selectors (so you can deal with the issue by setting it to false).

Apparently, DeploymentConfig treated selectors a bit differently (AFAIR, it used its own Selector implementation) and that's why you haven't encountered the issue before.

One option is to improve the error message, the other is to detect such conflicts and delete. I am a bit skeptic about the potential side effects of the later.

from quarkus.

yrodiere avatar yrodiere commented on August 18, 2024

Thanks, I'll try setting quarkus.openshift.add-version-to-label-selectors to false.

Another option would be to have quarkus.openshift.add-version-to-label-selectors default to false, since re-deployment cannot work with that being set to true?

from quarkus.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.