Redeploy spring boot service without rebooting?

I developed a microservice (Spring Boot REST service, deployed as an executable JAR) to track all the activities of third-party projects as my requirement and its work now.

It currently works separately from some projects, and now I have updated the service with some additional features.

But I can’t transfer it to a live server without restarting the existing service, since it is deployed as a bank. I'm afraid to restart the service, rebooting may lead to data loss from integrated projects.

What improvements can I make in my architecture to solve my problem?

+6
source share
2 answers

Finally got a solution commented by @Gimby.

We can do this by deploying multiple service instances and contacting the service registry. Here I achieved this using eureka as a registry service, and also used zuul as a proxy.

0
source

How about the JRebel plugin. This worked fine for me, but unfortunately this is not a free application. As an alternative (I used this approach with Spring MVC, it could have been different with Spring Boot), I installed a soft link in the working directory by the compiled path in JBoss (in my case it was a directory with the name target and * .class and * .jar files). As for me, the first solution with JRebel is the most suitable for you.

+2
source

All Articles