Linked Questions
11 questions linked to/from Spring Boot Externalizing properties not working
49 votes
4 answers
123k views
Using Maven properties in application.properties in Spring Boot
I'm trying to load properties from pom.xml into application.properties. I want to create two profiles: dev and prod to use different database urls. I'm using Jenkins as CI, in all my apps (Spring MVC ...
16 votes
5 answers
82k views
spring boot external config
I am trying to load an external properties file into my spring boot app. initially I used @PropertySource in the config class. but now I want to remove this annotation so the class is not dependent on ...
16 votes
1 answer
15k views
Issue overriding application properties in Spring-boot (profile-specific) application launched with PropertiesLauncher
I'm having difficulty trying to override a property declared in a profile-specific application properties file on the classpath with another value declared in an overrides file on the file system. I ...
0 votes
1 answer
6k views
Spring Boot custom error controller returning empty JSON response
I got a Spring Boot app. I have configured a custom error controller to handle 404 errors. It is returning an empty response. I got log statements which shows that the custom error controller method ...
1 vote
1 answer
4k views
How to property file value in Spring boot config class
How to use a application.properties file in Config class application.properties datasource.username=test Config.class @Configuration @EnableTransactionManagement @EnableJpaRepositories( ...
3 votes
2 answers
3k views
Spring Boot - Externalized properties
I've got a Spring Boot project that builds an executable war and is configured with an application.properties file and a application-dev.properties in src/main/resources. The first line in the ...
1 vote
2 answers
2k views
Environment specific application.properties in springboot Application
I'm trying to automate the process of deploying code using github and jenkins job to deploy my Springboot Application on AWS . I want to know where should I place the application.properties file in ...
1 vote
1 answer
1k views
what is the idiomatic way to use ConfigurationProperties and EnableConfigurationProperties in tests?
i am trying to setup unit tests for some elements to be used within a spring(-boot) application, and i struggled with setup around ConfigurationProperties and EnableConfigurationProperties. the way i ...
0 votes
1 answer
1k views
How to externalize configuration in Spring Boot using profiles?
I have an application where I would like to change a datasource password that is stored in a application.yml file. The password in the YML file is stored such as this: ---- spring: profiles: ...
1 vote
3 answers
522 views
Setup spring-boot app on tomcat
I followed a simple guide and created a spring-boot based web application on my local, using embedded tomcat, it works fine. The next step I am trying to deploy it onto a remote linux tomcat server. I ...
0 votes
1 answer
325 views
springboot config externalization with different file name
I am learning spring boot config externalization. I would like my application to read configuration from any external file (/Users/<userid>/application.properties). I created spring-web project,...