Hostid for kubernetes naervicebus with servicecontrol?

(Michael Fyffe) #1

We are migrating our nservicebus hosts kubernetes. Currently we use servicecontrol in order to monitor the health of our hosts along with replaying messages.

What do we need to set the hostid to so that our containers that scale out and in and come and go don’t show us a bunch of missing heartbeats within servicecontrol?

(Daniel Marbach) #2

Hi Michael

Would StatefulSets work?

Pods have a unique identity that is comprised of an ordinal, a stable network identity, and stable storage. The identity sticks to the Pod, regardless of which node it’s (re)scheduled on.

Each Pod in a StatefulSet derives its hostname from the name of the StatefulSet and the ordinal of the Pod. The pattern for the constructed hostname is $(statefulset name)-$(ordinal) .

Then you could use this stable name to set the host name and the host id (deterministic guid)