[英]HEROKU use -source 7 or higher to enable diamond operator
我試圖部署在Java EE平台中構建的應用程序。 當我運行命令git push heroku master
,在部署完成時會生成許多錯誤。
主要的例外是: use -source 7 or higher to enable diamond operator
。
有人對此錯誤有想法嗎? 波紋管是更多錯誤消息。 謝謝您的幫助。
[ERROR] -> [Help 1]
remote: [ERROR]
remote: [ERROR] To see the full stack trace of the errors, re-run
Maven with the -e switch.
remote: [ERROR] Re-run Maven using the -X switch to enable full
debug logging.
remote: [ERROR]
remote: [ERROR] For more information about the errors and possible
solutions, please read the following articles:
remote: [ERROR] [Help 1]
http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
remote:
remote: ! ERROR: Failed to build app with Maven
remote: We're sorry this build is failing! If you can't find the
issue in application code,
remote: please submit a ticket so we can help:
https://help.heroku.com/
remote:
remote: ! Push rejected, failed to compile Java app.
remote:
remote: ! Push failed
remote: Verifying deploy...
remote:
remote: ! Push rejected to wiidas-jee.
將以下插件和配置添加到pom.xml
:
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
然后運行:
$ git add pom.xml
$ git commit -m "pom.xml"
$ git push heroku master
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.