Java / Quarkus Interview questions
Define Quarkus configuration profiles?
Configuration profiles let a single Quarkus application define different sets of configuration values for different environments — development, testing, and production — without maintaining entirely separate configuration files or code branches.
%dev.quarkus.datasource.jdbc.url=jdbc:h2:mem:devdb %test.quarkus.datasource.jdbc.url=jdbc:h2:mem:testdb quarkus.datasource.jdbc.url=jdbc:postgresql://prod-db:5432/app
Quarkus ships three built-in profiles — dev (active under quarkus:dev), test (active during mvn test), and prod (the default when neither of the others applies) — and any property can be scoped to one of them using the %profile. prefix shown above; an unprefixed property applies to all profiles unless a profile-specific override exists.
Custom profiles beyond the three built-in ones are also supported for more specific scenarios, such as a staging profile, activated by setting the quarkus.profile system property or the QUARKUS_PROFILE environment variable at startup.
More Related questions...
