Bare minimum Kafka Brokers
@gamussa
Zookeeper Nodes
#OracleCodeOne @
@confluentinc
Slide 14
Shard data to get scalability Producer (1)
Producer (2)
Producer (3)
Messages are sent to different partitions Cluster of machines
Partitions live on different machines
@gamussa
#OracleCodeOne
@confluentinc
Slide 15
Linearly Scalable Architecture Producers
Single topic: - Many producers machines - Many consumer machines - Many Broker machines No Bottleneck!!
Consumers @gamussa
#OracleCodeOne
@confluentinc
Slide 16
Replicate to get fault tolerance leader
msg
Machine A @gamussa
Machine B replicate
msg
#OracleCodeOne
@confluentinc
Slide 17
Replication provides resiliency
A ‘replica’ takes over on machine failure @gamussa
#OracleCodeOne
@confluentinc
Pod
Basic Unit of Deployment in Kubernetes A collection of containers sharing: Namespace Network Volumes @gamussa
#OracleCodeOne @
@confluentinc
Slide 26
Storage Persistent Volume (PV) & Persistent Volume Claim (PVC) Both PV and PVC are ‘resources’
@gamussa
#OracleCodeOne @
@confluentinc
Slide 27
Storage Persistent Volume (PV) & Persistent Volume Claim (PVC) PV is a piece of storage that is provisioned dynamic or static of any individual pod that uses the PV
@gamussa
#OracleCodeOne @
@confluentinc
Slide 28
Storage Persistent Volume (PV) & Persistent Volume Claim (PVC) PVC is a request for storage by a User
@gamussa
#OracleCodeOne @
@confluentinc
StatefulSet
Rely on Headless Service to provide network identity
Headless Service
Ideal for highly available stateful workloads
@gamussa
Pod-0
Pod-2
Containers
Containers
Containers
Volumes
Volumes
Volumes
#OracleCodeOne @
Pod-1
@confluentinc
Slide 32
StatefulSet
Rely on Headless Service to provide network identity
@gamussa
Headless Service
Pod-0
Pod-2
Containers
Containers
Containers
Volumes
Volumes
Volumes
#OracleCodeOne @
Pod-1
@confluentinc
Slide 33
StatefulSet
Ideal for highly available stateful workloads
@gamussa
Headless Service
Pod-0
Pod-2
Containers
Containers
Containers
Volumes
Volumes
Volumes
#OracleCodeOne @
Pod-1
@confluentinc
Basic components are not enough
@gamussa
#OracleCodeOne
@confluentinc
Slide 40
Kafka deployment checklist PVC for Storage
Uses ZK Headless Svc
StatefulSet for 3-node zk
PVC for Storage
Optional Pod Anti-Affinity to spread the ZK ensemble across nodes
StatefulSet for n-node Kafka
Headless Service
A group of NodePort Services for external traffic
ConfigMap for Prometheus JMX exporter
ConfigMap for Prometheus JMX exporter
@gamussa
#OracleCodeOne @
@confluentinc
Kubernetes Operator Embedded with operational knowledge of both data software and Kubernetes Backup/restore Scale up/down Rebalance data Regular health checks @gamussa
#OracleCodeOne @
@confluentinc
Slide 45
Controller
Brain behind Kubernetes resources e.g. replication controller, namespace controller etc. @gamussa
#OracleCodeOne @
@confluentinc
Custom Resource Definition(CRD) Usually works together
Custom Controller
API
StatefulSet
ReplicaSet
...
CRD
Controller
StatefulSet Controller
ReplicaSet Controller
...
Custom Controller
ReplicaSet
...
Custom Resource
Instance
@gamussa
StatefulSet
#OracleCodeOne @
@confluentinc
Slide 48
Custom Resource Definition(CRD) Users can create and access Customer Resources with kubectl, just as they do for built-in
API
StatefulSet
ReplicaSet
...
CRD
Controller
StatefulSet Controller
ReplicaSet Controller
...
Custom Controller
ReplicaSet
...
Custom Resource
Instance
StatefulSet
resources like pods. @gamussa
#OracleCodeOne @
@confluentinc
Slide 49
Operator Deploy and Manage your production streaming platform with Confluent Operator. Automated Provisioning Platform Operations Resiliency Monitoring @gamussa
#OracleCodeOne @
@confluentinc
Slide 50
Confluent Platform Reference Architecture Each Confluent Platform component has specific characteristics: Security (SSL certificates) DNS names and zones
Application
Application
Application
Native Client library
Kafka Streams
Load Balancer * Schema Registry
REST Proxy
Kafka Connect
Host selection Fault tolerance
Zookeeper Nodes
Kafka Brokers
Scaling
@gamussa
#OracleCodeOne @
@confluentinc
Slide 51
Confluent Operator: Automated Provisioning
Load Balancer
Kafka Pod
Kafka Pod
Kafka Pod
Storage
@gamussa
#OracleCodeOne @
@confluentinc
Slide 52
Confluent Operator: Scale Horizontally Automate scaling: Spin up new broker pod(s) Distribute partitions to the new broker(s) Determine balancing plan Execute balancing plan Monitor resources @gamussa
#OracleCodeOne @
@confluentinc
Slide 53
Confluent Operator: Rolling Upgrade Automated rolling upgrade with no downtime for Kafka. Stop broker Wait for leader election to complete Start broker with new version Wait for zero under-replicatedpartitions Repeat
@gamussa
#OracleCodeOne @
@confluentinc
Slide 54
Will it fly? Let’s see
@gamussa
#OracleCodeOne
@confluentinc
Slide 55
Confluent Operator Automate provisioning
Scale your Kafkas and CP clusters elastically
Monitor SLAs through Confluent Control Center or Prometheus
Operate at scale with enterprise support from Confluent
@gamussa
#OracleCodeOne @
@confluentinc
Slide 56
Advanced use cases vs.
@gamussa
#OracleCodeOne
@confluentinc