Coder Social home page Coder Social logo

Comments (5)

hbagdi avatar hbagdi commented on July 22, 2024 1

Hi @julianguinard

Is there any news about this issue? It has been closed but being bound to statically, YML-declared consumers is still problematic in production use cases

I totally get this point and this is an issue that we are going to solve in the next couple of releases.

What kind of workaround would you suggest? Would calling the Kunernetes API from the user creation code in order to create a KongConsumer entry be considered a good practice?

This is the only work around that exists to get around this problem (Kong Enterprise users can use workspace feature to get around this problem).
Although, this approach is not scalable. If you have a few hundred or a few thousand consumers in Kong, it should be fine, but larger than that, and this solution is not really feasible.

How are we going to solve this in the upcoming releases?

We developed tagging feature in Kong 1.1 specifically to solve this problem.

In the future releases of the Ingress Controller, all the entities created by the Ingress Controller will be tagged and it won't manage all entities in Kong.
Meaning, if you wish to manage Consumers via another service, that will be possible.

Please stay tuned and follow #246 for updates!

from kubernetes-ingress-controller.

hbagdi avatar hbagdi commented on July 22, 2024

Hello @nHurD,

Thank you for opening this issue.
I'm afraid what you're observing is an expected behavior 0.1.0 onwards as noted in the changelog.

Currently, all the entities in Kong are managed by the Ingress Controller, meaning any entity which doesn't have an associated object in k8s object store, will be remove by the ingress controller.

You can currently create KongConsumer custom resources in k8s, which will be synced via Ingress Controller to Kong.

Having said that, in future, consumers and other entities in Kong created manually will not be deleted by Ingress Controller. This is currently not possible as the entities created by Ingress Controller and those created directly via Admin API of Kong cannot be differentiated, making the syncing of entities from k8s to Kong a challenge. This will solved once Kong includes a feature to tag or label entities.

from kubernetes-ingress-controller.

leoatpolaris avatar leoatpolaris commented on July 22, 2024

@hbagdi Can I ask another question? Can Kong Ingress Controller sync entities from K8s to Kong automatically now? Do I have to create Kong entities by yaml manually? Actually I want to add services to K8s manually and Ingress Controller can sync these resources to Kong automatically.

from kubernetes-ingress-controller.

hbagdi avatar hbagdi commented on July 22, 2024

@leoatpolaris,

@hbagdi Can I ask another question?

Sure :)

Can Kong Ingress Controller sync entities from K8s to Kong automatically now?

That is primarily what this controller does. You create resources (like services, ingress rules) in k8s and the ingress controller syncs all those resources to Kong.

Do I have to create Kong entities by yaml manually?

Yes, you'll need to create the entities in k8s. You can automate it, it doesn't have to be manually. Please refer to our getting started guide for a better understanding.

from kubernetes-ingress-controller.

julianguinard avatar julianguinard commented on July 22, 2024

Hello

Is there any news about this issue? It has been closed but being bound to statically, YML-declared consumers is still problematic in production use cases

For instance, we may have a service that calls the kong API in order to create kong consumers dynamically (upon app user creation for instance). This behavior cannot work using kong-ingress-controller because the periodic sync will delete all of these entries

What kind of workaround would you suggest? Would calling the Kunernetes API from the user creation code in order to create a KongConsumer entry be considered a good practice?

from kubernetes-ingress-controller.

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.