Creating an Environment-Specific Data Loader in Spring Boot
What is the Benefit of Creating an Environment-Specific Data Load Architecture?
Quite often when developing an application, there is a need to bootstrap data into your application. This data is often different, depending
on the environment that you are deploying it to. When using Spring Boot to build an application, the process becomes extremely simple, and involves
three simple steps:
- Create an Abstract Data Loader using TemplateMethod pattern (
only necessary if you have common data that will need to be loaded into all environments).
- Implement environment specific implementations using the
Creating an Application Context Listener that runs when ApplicationContext is initialized or refreshed.
Implementing an Abstract Data Loader
Environment-Specific Data Loader using