Home > Net >  Does each Microservices have different hostname for production site?
Does each Microservices have different hostname for production site?

Time:01-24

I have microservice based project in Spring-Boot. If I want to publish it live on production with HTTPS, then do I have to buy different hostname for each of the microservices? Or is there another way for calling APIs?

I have only tried this on my local system. And each microservices are running on different ports and hosts.

CodePudding user response:

No you don't have to buy different host names. you can organize your microservices like this:

www.myhost.com/api/v1/myservice

www.myhost.com/api/v1/anotherservice

or you could also use subdomains (they are mostly free) www.subdomain.myhost.com/api/v1/myservice

it depends how do you wan't to structure your microservices and how they fit together.

  • Related