Skip to main content

My microservice prototype currently has a Spring boot MVC application as its front-end. The application renders the View completely in the backend. It makes rest calls to other microservices like OrderService or ShippingService that are behind an API Gateway. Scaling the micro-services behind the API Gateway is no problem. But scaling the front-end MVC with a session is not that great I guess. I can implement Oauth2 and I could set the fronted also stateless!?

I often see microservice architecture examples with a complete JavaScript fronted like Angular. Is it normal to use that with a JavaScript client in the browser? When should I use server side rendering and when the client side renders with JavaScript?

Why I want to use server side rendering: I want to make all the microservices a self-contained system. Every service like a ShippingService(Resource) and the OrderService(Resource) have their own Spring MVC server side front-end (delivering the side and some JavaScript for back-end calls only related to that service). When the OrderSerivce goes down, for example, the ShippingserviceShipping service is still completely usable. Just the links to the OderService are not included because the service is not available.

Otherwise, when I use a web portal (Spring MVC application) that delivers the user the JavaScript client it would have the same behavior but what if the web portal goes down?

What about all the JavaScript code that is related to all the different microservices? There would always be a strong dependency or not?

I would also like to know if it is better instead of adding a Spring boot MVC app to each microservice if I just add the HTML to the OrderService and provide a link. When the user clicks it the browser will show the HTML page rendered by the OrderSerice instead of having ana REST API?

My microservice prototype currently has a Spring boot MVC application as its front-end. The application renders the View completely in the backend. It makes rest calls to other microservices like OrderService or ShippingService that are behind an API Gateway. Scaling the micro-services behind the API Gateway is no problem. But scaling the front-end MVC with session is not that great I guess. I can implement Oauth2 and I could set the fronted also stateless!?

I often see microservice architecture examples with a complete JavaScript fronted like Angular. Is it normal to use that with a JavaScript client in the browser? When should I use server side rendering and when the client side renders with JavaScript?

Why I want to use server side rendering: I want to make all the microservices a self-contained system. Every service like a ShippingService(Resource) and the OrderService(Resource) have their own Spring MVC server side front-end (delivering the side and some JavaScript for back-end calls only related to that service). When the OrderSerivce goes down for example the Shippingservice is still completely usable. Just the links to the OderService are not included because the service is not available.

Otherwise, when I use a web portal (Spring MVC application) that delivers the user the JavaScript client it would have the same behavior but what if the web portal goes down?

What about all the JavaScript code that is related to all the different microservices? There would always be a strong dependency or not?

I would also like to know if it is better instead of adding a Spring boot MVC app to each microservice if I just add the HTML to the OrderService and provide a link. When the user clicks it the browser will show the HTML page rendered by the OrderSerice instead of having an REST API?

My microservice prototype currently has a Spring boot MVC application as its front-end. The application renders the View completely in the backend. It makes rest calls to other microservices like OrderService or ShippingService that are behind an API Gateway. Scaling the micro-services behind the API Gateway is no problem. But scaling the front-end MVC with a session is not that great I guess. I can implement Oauth2 and I could set the fronted also stateless!?

I often see microservice architecture examples with a complete JavaScript fronted like Angular. Is it normal to use that with a JavaScript client in the browser? When should I use server side rendering and when the client side renders with JavaScript?

Why I want to use server side rendering: I want to make all the microservices a self-contained system. Every service like a ShippingService(Resource) and the OrderService(Resource) have their own Spring MVC server side front-end (delivering the side and some JavaScript for back-end calls only related to that service). When the OrderSerivce goes down, for example, the Shipping service is still completely usable. Just the links to the OderService are not included because the service is not available.

Otherwise, when I use a web portal (Spring MVC application) that delivers the user the JavaScript client it would have the same behavior but what if the web portal goes down?

What about all the JavaScript code that is related to all the different microservices? There would always be a strong dependency or not?

I would also like to know if it is better instead of adding a Spring boot MVC app to each microservice if I just add the HTML to the OrderService and provide a link. When the user clicks it the browser will show the HTML page rendered by the OrderSerice instead of having a REST API?

Tweeted twitter.com/StackSoftEng/status/852035262725070849
Grammar/spelling.
Source Link
user22815
user22815

I need some help because I get often the same answer from myself and would like to know what other people think. So my MicroserviceMy microservice prototype currently has a Spring boot MVC application as fronted currentlyits front-end. So theThe application renders the View completely in the backend. It makes Rest Callsrest calls to other Microservicesmicroservices like OrderService or ShippingService that are behind an API Gateway. So scalingScaling the micro-services behind the API Gateway is no problem. But scaling the Frontendfront-end MVC with session is not that great I guess. But I can implement Oauth2 and than I could set the fronted also stateless!? But 

I often see just Microservice Architecturemicroservice architecture examples with ana complete javascriptJavaScript fronted like angular.jsAngular. So isIs it normal to use for Browsers an javascript Clintthat with a JavaScript client in the Browserbrowser? And whenWhen should I use Server Side Renderingserver side rendering and when the client side renderingrenders with javascriptJavaScript?

Why I want to use Server Side Rendering. Soserver side rendering: I want to make all the Microserivces an Self Containedmicroservices a self-contained system. So every ServiceEvery service like a ShippingService(Resource) and the OrderService(Resource) have theretheir own Spring MVC ServerSide Frontendserver side front-end (Deliveringdelivering the side and some javascriptJavaScript for backendback-end calls only related to that service). When the OrderSerivce goes down for example the Shippingservice is still completely usable. Just the links to the OderService are not included because the service is not available. Otherwise

Otherwise, when I use a Web-Portalweb portal (Spring MVC application) that delivers the user the javascriptclientJavaScript client it would have the same behavior but what if the Web-Portalweb portal goes down? Also what

What about all the javascriptJavaScript code that areis related to all the different Microservicesmicroservices? There would always be a strong dependency or not?

Also iI would also like to know if it is better instead of adding a Spring boot MVC app to each Microservicemicroservice if I just add the htmlHTML to the OrderService and provide a link. So the whenWhen the user klickclicks it the browser will show the html Page renderdHTML page rendered by the OrderSerice instead of having an REST API?

I need some help because I get often the same answer from myself and would like to know what other people think. So my Microservice prototype has a Spring boot MVC application as fronted currently. So the application renders the View completely in the backend. It makes Rest Calls to other Microservices like OrderService or ShippingService that are behind an API Gateway. So scaling the micro-services behind the API Gateway is no problem. But scaling the Frontend MVC with session is not that great I guess. But I can implement Oauth2 and than I could set the fronted also stateless!? But I often see just Microservice Architecture examples with an complete javascript fronted like angular.js. So is it normal to use for Browsers an javascript Clint in the Browser? And when should I use Server Side Rendering and when client side rendering with javascript?

Why I want to use Server Side Rendering. So I want to make all the Microserivces an Self Contained system. So every Service like a ShippingService(Resource) and the OrderService(Resource) have there own Spring MVC ServerSide Frontend(Delivering the side and some javascript for backend calls only related to that service). When the OrderSerivce goes down for example the Shippingservice is still completely usable. Just the links to the OderService are not included because the service is not available. Otherwise, when I use a Web-Portal(Spring MVC application) that delivers the user the javascriptclient it would have the same behavior but what if the Web-Portal goes down? Also what about all the javascript code that are related to all the different Microservices? There would always be a strong dependency or not?

Also i would like to know if it is better instead of adding a Spring boot MVC app to each Microservice I just add the html to the OrderService and provide a link. So the when the user klick it the browser will show the html Page renderd by the OrderSerice instead of having an REST API?

My microservice prototype currently has a Spring boot MVC application as its front-end. The application renders the View completely in the backend. It makes rest calls to other microservices like OrderService or ShippingService that are behind an API Gateway. Scaling the micro-services behind the API Gateway is no problem. But scaling the front-end MVC with session is not that great I guess. I can implement Oauth2 and I could set the fronted also stateless!? 

I often see microservice architecture examples with a complete JavaScript fronted like Angular. Is it normal to use that with a JavaScript client in the browser? When should I use server side rendering and when the client side renders with JavaScript?

Why I want to use server side rendering: I want to make all the microservices a self-contained system. Every service like a ShippingService(Resource) and the OrderService(Resource) have their own Spring MVC server side front-end (delivering the side and some JavaScript for back-end calls only related to that service). When the OrderSerivce goes down for example the Shippingservice is still completely usable. Just the links to the OderService are not included because the service is not available.

Otherwise, when I use a web portal (Spring MVC application) that delivers the user the JavaScript client it would have the same behavior but what if the web portal goes down?

What about all the JavaScript code that is related to all the different microservices? There would always be a strong dependency or not?

I would also like to know if it is better instead of adding a Spring boot MVC app to each microservice if I just add the HTML to the OrderService and provide a link. When the user clicks it the browser will show the HTML page rendered by the OrderSerice instead of having an REST API?

Source Link
Rocks360
  • 199
  • 1
  • 5

Is it a good idea to use a Spring MVC as an Frontend of a Microservice Architecture?

I need some help because I get often the same answer from myself and would like to know what other people think. So my Microservice prototype has a Spring boot MVC application as fronted currently. So the application renders the View completely in the backend. It makes Rest Calls to other Microservices like OrderService or ShippingService that are behind an API Gateway. So scaling the micro-services behind the API Gateway is no problem. But scaling the Frontend MVC with session is not that great I guess. But I can implement Oauth2 and than I could set the fronted also stateless!? But I often see just Microservice Architecture examples with an complete javascript fronted like angular.js. So is it normal to use for Browsers an javascript Clint in the Browser? And when should I use Server Side Rendering and when client side rendering with javascript?

Why I want to use Server Side Rendering. So I want to make all the Microserivces an Self Contained system. So every Service like a ShippingService(Resource) and the OrderService(Resource) have there own Spring MVC ServerSide Frontend(Delivering the side and some javascript for backend calls only related to that service). When the OrderSerivce goes down for example the Shippingservice is still completely usable. Just the links to the OderService are not included because the service is not available. Otherwise, when I use a Web-Portal(Spring MVC application) that delivers the user the javascriptclient it would have the same behavior but what if the Web-Portal goes down? Also what about all the javascript code that are related to all the different Microservices? There would always be a strong dependency or not?

Also i would like to know if it is better instead of adding a Spring boot MVC app to each Microservice I just add the html to the OrderService and provide a link. So the when the user klick it the browser will show the html Page renderd by the OrderSerice instead of having an REST API?