- Notifications
You must be signed in to change notification settings - Fork 41.7k
Closed
Closed
Copy link
Labels
status: supersededAn issue that has been superseded by anotherAn issue that has been superseded by anothertype: bugA general bugA general bug
Description
Syntax improvement in the log output:
The standard logging output reports the active profile(s) used but the sentence is always in plural form (The following profiles are active):
... 2022-01-10 17:07:48.046 INFO 14436 --- [ restartedMain] com.mycompany.myapp.TestApp : The following profiles are active: profile0 ... This is misleading when one profile is active but dangerous when more profiles are badly activated (read below).
Bad profile activation:
The comma is used as a separator in the environment variable parsing - i.e. running the application with:
-Dspring.profiles.active=profile0,profile1 However it is tempting to simply copy-paste profile0,profile1 in the active profile annotation and write:
@ActiveProfiles("profile0,profile1") This (wrong) profile activation would make spring-boot activate a single profile (whose name contains a comma).
The log output would still be expressed in plural form, misleading the developer to think two profiles are active.
Metadata
Metadata
Assignees
Labels
status: supersededAn issue that has been superseded by anotherAn issue that has been superseded by anothertype: bugA general bugA general bug