简体   繁体   中英

wildfly-maven-plugin --> No plugin found for prefix 'wildfly'

When I use wildfly-maven-plugin I get a strange behaviour. I think it is my mistake but I can not figure out what the problem is.
I defined a goal under the wildfly-maven-plugin so when I use maven install then everything is fine and the ear is going to deploy.

I did not want to deploy the ear automatically so I removed the executions section and I used the mvn wildfly:deploy but I got an error. If I do not remove this section than the impact is same.

[ERROR] No plugin found for prefix 'wildfly' in the current project and in the plugin groups [org.apache.maven.plugins, org.codehaus.mojo]

pom.xml

<plugin>
  <groupId>org.wildfly.plugins</groupId>
  <artifactId>wildfly-maven-plugin</artifactId>
  <version>1.0.2.Final</version>
  <configuration>
    <filename>${project.name}-${parent.artifactId}-${version}.ear</filename>
  </configuration>
  <executions>
    <execution>
      <phase>install</phase>
      <goals>
        <goal>redeploy</goal>
      </goals>
    </execution>
  </executions>
</plugin>

The -X command does not provides any useful info.

Use the FQN (Fully Qualified Name) of the maven goal.

mvn org.wildfly.plugins:wildfly-maven-plugin:deploy

Should very explicitly start the wildfly deploy goal and use the configuration you have specified.

The goal shortcuts only works in your configured pluginGroups in settings.xml, and as you can see it only checks 2 groups [org.apache.maven.plugins, org.codehaus.mojo]

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM