How to expose each member of the Pet/StatefulSet as a separate service.

Solution In Progress - Updated -

Issue

Issue is pretty much summarized here

There is a need to expose each member of the Pet/StatefulSet as a separate service such that client requests can be routed to a specific set member rather any. This is vital for running certain kinds of clustered applications on Openshift.
For example, in "Kafka" a particular node is leader for a given topic/partition. A client receives this information via cluster metadata, which is subsequently used to identify the correct leader for a given operation.

It is currently not possible to expose a service per set member because StatefulSet member's (pet's) endpoints are not labeled with anything like "name-". So, there is no way to create a separate service per StatefulSet member with a lable selector to point to a particular 'pet'.

Environment

OpenShift Container Platform >3.4

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.