RandomValuePropertySource:配置文件中可以使用随机数

  ${Random.value}  ${random.int}, ${random.long}, ${random.int(10)}, ${random.int[1024,65536]}

属性配置占位符

  app.name=MyApp

  app.description=${app.name} is application

  可以在配置文件中引用前面配置过的属性

  ${app.name:默认值}来指定找不到属性时候的默认值

相关文章:

  • 2022-01-06
  • 2022-12-23
  • 2022-12-23
  • 2022-01-15
  • 2022-12-23
  • 2021-06-07
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-11-07
  • 2021-04-12
  • 2022-12-23
  • 2022-02-21
  • 2021-11-30
  • 2021-12-19
  • 2021-10-20
相关资源
相似解决方案