Spring Cloud Configuration Server Using File — Native Mode
The native mode for configuration in Spring Cloud refers to keeping configuration files locally on the host machine for the application. As opposed to other techniques, such as obtaining configurations from a distant configuration server, this.
When the application is in native mode, it reads its configuration straight from local files. Now as part of the Spring Cloud out-of-the-box feature, you can create a centralized configuration server and use native mode to store the config file if you are not interested in using Git or JDBC to store the configuration.
Getting Start
It is pretty easy to start a Spring Cloud Configuration server you just need to add the following dependency and Enable the server using @EnableConfigServer
annotation.
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-config-server</artifactId>
</dependency>
You can add the @EnableConfigServer
to the application's main class like the following example:
@SpringBootApplication
@EnableConfigServer
public class…