在@configuration文件中而不是在perseatoton.properties文件中设置spring.application.name的适当方法是什么?
谢谢Brian
基本上我想设置应用程序名称与 以下:缅因疗程杂色 myversion-snapshot
从文档中,您可以使用@..@
占位符,如果您使用spring-boot-starter-parent
(通常大多数Spring-Boot Project已经使用),请参考pom.xml
中的属性。
so在application.properties
中:
spring.application.name=@artifactId@-@version@