java - external yaml property file and normal properties file in spring boot -
this how have set external configuration file
/** .yaml file @configuration @propertysource("classpath:waterlvl.yaml") @configurationproperties("alerts") public class waterlvlalertconfig { /** .properties file @component @propertysource("classpath:waterlvl.properties") public class waterlvlconfig {
properties not being picked up, , files inside resources file. think path i'm providing wrong.what doing wrong.
in spring boot @propertysource cannot used when using .yaml configuration. refer point 24.6.4 yaml shortcomings in externalized configuration documents. also, similar question answered earlier, refer - spring boot external configuration of property file
Comments
Post a Comment