Skip to content

Commit 9ea9a9f

Browse files
radcortezgsmet
authored andcommitted
Remove customizer mappings from runtime recording Config
(cherry picked from commit ada7e07)
1 parent 84186cd commit 9ea9a9f

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

core/deployment/src/main/java/io/quarkus/deployment/configuration/BuildTimeConfigurationReader.java

+12
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,7 @@
8484
import io.smallrye.config.SecretKeys;
8585
import io.smallrye.config.SmallRyeConfig;
8686
import io.smallrye.config.SmallRyeConfigBuilder;
87+
import io.smallrye.config.SmallRyeConfigBuilderCustomizer;
8788
import io.smallrye.config.SysPropConfigSource;
8889
import io.smallrye.config.common.AbstractConfigSource;
8990

@@ -1112,6 +1113,17 @@ private SmallRyeConfig getConfigForRuntimeRecording() {
11121113
builder.getProfiles().add("");
11131114
builder.getSources().clear();
11141115
builder.getSourceProviders().clear();
1116+
builder.withCustomizers(new SmallRyeConfigBuilderCustomizer() {
1117+
@Override
1118+
public void configBuilder(final SmallRyeConfigBuilder builder) {
1119+
builder.getMappingsBuilder().getMappings().clear();
1120+
}
1121+
1122+
@Override
1123+
public int priority() {
1124+
return Integer.MAX_VALUE;
1125+
}
1126+
});
11151127
builder.setAddDefaultSources(false)
11161128
// Customizers may duplicate sources, but not much we can do about it, we need to run them
11171129
.addDiscoveredCustomizers()

0 commit comments

Comments
 (0)