2012-12-15 123 views
0

時,我一直在嘗試使用maven錯誤使用Maven插件WebLogic部署

我創建的WebLogic插件的Maven在this文章中提到的部署應用程序到Weblogic 10.3.6。

我已經加入了以下內容的pom.xml

<build> 
    <plugins> 
    <plugin> 
     <artifactId>maven-plugin-plugin</artifactId> 
     <version>2.3</version> 
     <configuration> 
     <goalPrefix>weblogic</goalPrefix> 
     </configuration> 
    </plugin> 
    <plugin> 
    <groupId>weblogic</groupId> 
    <artifactId>weblogic-maven-plugin</artifactId> 
    <version>10.3.6.0</version> 
    <configuration> 
    <adminurl>t3://localdomain:7001</adminurl> 
    <user>weblogic</user> 
    <password>password</password> 
    <name>wldemo</name> 
    <remote>true</remote> 
    <upload>true</upload> 
    <targets>AdminServer</targets> 
    </configuration> 
    <executions> 
    <execution> 
     <id>deploy</id> 
     <phase>pre-integration-test</phase> 
     <goals> 
     <goal>deploy</goal> 
     </goals> 
     <configuration> 
     <source>target/EmployeesApp-1.0-SNAPSHOT.war</source> 
     </configuration> 
    </execution> 
    </executions> 
</plugin> 
    </plugins> 
</build> 

當我做MVN com.oracle.weblogic:WebLogic的Maven的插件:部署我收到以下錯誤,我怎麼能解決這些錯誤?

[INFO] BUILD FAILURE 
[INFO] ------------------------------------------------------------------------ 
[INFO] Final Memory: 3M/15M 
[INFO] ------------------------------------------------------------------------ 
[ERROR] Failed to execute goal com.oracle.weblogic:weblogic-maven-plugin:10.3.6. 
0:deploy (default-cli) on project EmployeesApp: The parameters 'source' for goal 
com.oracle.weblogic:weblogic-maven-plugin:10.3.6.0:deploy are missing or invali 
d 

回答

0

您已指定在執行配置的參數,所以爲了讓它考慮您應該調用這個特殊的執行。它可以使用指定的相鍵來完成,所以如:

mvn integration-test 

Maven會經歷的整個生命週期,並在預集成測試測試階段(這之前的集成測試一個)它將運行您配置的weblogic-maven-plugin的執行。