smallrye-reactive-messaging: Overriding a config property with hypen at runtime fails with an exception at startup
Starting a Quarkus application with version 1.13.5.Final+ breaks the configuration of config keys with hyphens that are overriden with environment variables.
Example: mp.messaging.incoming.keycloak-events.connector and MP_MESSAGING_INCOMING_KEYCLOAK_EVENTS_CONNECTOR=smallrye-in-memory
I found out that in the end, the ConfigSource ends up with two properties.
smallrye-config/1.13.1/smallrye-config-1.13.1-sources.jar!/io/smallrye/config/EnvConfigSource.java

The problem is, that MP_MESSAGING_INCOMING_KEYCLOAK_EVENTS_CONNECTOR is converted to mp.messaging.incoming.keycloak.events.connector, but in the application.properties file the key is mp.messaging.incoming.keycloak-events.connector. So the problem is keycloak vs keycloak-events.
I have added a reproducer: https://github.com/ahofmeister/mp-messaging-config-hyphen-reproducer
Please note: It works with Quarkus 1.11.6.Final. (Also note, the reproducer will fail, because of SRMSG00072: Unknown connector forkeycloak-events., which is fine in this case!)
CC @radcortez
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 23 (15 by maintainers)
Doing the update right now.