错误描述
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 6.271 s
[INFO] Finished at: 2020-10-14T17:06:23+08:00
[INFO] Final Memory: 41M/358M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:3.1.0:resources (default-resources) on project app-manage: Unable to parse configuration of mojo org.apac
he.maven.plugins:maven-resources-plugin:3.1.0:resources for parameter delimiters: Cannot assign configuration entry 'delimiters' with value '@' of type java.lang.String to property of
type java.util.LinkedHashSet -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginConfigurationException
原因解释
mvn版本低了,项目中使用到了下述插件:
application.yml
logging:
file:
path: logs
config: classpath:logback-spring.xml
spring:
profiles:
active: @profile.active@
pom.xml
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<configuration>
<delimiters>@</delimiters>
<useDefaultDelimiters>false</useDefaultDelimiters>
</configuration>
</plugin>
application.yml中使用@来定义不同环境的配置,pom中使用了插件来消除默认的@转义,导致低版本的manen不能正常使用。
解决方案
换用高版本maven,笔者升级到了3.5.4