cen-ngc5139 / zookeeper-operator Goto Github PK
View Code? Open in Web Editor NEWKubernetes operator for deploying and managing ZooKeeper, Implement OAM framework
License: Apache License 2.0
Kubernetes operator for deploying and managing ZooKeeper, Implement OAM framework
License: Apache License 2.0
Provision
Is your feature request related to a problem? Please describe.
Add Workload ReConfig Reconcile
Is your feature request related to a problem? Please describe.
The zookeeper agent wraps a layer on the zookeeper API and provides the following functions:
Is your feature request related to a problem? Please describe.
Update CN README.md
Is your feature request related to a problem? Please describe.
Add admission webhook to validator spec
Is your feature request related to a problem? Please describe.
Add Rollout Trait
Describe the bug
group domain needs to update to zk.cache.ghostbaby.io
Is your feature request related to a problem? Please describe.
ReConfig Reconcile
ManualScale Reconcile
Rollout Reconcile
Is your feature request related to a problem? Please describe.
Is your feature request related to a problem? Please describe.
Add ManualScale Trait
Describe the bug
The observer can not get the current zookeeper node.
Describe the bug
if delete zk CR, the operator controller will crush.
Is your feature request related to a problem? Please describe.
Add Monitor Reconciler
Add observedGeneration
Fix known bug
│ manager [signal SIGSEGV: segmentation violation code=0x1 addr=0x0 pc=0x14cee5a] │
│ manager goroutine 347 [running]: │
│ manager k8s.io/apimachinery/pkg/util/runtime.HandleCrash(0x0, 0x0, 0x0) │
│ manager /go/pkg/mod/k8s.io/[email protected]/pkg/util/runtime/runtime.go:55 +0x105 │
│ manager panic(0x164d380, 0x2681ac0) │
│ manager /usr/local/go/src/runtime/panic.go:679 +0x1b2 │
│ manager github.com/ghostbaby/zookeeper-operator/controllers/workload/rollout.(*Rollout).RollingUpgrades(0xc00030df20, 0xc0008773c0, 0xc00053c000) │
│ manager /workspace/controllers/workload/rollout/rollingupdate.go:37 +0x12a │
│ manager github.com/ghostbaby/zookeeper-operator/controllers/workload/rollout.(*Rollout).Reconcile(0xc00030df20, 0x1aa6840, 0xc0000c4008) │
│ manager /workspace/controllers/workload/rollout/rollout.go:34 +0x8e │
│ manager github.com/ghostbaby/zookeeper-operator/controllers/workload.(*ReconcileWorkload).Reconcile(0xc0007000b0, 0x1aa6840, 0xc0000c4008) │
│ manager /workspace/controllers/workload/workload.go:55 +0x2e6 │
│ manager github.com/ghostbaby/zookeeper-operator/controllers.(*WorkloadReconciler).Reconcile(0xc00087fb00, 0xc0003487f9, 0x7, 0xc0003487ec, 0x4, 0xc00087a900, 0x0, 0x0, 0x0) │
│ manager /workspace/controllers/workload_controller.go:116 +0x617 │
│ manager sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).reconcileHandler(0xc0000fb710, 0x16a9040, 0xc000668c60, 0x0) │
│ manager /go/pkg/mod/sigs.k8s.io/[email protected]/pkg/internal/controller/controller.go:235 +0x27d │
│ manager sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).processNextWorkItem(0xc0000fb710, 0x0) │
│ manager /go/pkg/mod/sigs.k8s.io/[email protected]/pkg/internal/controller/controller.go:209 +0xcb │
│ manager sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).worker(0xc0000fb710) │
│ manager /go/pkg/mod/sigs.k8s.io/[email protected]/pkg/internal/controller/controller.go:188 +0x2b │
│ manager k8s.io/apimachinery/pkg/util/wait.BackoffUntil.func1(0xc00087a8e0) │
│ manager /go/pkg/mod/k8s.io/[email protected]/pkg/util/wait/wait.go:155 +0x5e │
│ manager k8s.io/apimachinery/pkg/util/wait.BackoffUntil(0xc00087a8e0, 0x1a692a0, 0xc0008544e0, 0x1, 0xc0000447e0) │
│ manager /go/pkg/mod/k8s.io/[email protected]/pkg/util/wait/wait.go:156 +0xa3 │
│ manager k8s.io/apimachinery/pkg/util/wait.JitterUntil(0xc00087a8e0, 0x3b9aca00, 0x0, 0xc0003dac01, 0xc0000447e0) │
│ manager /go/pkg/mod/k8s.io/[email protected]/pkg/util/wait/wait.go:133 +0xaa │
│ manager k8s.io/apimachinery/pkg/util/wait.Until(0xc00087a8e0, 0x3b9aca00, 0xc0000447e0) │
│ manager /go/pkg/mod/k8s.io/[email protected]/pkg/util/wait/wait.go:90 +0x4d │
│ manager created by sigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Start.func1 │
│ manager /go/pkg/mod/sigs.k8s.io/[email protected]/pkg/internal/controller/controller.go:170 +0x431 │
│ manager stream closed
Is your feature request related to a problem? Please describe.
Add DEVELOPMENT.md documentation
Is your feature request related to a problem? Please describe.
Add provision zookeeper cluster observe
Is your feature request related to a problem? Please describe.
observedGeneration
field of status in K8s object is widely used in K8s built-in resource. It reflects the generation of the most recently observed Object.
With the help of observedGeneration field, user can recognize whether a CR is reconciled by controller.
A workflow will like below:
apiVersion: cache.ghostbaby.io/v1alpha1
kind: Workload
metadata:
name: workload-sample
namespace: pg
spec:
version: v3.5.6
replicas: 5
...
After the controller reconciled, the observedGeneration will appear and align with generation in metadata:
apiVersion: cache.ghostbaby.io/v1alpha1
kind: Workload
metadata:
name: workload-sample
namespace: pg
generation: 1
spec:
version: v3.5.6
replicas: 5
...
status:
observedGeneration: 1
Later, we have another change, it will be:
apiVersion: cache.ghostbaby.io/v1alpha1
kind: Workload
metadata:
name: workload-sample
namespace: pg
generation: 2
spec:
version: v3.5.7
replicas: 5
...
status:
observedGeneration: 1
And after reconciled, it will be:
apiVersion: cache.ghostbaby.io/v1alpha1
kind: Workload
metadata:
name: workload-sample
namespace: pg
generation: 2
spec:
version: v3.5.7
replicas: 5
...
status:
observedGeneration: 2
Is your feature request related to a problem? Please describe.
Update readme.md
Is your feature request related to a problem? Please describe.
Update github workflows ci
Is your feature request related to a problem? Please describe.
Add Monitor Reconciler
Is your feature request related to a problem? Please describe.
OAM Definition
YAML fileIs your feature request related to a problem? Please describe.
Add observer finalizer.go
Describe the bug
apiVersion: zk.cache.ghostbaby.io/v1alpha1
kind: Workload
metadata:
name: workload-sample
spec:
version: v3.5.6
replicas: 3
cluster:
name: test
exporter:
exporter: true
exporterImage: ghostbaby/zookeeper_exporter
exporterVersion: v3.5.6
disableExporterProbes: false
storage:
persistentVolumeClaim:
metadata:
name: zookeeper-data
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi
when I use this YAML file to create zk cluster, mutate webhook not work .
Is your feature request related to a problem? Please describe.
Add zookeeper-agent
Add webhook
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.