本文共 1466 字,大约阅读时间需要 4 分钟。
wildfly-maven-plugin插件主要用于在WildFly AS服务器上对JavaEE应用进行部署、再次部署、运行和取消部署等操作。
wildfly-maven-plugin插件的最新版本是2016.4发布的1.1.0.Alpha8。
1. wildfly-maven-plugin插件的基本信息:
org.wildfly.plugins wildfly-maven-plugin 1.1.0.Alpha8
2. wildfly-maven-plugin插件提供的goal:
- adds a resource.
- deploys application to the server.
- deploys the application to application server invoking no other goals by default.
- deploys an arbitrary artifact to the server.
- redeploys the application.
- redeploys the application invoking no other goals by default.
- undeploys the application.
- runs the application server and deploys your application.
- starts the application server and leaves the process running. In most cases the shutdown goal be executed to ensure the server is shutdown.
- shuts down a running application server.
- executes commands on the running server.
3. wildfly-maven-plugin插件可以直接执行其goal如下:
mvn wildfly:deploy
也可以将wildfly-maven-plugin插件提供的goal直接嵌入到Maven内置的生命周期阶段。如下所示,将wildfly:deploy嵌入到Maven的install阶段:
org.wildfly.plugins wildfly-maven-plugin 1.1.0.Alpha8 install deploy
这样,在执行mvn install的过程中,将会直接调用wildfly:deploy。
参考文献:
转载地址:http://ojlai.baihongyu.com/