Reputation: 21
I have one .Net application running on K8 cluster which serves service requests. I had a requirement where I had to spin up pods when custom resource (CR) is available (which in turn have to be created during service call). I have implemented spinning up pod during runtime using operator pattern (GoLang) and its working fine. As of now I am applying custom resources manually. but this is not going to work in long run as I have to spin up N pods for N number of requests and have to apply N number of custom resources to achieve this. I am aware that, when end point is hit I can call K8's crud api s to create custom resource but not willing to touch our application code instead would like develop logic in custom operator codeline itself. but stuck as I have no idea how to achieve this? every input is appreciated.
Upvotes: 0
Views: 123
Reputation: 104
Maybe you can try work queue to schedule/queue requests to perform jobs https://kubernetes.io/docs/tasks/job/coarse-parallel-processing-work-queue/
Upvotes: 1