最总要的 是 加上 下面 这段代码
<!--将properties和xml文件编译-->
<resource>
<directory>src/main/resources</directory>
<includes>
<include>**/*.properties</include>
<include>**/*.xml</include>
</includes>
<filtering>false</filtering>
</resource>
application.properties