JAVA-19547 Move articles from spring-core-2 module to spring-boot modules (#13730)
This commit is contained in:
parent
dd5badab9c
commit
6212b272fc
|
@ -7,3 +7,4 @@ This module contains articles about configuring the Spring Boot `Environment`
|
|||
- [Spring Properties File Outside jar](https://www.baeldung.com/spring-properties-file-outside-jar)
|
||||
- [Get the Running Port in Spring Boot](https://www.baeldung.com/spring-boot-running-port)
|
||||
- [Environment Variable Prefixes in Spring Boot 2.5](https://www.baeldung.com/spring-boot-env-variable-prefixes)
|
||||
- [Spring Profiles](http://www.baeldung.com/spring-profiles)
|
||||
|
|
|
@ -133,8 +133,23 @@
|
|||
</plugins>
|
||||
</build>
|
||||
</profile>
|
||||
<profile>
|
||||
<id>dev</id>
|
||||
<activation>
|
||||
<activeByDefault>true</activeByDefault>
|
||||
</activation>
|
||||
<properties>
|
||||
<spring.profiles.active>dev</spring.profiles.active>
|
||||
</properties>
|
||||
</profile>
|
||||
<profile>
|
||||
<id>prod</id>
|
||||
<properties>
|
||||
<spring.profiles.active>prod</spring.profiles.active>
|
||||
</properties>
|
||||
</profile>
|
||||
</profiles>
|
||||
|
||||
|
||||
<properties>
|
||||
<jpa.version>2.2</jpa.version>
|
||||
<subethasmtp.version>3.1.7</subethasmtp.version>
|
||||
|
|
|
@ -4,4 +4,34 @@ management.metrics.enable.jvm=true
|
|||
management.endpoint.restart.enabled=true
|
||||
spring.datasource.tomcat.jmx-enabled=false
|
||||
management.endpoint.shutdown.enabled=true
|
||||
spring.config.import=file:./additional.properties,optional:file:/Users/home/config/jdbc.properties
|
||||
spring.config.import=file:./additional.properties,optional:file:/Users/home/config/jdbc.properties
|
||||
|
||||
#---
|
||||
spring.profiles.active=@spring.profiles.active@
|
||||
|
||||
my.prop=used-always-in-all-profiles
|
||||
|
||||
#---
|
||||
spring.config.activate.on-profile=dev
|
||||
#spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
|
||||
#spring.datasource.url=jdbc:mysql://localhost:3306/db
|
||||
#spring.datasource.username=root
|
||||
#spring.datasource.password=root
|
||||
|
||||
#---
|
||||
spring.config.activate.on-profile=production
|
||||
#spring.datasource.driver-class-name=org.h2.Driver
|
||||
#spring.datasource.url=jdbc:h2:mem:db;DB_CLOSE_DELAY=-1
|
||||
#spring.datasource.username=sa
|
||||
#spring.datasource.password=sa
|
||||
|
||||
#---
|
||||
spring.profiles.group.production=proddb,prodquartz
|
||||
|
||||
#---
|
||||
spring.config.activate.on-profile=proddb
|
||||
db=url_to_production_db
|
||||
|
||||
#---
|
||||
spring.config.activate.on-profile=prodquartz
|
||||
quartz=url_to_quartz_scheduler
|
|
@ -2,3 +2,4 @@
|
|||
|
||||
- [Spring Validation in the Service Layer](https://www.baeldung.com/spring-service-layer-validation)
|
||||
- [Validation in Spring Boot](https://www.baeldung.com/spring-boot-bean-validation)
|
||||
- [Spring Null-Safety Annotations](https://www.baeldung.com/spring-null-safety-annotations)
|
|
@ -4,8 +4,6 @@ This module contains articles about core Spring functionality
|
|||
|
||||
## Relevant Articles:
|
||||
|
||||
- [Spring Profiles](http://www.baeldung.com/spring-profiles)
|
||||
- [Quick Guide to Spring Bean Scopes](http://www.baeldung.com/spring-bean-scopes)
|
||||
- [Spring Events](https://www.baeldung.com/spring-events)
|
||||
- [Spring Null-Safety Annotations](https://www.baeldung.com/spring-null-safety-annotations)
|
||||
- More articles: [[<-- prev]](/spring-core)[[next -->]](/spring-core-3)
|
||||
|
|
|
@ -162,24 +162,6 @@
|
|||
</plugins>
|
||||
</build>
|
||||
|
||||
<profiles>
|
||||
<profile>
|
||||
<id>dev</id>
|
||||
<activation>
|
||||
<activeByDefault>true</activeByDefault>
|
||||
</activation>
|
||||
<properties>
|
||||
<spring.profiles.active>dev</spring.profiles.active>
|
||||
</properties>
|
||||
</profile>
|
||||
<profile>
|
||||
<id>prod</id>
|
||||
<properties>
|
||||
<spring.profiles.active>prod</spring.profiles.active>
|
||||
</properties>
|
||||
</profile>
|
||||
</profiles>
|
||||
|
||||
<properties>
|
||||
<start-class>com.baeldung.sample.App</start-class>
|
||||
<!-- Spring -->
|
||||
|
|
|
@ -1,28 +0,0 @@
|
|||
spring.profiles.active=@spring.profiles.active@
|
||||
|
||||
my.prop=used-always-in-all-profiles
|
||||
|
||||
#---
|
||||
spring.config.activate.on-profile=dev
|
||||
spring.datasource.driver-class-name=com.mysql.cj.jdbc.Driver
|
||||
spring.datasource.url=jdbc:mysql://localhost:3306/db
|
||||
spring.datasource.username=root
|
||||
spring.datasource.password=root
|
||||
|
||||
#---
|
||||
spring.config.activate.on-profile=production
|
||||
spring.datasource.driver-class-name=org.h2.Driver
|
||||
spring.datasource.url=jdbc:h2:mem:db;DB_CLOSE_DELAY=-1
|
||||
spring.datasource.username=sa
|
||||
spring.datasource.password=sa
|
||||
|
||||
#---
|
||||
spring.profiles.group.production=proddb,prodquartz
|
||||
|
||||
#---
|
||||
spring.config.activate.on-profile=proddb
|
||||
db=url_to_production_db
|
||||
|
||||
#---
|
||||
spring.config.activate.on-profile=prodquartz
|
||||
quartz=url_to_quartz_scheduler
|
Loading…
Reference in New Issue