broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT...

21
The journey of shifting the MQTT message broker HiveMQ to Kubernetes Arnold Bechtoldt v1

Transcript of broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT...

Page 1: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

The journey of shifting the MQTT message broker HiveMQ to Kubernetes

Arnold Bechtoldt

v1

Page 2: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

Background

Page 3: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

Use Case: Fleet Management

3

Backend

MQTT Broker

Clients (Fleet)

Page 4: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

● MQTT clients are everywhere

● One fat pet (cluster)

● Manual MQTT broker deployment

● Painful up-scaling

● Antiqued configuration management

Design Flaws

4

Page 5: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

The Plan

Page 6: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

Docker!

6

Page 7: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

Docker + Kubernetes!

7

Page 8: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

● Stateless

● Web-based (HTTP interfaces)

● Cloud-ready

Kubernetes works best with an app that is ...

8

Page 9: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

● Stateless

● Web-based (HTTP interfaces)

● Cloud-ready

HiveMQ wasn‘t ...

9

Page 10: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers
Page 11: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

● Already in use (for microservices)

● High flexibility

● A lot of knowledge and skills at inovex :-)

● Close collaboration with HiveMQ support

● Easy is not an option!

Kubernetes because ...

11

Page 12: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

Facing the Truth: Challenges

Page 13: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

● Existing mechanisms not cloud-ready

● Kubernetes API integration was needed

● We’ve created a new HiveMQ plugin

● Final completion & open sourcing by dc-square

Challenge: HiveMQ Cluster Discovery (1)

13

Page 14: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

● Cloud’s main language is HTTP

● MQTT works different

● TLS required

● Proxy protocol (v2) for authn & authz

Challenge: Loadbalancing Capabilities (2)

14

Page 15: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

● Health: Is it working properly?

● Readiness: Is it ready for clients/traffic?

● No smooth way to find out

● Log event available only

● New HTTP interface in the pipeline (WIP)

Challenge: Determining App Health/Readiness (3)

15

Page 16: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

● Kubernetes won’t simplify your IT architecture

● Applications must be verbose (see 12factor app guide)

● Your containers will die

● Overall troubleshooting becomes more complicated

● Already work in progress

Challenge: Missing HiveMQ Application Insights (4)

16

Page 17: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

Hands on: Demo

Page 18: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

Demo Time

18

You know what happens with live demos? Right, they always fail!

Page 19: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

Demo Time: Video!

19

youtu.be/Ly_f221O6Fo

Page 20: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

Arnold Bechtoldtinovex GmbH

[email protected]

github.com/bechtoldt youtube.com/inovexGmbH

arbe.io

Feedback & Questions:

sayat.me/arbe

Page 21: broker HiveMQ to Kubernetes The journey of shifting the ... · Kubernetes won’t simplify your IT architecture Applications must be verbose (see 12factor app guide) Your containers

Q&A