2012-04-11 13 views
3

Mavenを使用してJavadoc(正常に作成されたもの)をSharepointサーバーに展開しようとしていますが、NTLM認証が必要です。私はこれを行うには、WebDAVプロバイダでMaven Wagonプラグインを使用しています。私はm2eclipseを使用して、特定のプロファイル内のゴールを実行するための実行コンフィギュレーションを設定しています。Maven Wagon WebDAVプロバイダーを介したJavadocのNTLM認証サーバーへの展開

私は本質的に、これらのツールに関するさまざまなソリューションのソリューションをまとめました。 NTLMが現在Mavenでサポートされていない可能性があると思われますが、他のページではタグがこれを許可する可能性があります。また、Apacheの使用ページとは異なり、配布サイトが配布管理で指定されているソリューションも見てきました。とにかく、私はいくつかの問題に遭遇しています。

まず、 'wagon:upload'ゴールの実行を含むワゴンプラグイン( 'リリース'プロファイル内で 'クリーン'と 'パッケージ'を実行する)実行設定メニューから実行すると、 'パッケージ'フェーズでは、実行は無視されます。プロジェクトジャーとJavadocを作成してソースを添付しますが、Wagonプラグインは実行されません。

私も実行しようとしてきた「ワゴン:アップロード」のJavadocを個別に作成された後、独自の目標を、私は(デバッグ中)このエラーが発生した:

[DEBUG] Configuring mojo org.codehaus.mojo:wagon-maven-plugin:1.0-beta-3:upload 
from plugin realm ClassRealm[plugin>org.codehaus.mojo:wagon-maven-plugin:1.0-bet 
a-3, parent: [email protected]] 
[DEBUG] Configuring mojo 'org.codehaus.mojo:wagon-maven-plugin:1.0-beta-3:upload 
' with basic configurator --> 
[DEBUG] (f) followSymLink = false 
[DEBUG] (f) fromDir = C:\Documents and Settings\c40208\IBM\rationalsdp\CEC\cec 
-diagnostics 
[DEBUG] (f) optimize = false 
[DEBUG] (f) project = MavenProject: com.mycompany.cec:cec-diagnostics:0.5.0-SNAPSH 
OT @ C:\Documents and Settings\c40208\IBM\rationalsdp\CEC\cec-diagnostics\pom.xm 
l 
[DEBUG] (f) serverId = serverId 
[DEBUG] (f) settings = [email protected] 
[DEBUG] (f) skip = false 
[DEBUG] (f) useDefaultExcludes = true 
[DEBUG] -- end configuration -- 
[INFO] ------------------------------------------------------------------------ 
[INFO] BUILD FAILURE 
[INFO] ------------------------------------------------------------------------ 
[INFO] Total time: 1.687s 
[INFO] Finished at: Fri Apr 13 08:54:34 EDT 2012 
[INFO] Final Memory: 5M/15M 
[INFO] ------------------------------------------------------------------------ 
[ERROR] Failed to execute goal org.codehaus.mojo:wagon-maven-plugin:1.0-beta-3:u 
pload (default-cli) on project cec-diagnostics: The parameters 'url' for goal or 
g.codehaus.mojo:wagon-maven-plugin:1.0-beta-3:upload are missing or invalid -> [ 
Help 1] 
    org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal o 
rg.codehaus.mojo:wagon-maven-plugin:1.0-beta-3:upload (default-cli) on project c 
ec-diagnostics: The parameters 'url' for goal org.codehaus.mojo:wagon-maven-plug 
in:1.0-beta-3:upload are missing or invalid 
     at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor 
.java:221) 
     at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor 
.java:153) 
     at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor 
.java:145) 
     at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProje 
ct(LifecycleModuleBuilder.java:84) 
     at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProje 
ct(LifecycleModuleBuilder.java:59) 
     at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBu 
ild(LifecycleStarter.java:183) 
     at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(Lifecycl 
eStarter.java:161) 
     at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:320) 
     at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156) 
     at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537) 
     at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196) 
     at org.apache.maven.cli.MavenCli.main(MavenCli.java:141) 
     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) 
     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl. 
java:39) 
     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces 
sorImpl.java:25) 
     at java.lang.reflect.Method.invoke(Method.java:597) 
     at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Laun 
cher.java:290) 
     at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.jav 
a:230) 
     at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(La 
uncher.java:409) 
     at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java: 
352) 
Caused by: org.apache.maven.plugin.PluginParameterException: The parameters 'url 
' for goal org.codehaus.mojo:wagon-maven-plugin:1.0-beta-3:upload are missing or 
invalid 
     at org.apache.maven.plugin.internal.DefaultMavenPluginManager.populatePl 
uginFields(DefaultMavenPluginManager.java:576) 
     at org.apache.maven.plugin.internal.DefaultMavenPluginManager.getConfigu 
redMojo(DefaultMavenPluginManager.java:529) 
     at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(Default 
BuildPluginManager.java:92) 
     at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor 
.java:209) 
     ... 19 more 
[ERROR] 
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please rea 
d the following articles: 
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginParamete 
rException 

私はそれを知っています私の道に沿って私を助けてくれる助言や提案は誰にもありますか?うまくいけば、私が会社の関連サイトを検閲しなければならなかったという事実にもかかわらず、何が起こっているのか理解しています

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> 
<modelVersion>4.0.0</modelVersion> 
<groupId>com.mycompany.cec</groupId> 
<artifactId>cec-diagnostics</artifactId> 
<version>0.5.0-SNAPSHOT</version> 
<packaging>jar</packaging> 
<name>CEC Diagnostics Jar</name> 
<description><![CDATA[Assertion capture and analysis library for Java]]]></description> 
<inceptionYear>2011</inceptionYear> 
<scm> 
    <developerConnection>scm:svn:(FQDN)/(path)</developerConnection> 
    <url>(FQDN)/(path)</url> 
</scm> 
<properties> 
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> 
    <spring.framework.version>3.0.5.RELEASE</spring.framework.version> 
    <jar.plugin.version>2.4</jar.plugin.version> 
    <bundle.plugin.version>2.3.6</bundle.plugin.version> 
    <surefire.plugin.version>2.12</surefire.plugin.version> 
    <testng.version>6.3.1</testng.version> 
    <javadoc.plugin.version>2.8.1</javadoc.plugin.version> 
    <source.plugin.version>2.1.2</source.plugin.version> 
    <wagon.plugin.version>1.0-beta-3</wagon.plugin.version> 
    <project.info.reports.plugin.version>2.4</project.info.reports.plugin.version> 
    <site.plugin.version>3.0</site.plugin.version> 
    <pdf.plugin.version>1.2</pdf.plugin.version> 
    <confluence.plugin.version>3.1.3</confluence.plugin.version> 
    <confluence.root>http://confluence.sys.mycompany.com/confluence</confluence.root> 
    <confluence.space>SEI</confluence.space> 
</properties> 
<dependencies> 
    <dependency> 
     <groupId>org.springframework</groupId> 
     <artifactId>spring-core</artifactId> 
     <version>${spring.framework.version}</version> 
    </dependency> 
    <dependency> 
     <groupId>org.springframework</groupId> 
     <artifactId>spring-context</artifactId> 
     <version>${spring.framework.version}</version> 
    </dependency> 
    <dependency> 
     <groupId>org.springframework</groupId> 
     <artifactId>spring-context-support</artifactId> 
     <version>${spring.framework.version}</version> 
    </dependency> 
    <dependency> 
     <groupId>org.testng</groupId> 
     <artifactId>testng</artifactId> 
     <version>${testng.version}</version> 
    </dependency> 
</dependencies> 
<build> 
    <plugins> 
     <plugin> 
      <groupId>org.apache.maven.plugins</groupId> 
      <artifactId>maven-jar-plugin</artifactId> 
      <version>${jar.plugin.version}</version> 
      <configuration> 
       <archive> 
        <index>true</index> 
        <manifest> 
         <addClasspath>true</addClasspath> 
        </manifest> 
        <manifestEntries> 
         <Specification-Title>${project.name}</Specification-Title> 
         <Specification-Version>${project.version}</Specification-Version> 
         <Specification-Vendor>${project.organization.name}</Specification-Vendor> 
         <Implementation-Title>${project.name}</Implementation-Title> 
         <Implementation-Version>${project.version}</Implementation-Version> 
        </manifestEntries> 
       </archive> 
      </configuration> 
     </plugin> 
     <plugin> 
      <groupId>org.apache.felix</groupId> 
      <artifactId>maven-bundle-plugin</artifactId> 
      <version>${bundle.plugin.version}</version> 
      <executions> 
       <execution> 
        <id>bundle-manifest</id> 
        <phase>process-classes</phase> 
        <goals> 
         <goal>manifest</goal> 
        </goals> 
       </execution> 
      </executions> 
     </plugin> 
    </plugins> 
    <extensions> 
     <extension> 
      <groupId>org.apache.maven.wagon</groupId> 
      <artifactId>wagon-webdav-jackrabbit</artifactId> 
      <version>2.2</version> 
     </extension> 
    </extensions> 
</build> 
<profiles> 
    <profile> 
     <id>release</id> 
     <build> 
      <plugins> 
       <plugin> 
        <groupId>org.apache.maven.plugins</groupId> 
        <artifactId>maven-javadoc-plugin</artifactId> 
        <version>${javadoc.plugin.version}</version> 
        <executions> 
         <execution> 
          <id>attach-javadocs</id> 
          <goals> 
           <goal>jar</goal> 
          </goals> 
         </execution> 
        </executions> 
        <configuration> 
         <additionalJOption>-J-Dhttp.auth.ntlm.domain=dav:https//(domain)</additionalJOption> 
        </configuration> 
       </plugin> 
       <plugin> 
        <groupId>org.apache.maven.plugins</groupId> 
        <artifactId>maven-source-plugin</artifactId> 
        <version>${source.plugin.version}</version> 
        <executions> 
         <execution> 
          <id>attach-sources</id> 
          <goals> 
           <goal>jar-no-fork</goal> 
          </goals> 
         </execution> 
        </executions> 
       </plugin> 
       <plugin> 
        <groupId>org.codehaus.mojo</groupId> 
        <artifactId>wagon-maven-plugin</artifactId> 
        <version>${wagon.plugin.version}</version> 
        <executions> 
         <execution> 
          <id>upload-javadocs</id> 
          <phase>package</phase> 
          <goals> 
           <goal>upload</goal> 
          </goals> 
          <configuration> 
           <serverId>(serverId)</serverId> 
           <fromDir>${project.build.directory}/apidocs</fromDir> 
           <includes>*</includes> 
           <excludes>pom.xml</excludes> 
           <url>dav:https://(domain)/(path)</url> 
           <toDir>(path)</toDir> 
           <optimize>true</optimize> 
          </configuration> 
         </execution> 
        </executions> 
       </plugin> 
       <plugin> 
        <groupId>org.apache.maven.plugins</groupId> 
        <artifactId>maven-site-plugin</artifactId> 
        <version>${site.plugin.version}</version> 
       </plugin> 
      </plugins> 
     </build> 
    </profile> 
</profiles> 
<reporting> 
    <plugins> 
     <plugin> 
      <groupId>org.apache.maven.plugins</groupId> 
      <artifactId>maven-project-info-reports-plugin</artifactId> 
      <version>${project.info.reports.plugin.version}</version> 
      <reportSets> 
       <reportSet> 
        <reports> 
         <report>summary</report> 
         <report>project-team</report> 
         <report>plugins</report> 
         <report>dependencies</report> 
         <report>scm</report> 
         <report>cim</report> 
         <report>issue-tracking</report> 
        </reports> 
       </reportSet> 
      </reportSets> 
     </plugin> 
     <plugin> 
      <groupId>org.apache.maven.plugins</groupId> 
      <artifactId>maven-javadoc-plugin</artifactId> 
      <version>${javadoc.plugin.version}</version> 
      <configuration> 
       <show>public</show> 
      </configuration> 
     </plugin> 
    </plugins> 
</reporting> 
<repositories> 
    (repositories) 
</repositories> 
<distributionManagement> 
    (repositories) 
</distributionManagement> 
<developers> 
    (developers) 
</developers> 
</project> 

は、ここに私のPOMファイルです。

<proxy> 
    <active>true</active> 
    <protocol>https</protocol> 
    <host>(host address)</host> 
    <port>9090</port> 
    <username>(username)</username> 
    <password>(password)</password> 
    <nonProxyHosts>*.mycompany.com</nonProxyHosts> 
</proxy> 

サーバー:

<server> 
    <id>(the same serverId from the POM)</id> 
    <username>(username)</username> 
    <password>(password)</password> 
</server> 

おかげで多くのことを次のようにまた、私は、のsettings.xmlにプロキシとサーバーの設定を追加しました。

答えて

0

あなたのURLは<url>dav:http://...</url>のようになります。

最初にベータ-4を試してから、コマンドごとに-Dwagon.url =のように設定してください。それでも動作しない場合は、CodehausのJIRAでチケットを提出する必要があります。 source codeは問題ありません。これは注射の問題です。 Mavenの別のバージョンを試すことはできますか?

+0

ありがとうございました。私はそれを修正しましたが、それでも同じエラーがスローされます。 –

+0

デバッグフラグ '-X'を試してください! –

+0

デバッグの詳細を含めるように質問を編集しましたが、全体的に私には分かりません。 –

関連する問題