Is it possible to have a client always connect to the same database in a cluster? I mean: I would like to have a pool of databases (all with the same image but data-wise independent between them). Then, I would like to expose an IP and port at the cluster. When a client connects to this address, I would like the Kubernetes to automatically associate this cliente with a brand new database inside the cluster. This database should never be associated to any other client. All the times the given client conencts to the IP and port at the cluster, it should connect to the same database.
In case a new client accesses the service and now fresh databases are available, I would like k8s to automatically create a new database and associate it to the client.
Is this possible or pure fantasy?
Thanks in advance!
Aucun commentaire:
Enregistrer un commentaire