Skip to content

Commit

Permalink
Add remaining kafka ops request docs
Browse files Browse the repository at this point in the history
Signed-off-by: obaydullahmhs <[email protected]>
  • Loading branch information
obaydullahmhs committed Aug 13, 2024
1 parent b2ce7dd commit e75e973
Show file tree
Hide file tree
Showing 34 changed files with 4,380 additions and 702 deletions.
15 changes: 3 additions & 12 deletions docs/examples/kafka/configuration/kafka-combined.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,8 @@ metadata:
spec:
replicas: 2
version: 3.6.1
podTemplate:
spec:
containers:
- name: kafka
resources:
limits:
cpu: 1
memory: 2Gi
requests:
cpu: 500m
memory: 1Gi
configSecret:
name: configsecret-combined
storage:
accessModes:
- ReadWriteOnce
Expand All @@ -25,4 +16,4 @@ spec:
storage: 1Gi
storageClassName: standard
storageType: Durable
deletionPolicy: DoNotTerminate
deletionPolicy: WipeOut
16 changes: 0 additions & 16 deletions docs/examples/kafka/configuration/kafka-topology.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,6 @@ spec:
topology:
broker:
replicas: 2
podTemplate:
spec:
containers:
- name: kafka
resources:
requests:
cpu: "500m"
memory: "1Gi"
storage:
accessModes:
- ReadWriteOnce
Expand All @@ -27,14 +19,6 @@ spec:
storageClassName: standard
controller:
replicas: 2
podTemplate:
spec:
containers:
- name: kafka
resources:
requests:
cpu: "500m"
memory: "1Gi"
storage:
accessModes:
- ReadWriteOnce
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
apiVersion: v1
kind: Secret
metadata:
name: kf-combined-custom-config
namespace: demo
stringData:
server.properties: |-
log.retention.hours=100
19 changes: 19 additions & 0 deletions docs/examples/kafka/reconfigure/kafka-combined.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
apiVersion: kubedb.com/v1
kind: Kafka
metadata:
name: kafka-dev
namespace: demo
spec:
replicas: 2
version: 3.6.1
configSecret:
name: kf-combined-custom-config
storage:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi
storageClassName: standard
storageType: Durable
deletionPolicy: WipeOut
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
apiVersion: ops.kubedb.com/v1alpha1
kind: KafkaOpsRequest
metadata:
name: kfops-reconfigure-apply-combined
namespace: demo
spec:
type: Reconfigure
databaseRef:
name: kafka-dev
configuration:
applyConfig:
server.properties: |-
log.retention.hours=150
timeout: 5m
apply: IfReady
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
apiVersion: ops.kubedb.com/v1alpha1
kind: KafkaOpsRequest
metadata:
name: kfops-reconfigure-apply-topology
namespace: demo
spec:
type: Reconfigure
databaseRef:
name: kafka-prod
configuration:
applyConfig:
broker.properties: |-
log.retention.hours=150
controller.properties: |-
controller.quorum.election.timeout.ms=4000
controller.quorum.fetch.timeout.ms=5000
timeout: 5m
apply: IfReady
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
apiVersion: ops.kubedb.com/v1alpha1
kind: KafkaOpsRequest
metadata:
name: kfops-reconfigure-combined
namespace: demo
spec:
type: Reconfigure
databaseRef:
name: kafka-dev
configuration:
configSecret:
name: new-kf-combined-custom-config
timeout: 5m
apply: IfReady
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
apiVersion: ops.kubedb.com/v1alpha1
kind: KafkaOpsRequest
metadata:
name: kfops-reconfigure-topology
namespace: demo
spec:
type: Reconfigure
databaseRef:
name: kafka-prod
configuration:
configSecret:
name: new-kf-topology-custom-config
timeout: 5m
apply: IfReady
10 changes: 10 additions & 0 deletions docs/examples/kafka/reconfigure/kafka-topology-custom-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
apiVersion: v1
kind: Secret
metadata:
name: kf-topology-custom-config
namespace: demo
stringData:
broker.properties: |-
log.retention.hours=100
controller.properties: |-
controller.quorum.election.timeout.ms=2000
30 changes: 30 additions & 0 deletions docs/examples/kafka/reconfigure/kafka-topology.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
apiVersion: kubedb.com/v1
kind: Kafka
metadata:
name: kafka-prod
namespace: demo
spec:
version: 3.6.1
configSecret:
name: kf-topology-custom-config
topology:
broker:
replicas: 2
storage:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi
storageClassName: standard
controller:
replicas: 2
storage:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi
storageClassName: standard
storageType: Durable
deletionPolicy: WipeOut
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
apiVersion: v1
kind: Secret
metadata:
name: new-kf-combined-custom-config
namespace: demo
stringData:
server.properties: |-
log.retention.hours=125
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
apiVersion: v1
kind: Secret
metadata:
name: new-kf-topology-custom-config
namespace: demo
stringData:
broker.properties: |-
log.retention.hours=125
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
apiVersion: ops.kubedb.com/v1alpha1
kind: KafkaOpsRequest
metadata:
name: kfops-hscale-down-combined
namespace: demo
spec:
type: HorizontalScaling
databaseRef:
name: kafka-dev
horizontalScaling:
node: 2
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
apiVersion: ops.kubedb.com/v1alpha1
kind: KafkaOpsRequest
metadata:
name: kfops-hscale-down-topology
namespace: demo
spec:
type: HorizontalScaling
databaseRef:
name: kafka-prod
horizontalScaling:
topology:
broker: 2
controller: 2
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
apiVersion: ops.kubedb.com/v1alpha1
kind: KafkaOpsRequest
metadata:
name: kfops-hscale-up-combined
namespace: demo
spec:
type: HorizontalScaling
databaseRef:
name: kafka-dev
horizontalScaling:
node: 3
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
apiVersion: ops.kubedb.com/v1alpha1
kind: KafkaOpsRequest
metadata:
name: kfops-hscale-up-topology
namespace: demo
spec:
type: HorizontalScaling
databaseRef:
name: kafka-prod
horizontalScaling:
topology:
broker: 3
controller: 3
17 changes: 17 additions & 0 deletions docs/examples/kafka/scaling/kafka-combined.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
apiVersion: kubedb.com/v1
kind: Kafka
metadata:
name: kafka-dev
namespace: demo
spec:
replicas: 2
version: 3.6.1
storage:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi
storageClassName: standard
storageType: Durable
deletionPolicy: WipeOut
28 changes: 28 additions & 0 deletions docs/examples/kafka/scaling/kafka-topology.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
apiVersion: kubedb.com/v1
kind: Kafka
metadata:
name: kafka-prod
namespace: demo
spec:
version: 3.6.1
topology:
broker:
replicas: 2
storage:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi
storageClassName: standard
controller:
replicas: 2
storage:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 1Gi
storageClassName: standard
storageType: Durable
deletionPolicy: WipeOut
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
apiVersion: ops.kubedb.com/v1alpha1
kind: KafkaOpsRequest
metadata:
name: kfops-vscale-combined
namespace: demo
spec:
type: VerticalScaling
databaseRef:
name: kafka-dev
verticalScaling:
node:
resources:
requests:
memory: "1.2Gi"
cpu: "0.6"
limits:
memory: "1.2Gi"
cpu: "0.6"
timeout: 5m
apply: IfReady
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
apiVersion: ops.kubedb.com/v1alpha1
kind: KafkaOpsRequest
metadata:
name: kfops-vscale-topology
namespace: demo
spec:
type: VerticalScaling
databaseRef:
name: kafka-prod
verticalScaling:
broker:
resources:
requests:
memory: "1.2Gi"
cpu: "0.6"
limits:
memory: "1.2Gi"
cpu: "0.6"
controller:
resources:
requests:
memory: "1.1Gi"
cpu: "0.6"
limits:
memory: "1.1Gi"
cpu: "0.6"
timeout: 5m
apply: IfReady
Loading

0 comments on commit e75e973

Please sign in to comment.