官术网_书友最值得收藏!

YAML for properties

Spring Boot supports YAML for properties as an alternative to properties files. YAML is convenient for hierarchical configuration data. Spring Boot properties are organized in groups, for example, server, database, and so on.

Let's see the following properties:

  • In application.properties:
database.host = localhost 
database.user = admin
  • In application.yml:
database:  
   host: localhost 
   user: admin 

Let's see, in the following section, how to define multiple profiles in a single YAML file.

主站蜘蛛池模板: 尉犁县| 内乡县| 宁强县| 镇江市| 晴隆县| 北海市| 武川县| 科技| 呼玛县| 望谟县| 汪清县| 潍坊市| 苍梧县| 黑河市| 河源市| 鹤壁市| 呼图壁县| 仪征市| 高密市| 枣庄市| 阿克苏市| 江孜县| 阿荣旗| 瓦房店市| 渝中区| 涟水县| 大名县| 五常市| 视频| 江永县| 会同县| 泾阳县| 秭归县| 潼关县| 白山市| 德清县| 吴桥县| 锡林浩特市| 青州市| 聊城市| 泗阳县|