I'm creating a Java Web Application that predicts bitcoin price. I have 3 important "parts" there:
- Web Stack(Spring+Thymeleaf+Hibernate)
- Part that parses API and save btc prices into a database
- Machine Learning model that takes the data from a database and automatically update itself.
Now these parts are in a single jar stored in different packages. I feel they're completely different and storing them in distinct packages is not enough!
I believe that they should be somehow independent: for example, if there is an internal server error, I don't want to shutdown the self-optimizing of machine learning model just to see what's happened with Tomcat.
My business logic should work continuously and each part should work independently of any parts that it doesn't need. Maybe they should be in three different jars? Did anyone have experience with it? Or maybe someone knows how different logic parts are separated in a big enterprise projects?