Comments (5)
I actually already implemented a simple version of this using k8s lease resource so we can use the k8s API for leader election. It's very beta and code is ugly as hell. Merely a POC. But cleaned up and dressed nicely, this could be the approach. wdyt @sleipnir?
from bonny.
I think it makes sense. I will test with my Operator
That would mean a lot. I ran some rudimentary tests locally by running Kompost with BONNY_POD_NAME=different-value iex -S mix
, but some longer lasting test with a real deployment would be nice!
from bonny.
I think we could map a Process (GenServer) using the global type registry to perform the election. However this approach requires Operator to be running on a cluster of nodes, this responsibility could be delegated to the end user to avoid the inherent complexities of implementing this directly in Bonny. Leaving Bonny only the responsibility of communicating with the k8s API.
wdyt @mruoss ?
from bonny.
Forget what I said, I saw that the Leader Election API (Lease API) itself takes care of this :D
from bonny.
I actually already implemented a simple version of this using k8s lease resource so we can use the k8s API for leader election. It's very beta and code is ugly as hell. Merely a POC. But cleaned up and dressed nicely, this could be the approach. wdyt @sleipnir?
I think it makes sense. I will test with my Operator
from bonny.
Related Issues (20)
- Operator does not create the resources HOT 12
- Reduce Code Generation HOT 2
- Error :cluster_not_registered HOT 1
- Error on create HPA resource HOT 7
- The current CRD from `mix bonny.gen.manifest` doesn't work on later version of k8s HOT 19
- Missing priv folder in hex release 0.5.0 HOT 1
- cluster_name/0 is undefined HOT 4
- mix bonny.gen.manifest add an override callback
- Implement observedGeneration
- Multiple controllers handling same descendant kind HOT 7
- Initial test setup errors on application start. HOT 5
- An error is being thrown for deployments but not hpas. HOT 4
- Use strategic merge patch to add finalizers HOT 1
- Add multiple different resources with the same name in the pipeline for register_descendants
- Reconciled deletes don't seem to happen easily HOT 3
- Bonny Events throw without :operator_name in prod HOT 2
- Error with dependent resources HOT 7
- LeaderElector error on leader change HOT 2
- FIPS mode HOT 22
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bonny.