Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/maven/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
maven javadoc插件覆盖中央存储库_Maven_Javadoc_Maven Javadoc Plugin_Maven Jar Plugin_Doclet - Fatal编程技术网

maven javadoc插件覆盖中央存储库

maven javadoc插件覆盖中央存储库,maven,javadoc,maven-javadoc-plugin,maven-jar-plugin,doclet,Maven,Javadoc,Maven Javadoc Plugin,Maven Jar Plugin,Doclet,我对Maven Javadoc插件和自定义doclet有问题 我正在使用maven javadoc插件v2.10.1和一个定制的doclet,它基本上是一个maven jar项目 我还有一个settings.xml,它定义了一个自定义工件的central存储库 问题是每次我运行maven javadoc插件时,它都试图从https://repo.maven.apache.org/maven2,doclet自己从自定义工件解析。 调试输出也很奇怪,它说central存储库是https://repo

我对Maven Javadoc插件和自定义doclet有问题

我正在使用maven javadoc插件v2.10.1和一个定制的doclet,它基本上是一个maven jar项目

我还有一个
settings.xml
,它定义了一个自定义工件的
central
存储库

问题是每次我运行maven javadoc插件时,它都试图从
https://repo.maven.apache.org/maven2
,doclet自己从自定义工件解析。
调试输出也很奇怪,它说
central
存储库是
https://repo.maven.apache.org/maven2
快照
存储库是我的自定义快照工件。
它就像maven jar插件覆盖
settings.xml
central
存储库一样锁定

我如何告诉
maven jar插件
不要覆盖我的
central
存储库

调试日志如下所示:

Apache Maven 3.2.5 (12a6b3acb947671f09b81f49094c53f426d8cea1; 2014-12-14T18:29:23+01:00)
Maven home: PATH TO MAVEN
Java version: 1.8.0_51, vendor: Oracle Corporation
Java home: PATH TO JRE
Default locale: de_DE, platform encoding: UTF-8
OS name: "windows 7", version: "6.1", arch: "amd64", family: "dos"
[DEBUG] Reading global settings from PATH TO MAVEN\conf\settings.xml
[DEBUG] Reading user settings from PATH TO USER\.m2\settings.xml
[DEBUG] Using local repository at PATH TO LOCAL REPOSITORY
[DEBUG] Using manager EnhancedLocalRepositoryManager with priority 10.0 for PATH TO LOCAL REPOSITORY
[DEBUG] Skipped remote request for PARENT POM AND VERSION/maven-metadata.xml, locally installed metadata up-to-date.
[DEBUG] Extension realms for project ARTIFACT AND VERSION: (none)
[DEBUG] Looking up lifecyle mappings for packaging war from ClassRealm[plexus.core, parent: null]
[DEBUG] Extension realms for project ARTITFACT AND VERSION: (none)
[DEBUG] Looking up lifecyle mappings for packaging pom from ClassRealm[plexus.core, parent: null]
[DEBUG] Extension realms for project PARENT POM AND VERSION: (none)
[DEBUG] Looking up lifecyle mappings for packaging pom from ClassRealm[plexus.core, parent: null]
[DEBUG] Extension realms for project PARENT POM AND VERSION: (none)
[DEBUG] Looking up lifecyle mappings for packaging pom from ClassRealm[plexus.core, parent: null]
[DEBUG] Extension realms for project PARENT POM AND VERSION: (none)
[DEBUG] Looking up lifecyle mappings for packaging pom from ClassRealm[plexus.core, parent: null]
[DEBUG] Resolving plugin version for org.apache.maven.plugins:maven-jar-plugin
[DEBUG] Could not find metadata org.apache.maven.plugins:maven-jar-plugin/maven-metadata.xml in local (PATH TO LOCAL REPOSITORY)
[DEBUG] Skipped remote request for org.apache.maven.plugins:maven-jar-plugin/maven-metadata.xml, locally cached metadata up-to-date.
[DEBUG] Failure to find org.apache.maven.plugins:maven-jar-plugin/maven-metadata.xml in PATH TO CUSTOM PLUGIN SNAPSHOT REPOSITORY was cached in the local repository, resolution will not be reattempted until the update interval of snapshots has elapsed or updates are forced
[DEBUG] Resolved plugin version for org.apache.maven.plugins:maven-jar-plugin to 2.6 from repository central (PATH TO CUSTOM PLUGIN RELEASE REPOSITORY, default, releases)
[DEBUG] Resolving plugin prefix javadoc from [org.apache.maven.plugins, org.codehaus.mojo]
[DEBUG] Resolved plugin prefix javadoc to org.apache.maven.plugins:maven-javadoc-plugin from POM ARTIFACT AND VERSION
[DEBUG] === REACTOR BUILD PLAN ================================================
[DEBUG] Project: ARTIFACT AND VERSION
[DEBUG] Tasks:   [javadoc:javadoc]
[DEBUG] Style:   Regular
[DEBUG] =======================================================================
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building ARTIFACT AND VERSION
[INFO] ------------------------------------------------------------------------
[DEBUG] Resolving plugin prefix javadoc from [org.apache.maven.plugins, org.codehaus.mojo]
[DEBUG] Resolved plugin prefix javadoc to org.apache.maven.plugins:maven-javadoc-plugin from POM ARTIFACT AND VERSION
[DEBUG] Lifecycle default -> [validate, initialize, generate-sources, process-sources, generate-resources, process-resources, compile, process-classes, generate-test-sources, process-test-sources, generate-test-resources, process-test-resources, test-compile, process-test-classes, test, prepare-package, package, pre-integration-test, integration-test, post-integration-test, verify, install, deploy]
[DEBUG] Lifecycle clean -> [pre-clean, clean, post-clean]
[DEBUG] Lifecycle site -> [pre-site, site, post-site, site-deploy]
[DEBUG] Lifecycle default -> [validate, initialize, generate-sources, process-sources, generate-resources, process-resources, compile, process-classes, generate-test-sources, process-test-sources, generate-test-resources, process-test-resources, test-compile, process-test-classes, test, prepare-package, package, pre-integration-test, integration-test, post-integration-test, verify, install, deploy]
[DEBUG] Lifecycle clean -> [pre-clean, clean, post-clean]
[DEBUG] Lifecycle site -> [pre-site, site, post-site, site-deploy]
[DEBUG] === PROJECT BUILD PLAN ================================================
[DEBUG] Project:       ARTIFACT AND VERSION
[DEBUG] Dependencies (collect): []
[DEBUG] Dependencies (resolve): [compile]
[DEBUG] Repositories (dependencies): [central (PATH TO CUSTOM LIBS RELEASE REPOSITORY, default, releases), snapshots (PATH TO CUSTOM LIBS SNAPSHOT REPOSITORY, default, releases+snapshots)]
[DEBUG] Repositories (plugins)     : [central (PATH TO CUSTOM PLUGIN RELEASE REPOSITORY, default, releases), snapshots (PATH TO CUSTOM PLUGIN SNAPSHOT REPOSITORY, default, releases+snapshots)]
[DEBUG] --- init fork of ARTIFACT AND VERSION for org.apache.maven.plugins:maven-javadoc-plugin:2.10.1:javadoc (default-cli) ---
[DEBUG] Dependencies (collect): []
[DEBUG] Dependencies (resolve): []
[DEBUG] -----------------------------------------------------------------------
[DEBUG] Goal:          org.codehaus.mojo:build-helper-maven-plugin:1.9.1:add-source (add-source)
[DEBUG] Style:         Regular
[DEBUG] Configuration: <?xml version="1.0" encoding="UTF-8"?>
<configuration>
  <sources>
    <source>PATH TO ARTIFACT\target/generated-sources</source>
  </sources>
  <project default-value="${project}"/>
</configuration>
[DEBUG] --- exit fork of ARTIFACT AND VERSION for org.apache.maven.plugins:maven-javadoc-plugin:2.10.1:javadoc (default-cli) ---
[DEBUG] -----------------------------------------------------------------------
[DEBUG] Goal:          org.apache.maven.plugins:maven-javadoc-plugin:2.10.1:javadoc (default-cli)
[DEBUG] Style:         Regular
[DEBUG] Configuration: <?xml version="1.0" encoding="UTF-8"?>
<configuration>
  <additionalparam>-Xdoclint:none </additionalparam>
  <doclet>PACKAGE AND CLASS OF CUSTOM DOCLET</doclet>
  <docletArtifact>${docletArtifact}</docletArtifact>
  <docletArtifacts>
    <docletArtifact>
      <groupId>CUSTOM DOCLET GROUP</groupId>
      <artifactId>CUSTOM DOCLET ARTIFACT</artifactId>
      <version>CUSTOM DOCLET VERSION</version>
    </docletArtifact>${docletArtifacts}</docletArtifacts>
  <docletPath>${docletPath}</docletPath>
 </configuration>
[DEBUG] =======================================================================
[INFO] 
[INFO] >>> maven-javadoc-plugin:2.10.1:javadoc (default-cli) > generate-sources @ ARTIFACT ID>>>
[INFO] 
[INFO] --- build-helper-maven-plugin:1.9.1:add-source (add-source) @ ARTIFACT ID---
[DEBUG] Created new class realm maven.api
[DEBUG] Importing foreign packages into class realm maven.api
[DEBUG] Configuring mojo 'org.codehaus.mojo:build-helper-maven-plugin:1.9.1:add-source' with basic configurator -->
[DEBUG]   (f) sources = [PATH TO ARTIFACT\target\generated-sources]
[DEBUG]   (f) project = MavenProject: ARTITFACT AND VERSION @ PATH TO ARTIFACT\pom.xml
[DEBUG] -- end configuration --
[INFO] Source directory: PATH TO ARTIFACT\target\generated-sources added.
[INFO] 
[INFO] <<< maven-javadoc-plugin:2.10.1:javadoc (default-cli) < generate-sources @ ARTIFACT ID <<<
[DEBUG] Dependency collection stats: {ConflictMarker.analyzeTime=0, ConflictMarker.markTime=15, ConflictMarker.nodeCount=148, ConflictIdSorter.graphTime=0, ConflictIdSorter.topsortTime=0, ConflictIdSorter.conflictIdCount=78, ConflictIdSorter.conflictIdCycleCount=2, ConflictResolver.totalTime=0, ConflictResolver.conflictItemCount=126, DefaultDependencyCollector.collectTime=437, DefaultDependencyCollector.transformTime=15}
[DEBUG] ARTIFACT AND VERSION
[DEBUG]    org.jvnet.jax-ws-commons.spring:jaxws-spring:jar:1.9:compile
[DEBUG]       javax.xml.ws:jaxws-api:jar:2.2.8:compile
[DEBUG]          javax.xml.bind:jaxb-api:jar:2.2.7-facets-1.0.5:compile (version managed from 2.2.4 by PARENT POM AND VERSION)
[DEBUG]          javax.xml.soap:saaj-api:jar:1.3.4:compile
[DEBUG]          org.glassfish:javax.annotation:jar:3.1.1:runtime
[DEBUG]       javax.servlet:servlet-api:jar:2.5:compile
[DEBUG]       org.springframework:spring-core:jar:4.1.6.RELEASE:compile (version managed from 3.2.3.RELEASE by PARENT POM AND VERSION)
[DEBUG]          commons-logging:commons-logging:jar:1.2:compile
[DEBUG]       org.springframework:spring-beans:jar:4.1.6.RELEASE:compile (version managed from 3.2.3.RELEASE by PARENT POM AND VERSION)
[DEBUG]       org.springframework:spring-context:jar:4.1.6.RELEASE:compile (version managed from 3.2.3.RELEASE by PARENT POM AND VERSION)
[DEBUG]          org.springframework:spring-aop:jar:4.1.6.RELEASE:compile
[DEBUG]             aopalliance:aopalliance:jar:1.0:compile
[DEBUG]          org.springframework:spring-expression:jar:4.1.6.RELEASE:compile
[DEBUG]       org.springframework:spring-web:jar:4.1.6.RELEASE:compile (version managed from 3.2.3.RELEASE by PARENT POM AND VERSION)
[DEBUG]       org.apache.xbean:xbean-spring:jar:3.14:compile
[DEBUG]       javax.jws:jsr181-api:jar:1.0-MR1:compile
[DEBUG]    com.sun.xml.ws:policy:jar:2.5:compile
[DEBUG]       javax.xml.stream:stax-api:jar:1.0-2:compile
[DEBUG]       com.sun.xml.txw2:txw2:jar:20110809:compile
[DEBUG]          relaxngDatatype:relaxngDatatype:jar:20020414:compile
[DEBUG]       com.sun.istack:istack-commons-runtime:jar:2.4:compile
[DEBUG]       org.codehaus.woodstox:woodstox-core-asl:jar:4.1.1:runtime
[DEBUG]          org.codehaus.woodstox:stax2-api:jar:3.1.1:runtime
[DEBUG]    org.glassfish.gmbal:gmbal-api-only:jar:3.2.0-b003:compile
[DEBUG]       org.glassfish.external:management-api:jar:3.0.0-b012:compile
[DEBUG]    org.springframework:spring-orm:jar:4.1.6.RELEASE:compile
[DEBUG]       org.springframework:spring-jdbc:jar:4.1.6.RELEASE:compile
[DEBUG]    org.springframework:spring-tx:jar:4.1.6.RELEASE:compile
[DEBUG]    com.sun.xml.bind:jaxb-impl:jar:2.2.6-facets-1.3.1:compile
[DEBUG]       com.sun.xml.ws:jaxws-tools:jar:2.2.6:compile
[DEBUG]          com.sun.xml.ws:jaxws-rt:jar:2.2.8:compile (version managed from 2.2.6 by PARENT POM AND VERSION)
[DEBUG]             javax.xml.soap:javax.xml.soap-api:jar:1.3.5:compile
[DEBUG]             javax.annotation:javax.annotation-api:jar:1.2-b03:compile
[DEBUG]             com.sun.xml.bind:jaxb-core:jar:2.2.7:compile
[DEBUG]             org.jvnet.mimepull:mimepull:jar:1.9.1:compile
[DEBUG]             com.sun.xml.fastinfoset:FastInfoset:jar:1.2.12:compile
[DEBUG]             org.glassfish.ha:ha-api:jar:3.1.9:compile
[DEBUG]             com.sun.xml.messaging.saaj:saaj-impl:jar:1.3.20:compile
[DEBUG]             com.sun.org.apache.xml.internal:resolver:jar:20050927:compile
[DEBUG]          com.sun.xml.bind:jaxb-xjc:jar:2.2.5:compile
[DEBUG]       net.java.loci:jsr308-all:jar:1.1.2:compile
[DEBUG]       javax.validation:validation-api:jar:1.1.0.Final:compile
[DEBUG]    oracle:ojdbc6:jar:11.2.0.4.0:provided
[DEBUG]    org.eclipse.persistence:eclipselink:jar:2.5.1:provided
[DEBUG]       org.eclipse.persistence:javax.persistence:jar:2.1.0:provided
[DEBUG]       org.eclipse.persistence:commonj.sdo:jar:2.1.1:provided
[DEBUG]    com.sun.xml.stream.buffer:streambuffer:jar:1.4:compile
[DEBUG]       org.jvnet.staxex:stax-ex:jar:1.6:compile
[DEBUG]       javax.activation:activation:jar:1.1:compile
[DEBUG]    commons-dbcp:commons-dbcp:jar:1.4:compile
[DEBUG]       commons-pool:commons-pool:jar:1.5.4:compile
[DEBUG]    org.apache.commons:commons-lang3:jar:3.3.2:compile
[DEBUG]    org.springframework:spring-test:jar:4.1.6.RELEASE:test
[DEBUG]    com.github.springtestdbunit:spring-test-dbunit:jar:1.2.1:test
[DEBUG]    org.dbunit:dbunit:jar:2.5.1:test
[DEBUG]       org.slf4j:slf4j-api:jar:1.7.12:test
[DEBUG]       commons-collections:commons-collections:jar:3.2.1:test
[DEBUG]       org.apache.poi:poi-ooxml:jar:3.11:test
[DEBUG]          org.apache.poi:poi:jar:3.11:test
[DEBUG]             commons-codec:commons-codec:jar:1.9:test
[DEBUG]          org.apache.poi:poi-ooxml-schemas:jar:3.11:test
[DEBUG]             org.apache.xmlbeans:xmlbeans:jar:2.6.0:test
[DEBUG]                stax:stax-api:jar:1.0.1:test
[DEBUG]    junit:junit:jar:4.12:test
[DEBUG]       org.hamcrest:hamcrest-core:jar:1.3:test
[DEBUG]    pl.pragmatists:JUnitParams:jar:1.0.4:test
[DEBUG]    org.mockito:mockito-all:jar:1.10.19:test
[DEBUG]    org.reflections:reflections:jar:0.9.9:compile
[DEBUG]       com.google.guava:guava:jar:15.0:compile
[DEBUG]       org.javassist:javassist:jar:3.18.2-GA:compile
[DEBUG]       com.google.code.findbugs:annotations:jar:2.0.1:compile
[DEBUG]   CUSTOM DEPENDENCY OF ARTIFACT:compile
[DEBUG]       log4j:log4j:jar:1.2.16:compile
[DEBUG]       org.aspectj:aspectjrt:jar:1.8.5:compile
[DEBUG]       org.aspectj:aspectjweaver:jar:1.8.5:compile
[DEBUG]      CUSTOM DEPENDENCY OF ARTIFACT:compile
[DEBUG]         CUSTOM DEPENDENCY OF ARTIFACT:compile
[DEBUG]          CUSTOM DEPENDENCY OF ARTIFACT:compile
[INFO] 
[INFO] --- maven-javadoc-plugin:2.10.1:javadoc (default-cli) @ ARTITFACT ID---
 [DEBUG] Configuring mojo org.apache.maven.plugins:maven-javadoc-plugin:2.10.1:javadoc from plugin realm ClassRealm[plugin>org.apache.maven.plugins:maven-javadoc-plugin:2.10.1, parent: sun.misc.Launcher$AppClassLoader@4e25154f]
[DEBUG] Configuring mojo 'org.apache.maven.plugins:maven-javadoc-plugin:2.10.1:javadoc' with basic configurator -->
[DEBUG]   (f) additionalparam = -Xdoclint:none
[DEBUG]   (f) doclet = CUSTOM DOCLECT
[DEBUG]   (f) docletArtifact = groupId = 'null'
artifactId = 'null'
version = 'null'
[DEBUG]   (s) groupId = GROUP OF CUSTOM DOCLET
[DEBUG]   (s) artifactId = ARTIFACT ID OF CUSTOM DOCLET
[DEBUG]   (s) version = VERSION OF CUSTOM DOCLET
[DEBUG]   (f) docletArtifacts = [groupId = 'GROUP OF CUSTOM DOCLET'
artifactId = 'ARTIFACT ID OF CUSTOM DOCLET'
version = 'VERSION OF CUSTOM DOCLET']
[DEBUG]   (f) doctitle = ARTIFACT ID AND VERSION
[DEBUG]   (f) javadocDirectory = PATH TO ARTIFACT\src\main\javadoc
[DEBUG]   (f) javadocOptionsDir = PATH TO ARTIFACT\target\javadoc-bundle-options
[DEBUG]   (f) localRepository =       id: local
      url: file:///PATH TO LOCAL REPOSITORY
   layout: default
snapshots: [enabled => true, update => always]
 releases: [enabled => true, update => always]
[DEBUG]   (f) project = MavenProject: ARTIFACT AND VERSION @ PATH TO ARTIFACT\pom.xml
[DEBUG]   (f) reactorProjects = [MavenProject: ARTIFACT AND VERSION @ PATH TO ARTIFACT\pom.xml]
[DEBUG]   (f) remoteRepositories = [      id: central
      url: PATH TO CUSTOM LIBS RELEASE REPOSITORY
   layout: default
snapshots: [enabled => false, update => daily]
 releases: [enabled => true, update => daily]
,       id: snapshots
      url: PATH TO CUSTOM LIBS SNAPSHOT REPOSITORY
   layout: default
snapshots: [enabled => true, update => daily]
 releases: [enabled => true, update => daily]
]
[DEBUG]   (s) reportOutputDirectory = PATH TO ARTIFACT\target\site\apidocs
[DEBUG]   (f) sourceDependencyCacheDir = PATH TO ARTIFACT\target\distro-javadoc-sources
[DEBUG]   (f) windowtitle = ARTIFACT AND VERSION
[DEBUG] -- end configuration --
[DEBUG] Could not find metadata CUSTOM DOCLET AND VERSION/maven-metadata.xml in local (PATH TO LOCAL REPOSITORY)
[DEBUG] Using transporter WagonTransporter with priority -1.0 for PATH TO CUSTOM LIBS RELEASE REPOSITORY
[DEBUG] Using connector BasicRepositoryConnector with priority 0.0 for PATH TO CUSTOM LIBS RELEASE REPOSITORY
[INFO] Downloading: PATH TO CUSTOM LIBS RELEASE REPOSITORY/PATH TO CUSTOM DOCLET/maven-metadata.xml
[INFO] Downloaded: PATH TO CUSTOM LIBS RELEASE REPOSITORY/PATH TO CUSTOM DOCLET/maven-metadata.xml (770 B at 1.0 KB/sec)
[DEBUG] Writing tracking file PATH TO LOCAL REPOSITORY\PATH TO CUSTOM DOCLET\resolver-status.properties
[DEBUG] Using transporter WagonTransporter with priority -1.0 for PATH TO CUSTOM LIBS RELEASE REPOSITORY
[DEBUG] Using connector BasicRepositoryConnector with priority 0.0 for PATH TO CUSTOM LIBS RELEASE REPOSITORY
[INFO] Downloading: PATH TO CUSTOM LIBS RELEASE REPOSITORY/PATH TO CUSTOM DOCLET.pom
[INFO] Downloaded: PATH TO CUSTOM LIBS RELEASE REPOSITORY/PATH TO CUSTOM DOCLET.pom (3 KB at 88.8 KB/sec)
[DEBUG] Writing tracking file PATH TO LOCAL REPOSITORY\PATH TO CUSTOM DOCLET\_remote.repositories
[DEBUG] Writing tracking file PATH TO LOCAL REPOSITORY\PATH TO CUSTOM DOCLET.pom.lastUpdated
[DEBUG] Could not find metadata CUSTOM DOCLET ARTIFACT AND VERSION/maven-metadata.xml in local (PATH TO LOCAL REPOSITORY)
[DEBUG] Skipped remote request for CUSTOM DOCLET ARTIFACT AND VERSION/maven-metadata.xml, already updated during this session.
[DEBUG] Using transporter WagonTransporter with priority -1.0 for PATH TO CUSTOM LIBS RELEASE REPOSITORY
[DEBUG] Using connector BasicRepositoryConnector with priority 0.0 for PATH TO CUSTOM LIBS RELEASE REPOSITORY
[INFO] Downloading: PATH TO CUSTOM LIBS RELEASE REPOSITORY/PATH TO CUSTOM DOCLET.jar
[INFO] Downloaded: PATH TO CUSTOM LIBS RELEASE REPOSITORY/PATH TO CUSTOM DOCLET.jar (47 KB at 1512.5 KB/sec)
[DEBUG] Writing tracking file PATH TO LOCAL REPOSITORY\PATH TO CUSTOM DOCLET\_remote.repositories
[DEBUG] Writing tracking file PATH TO LOCAL REPOSITORY\PATH TO CUSTOM DOCLET.jar.lastUpdated
[DEBUG] CUSTOM DOCLET ARTIFACT AND VERSION (selected for null)
[DEBUG]   jdk.tools:jdk.tools:jar:1.8.0_51:system (selected for system)
[DEBUG]   org.apache.commons:commons-lang3:jar:3.3.2:compile (selected for compile)
[DEBUG]   javax.xml.bind:jaxb-api:jar:2.2.7-facets-1.0.5:compile (selected for compile)
[DEBUG]     javax.xml.bind:jaxb-api:jar:2.2.7:compile (removed - nearer found: 2.2.7-facets-1.0.5)
[DEBUG] Using transporter WagonTransporter with priority -1.0 for https://repo.maven.apache.org/maven2 <b><-- ???</b>
[DEBUG] Using connector BasicRepositoryConnector with priority 0.0 for https://repo.maven.apache.org/maven2 <br><--- ???</b>
[INFO] Downloading: https://repo.maven.apache.org/maven2/com/bitplan/mediawiki-japi/0.0.4/mediawiki-japi-0.0.4.pom
[DEBUG] Writing tracking file PATH TO LOCAL REPOSITORY\com\bitplan\mediawiki-japi\0.0.4\mediawiki-japi-0.0.4.pom.lastUpdated
[DEBUG] Using transporter WagonTransporter with priority -1.0 for PATH TO CUSTOM LIBS SNAPSHOT REPOSITORY
[DEBUG] Using connector BasicRepositoryConnector with priority 0.0 for PATH TO CUSTOM LIBS SNAPSHOT REPOSITORY
[INFO] Downloading: PATH TO CUSTOM LIBS SNAPSHOT REPOSITORY/com/bitplan/mediawiki-japi/0.0.4/mediawiki-japi-0.0.4.pom
[DEBUG] Writing tracking file PATH TO LOCAL REPOSITORY\com\bitplan\mediawiki-japi\0.0.4\mediawiki-japi-0.0.4.pom.lastUpdated
[DEBUG]   com.google.code.gson:gson:jar:2.3.1:compile (selected for compile)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 26.242 s
[INFO] Finished at: 2016-01-28T08:29:00+01:00
[INFO] Final Memory: 22M/218M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-javadoc-plugin:2.10.1:javadoc (default-cli) on project ARTIFACT ID: An error has occurred in JavaDocs report generation: Unable to resolve artifact:groupId = 'GROUP OF CUSTOM DOCLET'
[ERROR] artifactId = 'ARTIFACT OF CUSTOM DOCLET'
[ERROR] version = 'VERSION OF CUSTOM DOCLET': Unable to get dependency information for com.bitplan:mediawiki-japi:jar:0.0.4: Failed to retrieve POM for com.bitplan:mediawiki-japi:jar:0.0.4: Could not transfer artifact com.bitplan:mediawiki-japi:pom:0.0.4 from/to central (https://repo.maven.apache.org/maven2): Connect to repo.maven.apache.org:443 [repo.maven.apache.org/185.31.17.215] failed: Connection timed out: connect
[ERROR] com.bitplan:mediawiki-japi:jar:0.0.4
[ERROR] 
[ERROR] from the specified remote repositories:
[ERROR] central (https://repo.maven.apache.org/maven2, releases=true, snapshots=false),
[ERROR] snapshots (PATH TO CUSTOM LIBS SNAPSHOT REPOSITORY, releases=true, snapshots=true)
[ERROR] Path to dependency:
[ERROR] 1) CUSTOM DOCLET ARTIFACT AND VERSION
[ERROR] -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-javadoc-plugin:2.10.1:javadoc (default-cli) on project ARTIFACT ID: An error has occurred in JavaDocs report generation: Unable to resolve artifact:groupId = 'GROUP OF CUSTOM DOCLET'
artifactId = 'ARTIFACT ID OF CUSTOM DOCLET'
version = 'VERSION OF CUSTOM DOCLET'
Caused by: org.apache.maven.plugin.MojoExecutionException: An error has occurred in JavaDocs report generation: Unable to resolve artifact:groupId = 'GROUP OF CUSTOM DOCLET'
artifactId = 'ARTIFACT ID OF CUSTOM DOCLET'
version = 'VERSION OF CUSTOM DOCLET'
Caused by: org.apache.maven.reporting.MavenReportException: Unable to resolve artifact:groupId = 'GROUP OF CUSTOM DOCLET'
artifactId = 'ARTIFACT ID OF CUSTOM DOCLET'
version = 'VERSION OF CUSTOM DOCLET'
Caused by: org.apache.maven.artifact.resolver.ArtifactResolutionException: Unable to get dependency information for com.bitplan:mediawiki-japi:jar:0.0.4: Failed to retrieve POM for com.bitplan:mediawiki-japi:jar:0.0.4: Could not transfer artifact com.bitplan:mediawiki-japi:pom:0.0.4 from/to central (https://repo.maven.apache.org/maven2): Connect to repo.maven.apache.org:443 [repo.maven.apache.org/185.31.17.215] failed: Connection timed out: connect
  com.bitplan:mediawiki-japi:jar:0.0.4
from the specified remote repositories:
  central (https://repo.maven.apache.org/maven2, releases=true, snapshots=false),
  snapshots (PATH TO CUSTOM LIBS SNAPSHOT REPOSITORY, releases=true, snapshots=true)
Path to dependency: 
    1) CUSTOM DOCLET ARTIFACT AND VERSION
我希望有人能帮我解决这个问题


关于可能的故障排除路径:

Maven设置(最新更新/编辑后,此设置已被选中)

为自定义Maven存储库提供配置的
settings.xml
文件可能仅在其
repositories
部分(用于依赖项中介的存储库)中指向它,而不在
pluginRepositories
部分(用于插件/报告中介和插件依赖项中介的存储库)

pluginRepositories
中,应指定:

用于发现插件的远程存储库的列表

如果没有这个额外的配置,Maven将尝试解析插件对插件的默认存储库的依赖关系,该存储库来自。看看它,插件的默认存储库实际上就是您的构建所指向的(
https://repo.maven.apache.org/maven2
):

目标将作为构建输出的一部分打印整个合并的pom和使用的设置。从中,您应该能够看到构建有效地使用了哪些
pluginRepositories

注意:
-Doutput
参数有助于将其重定向到外部文件


人工配置

如果不是这样(因此,配置是一致的,并且在两个部分中都指向您的自定义Maven存储库),您应该检查自定义存储库是否配置良好:

  • Artifactory附带了库、插件和快照的默认存储库
  • 可以将Artifactory配置为使用虚拟存储库来聚合后面的几个真实存储库
  • 您的自定义库可能已上载到lib存储库,而该存储库不包含在提供插件依赖项的虚拟存储库中
从您提供的输出代码段:

[DEBUG] Repositories (dependencies): [central (PATH TO CUSTOM LIBS RELEASE REPOSITORY, default, releases), snapshots (PATH TO CUSTOM LIBS SNAPSHOT REPOSITORY, default, releases+snapshots)]
[DEBUG] Repositories (plugins)     : [central (PATH TO CUSTOM PLUGIN RELEASE REPOSITORY, default, releases), snapshots (PATH TO CUSTOM PLUGIN SNAPSHOT REPOSITORY, default, releases+snapshots)]
事实上可能是这样

这是一个常见的错误配置(我过去也碰到过这堵墙)。实际上,在大多数情况下,插件依赖项甚至不需要不同的存储库,只有一个用于已发布库的虚拟存储库和一个用于快照库的虚拟存储库会更容易、更清晰,这两个库都提供依赖项和插件人工制品。因此,仅区分已发布和快照,而不是een依赖项和插件(或者,如果您确实想保持当前配置,可以将libs存储库添加为虚拟插件存储库的一部分)

一个简单且无害的测试是:

  • 在Artifactory中配置新的虚拟存储库
  • 新的虚拟存储库将包括libs和plugins存储库
  • 在Maven设置中配置新的虚拟存储库(在两个存储库部分中)
  • 再次运行Maven构建

使用插件依赖项(在您最近的评论之后:宾果!,这解决了问题)

您应该将所需的依赖项添加为插件依赖项,如下所示:

<plugin>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-javadoc-plugin</artifactId>
    <version>2.10.1</version>
    <configuration>
        <show>public</show>
        <excludePackageNames>*.ws.jaxws.*</excludePackageNames>
        <additionalparam>-Xdoclint:none</additionalparam>
    </configuration>
    <executions>
        <execution>
            <id>default-cli</id>
            <goals>
                <goal>javadoc</goal>
            </goals>
            <configuration>
                <docletArtifacts>
                    <docletArtifact>
                        <groupId>GROUP ID OF CUSTOM DOCLET</groupId>
                        <artifactId>ARTIFACT ID OF CUSTOM DOCLET</artifactId>
                        <version>VERSION OF CUSTOM DOCLET</version>
                    </docletArtifact>
                </docletArtifacts>
                <doclet>PACKAGE AND CLASS OF CUSTOM DOCLET</doclet>
            </configuration>
        </execution>
    </executions>
    <dependencies>
        <dependency>
            <groupId>GROUP ID OF CUSTOM DOCLET</groupId>
            <artifactId>ARTIFACT ID OF CUSTOM DOCLET</artifactId>
            <version>VERSION OF CUSTOM DOCLET</version>
        </dependency>
    </dependencies>
</plugin>
<plugin>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-javadoc-plugin</artifactId>
    <version>2.10.1</version>
    <configuration>
        <show>public</show>
        <excludePackageNames>*.ws.jaxws.*</excludePackageNames>
        <additionalparam>-Xdoclint:none</additionalparam>
    </configuration>
    <executions>
        <execution>
            <id>default-cli</id>
            <goals>
                <goal>javadoc</goal>
            </goals>
            <configuration>
                <docletArtifacts>
                    <docletArtifact>
                        <groupId>GROUP ID OF CUSTOM DOCLET</groupId>
                        <artifactId>ARTIFACT ID OF CUSTOM DOCLET</artifactId>
                        <version>VERSION OF CUSTOM DOCLET</version>
                    </docletArtifact>
                </docletArtifacts>
                <doclet>PACKAGE AND CLASS OF CUSTOM DOCLET</doclet>
                <docletPath>path_to_jar/fileName.jar</docletPath>
            </configuration>
        </execution>
    </executions>
</plugin>
自:

扩展是要在此构建中使用的工件的列表。它们将包含在正在运行的构建的类路径中

  • 设置插件的依赖项(如上所述)应同时应用于插件和报告机制

    有一种方法可以在报表中实现这一点。在下面的示例中,我从插件块中删除了执行,并将插件添加为报表。在报表中使用插件时,似乎继承了依赖关系

    也记录了类似的方法

  • 编辑(2016年2月3日)(在您最近的评论之后:宾果!,使用构建扩展修复了该问题)


    使用docletPath配置元素

    查看Maven Javadoc插件,配置元素
    docletPath
    应该提供外部文件的路径(依赖项),该路径与官方
    Javadoc
    命令的预期选项一致

    查看官方文档,路径方法优先于Maven依赖方法。因此,您的配置可以进行如下调整:

    <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
        <version>2.10.1</version>
        <configuration>
            <show>public</show>
            <excludePackageNames>*.ws.jaxws.*</excludePackageNames>
            <additionalparam>-Xdoclint:none</additionalparam>
        </configuration>
        <executions>
            <execution>
                <id>default-cli</id>
                <goals>
                    <goal>javadoc</goal>
                </goals>
                <configuration>
                    <docletArtifacts>
                        <docletArtifact>
                            <groupId>GROUP ID OF CUSTOM DOCLET</groupId>
                            <artifactId>ARTIFACT ID OF CUSTOM DOCLET</artifactId>
                            <version>VERSION OF CUSTOM DOCLET</version>
                        </docletArtifact>
                    </docletArtifacts>
                    <doclet>PACKAGE AND CLASS OF CUSTOM DOCLET</doclet>
                </configuration>
            </execution>
        </executions>
        <dependencies>
            <dependency>
                <groupId>GROUP ID OF CUSTOM DOCLET</groupId>
                <artifactId>ARTIFACT ID OF CUSTOM DOCLET</artifactId>
                <version>VERSION OF CUSTOM DOCLET</version>
            </dependency>
        </dependencies>
    </plugin>
    
    <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
        <version>2.10.1</version>
        <configuration>
            <show>public</show>
            <excludePackageNames>*.ws.jaxws.*</excludePackageNames>
            <additionalparam>-Xdoclint:none</additionalparam>
        </configuration>
        <executions>
            <execution>
                <id>default-cli</id>
                <goals>
                    <goal>javadoc</goal>
                </goals>
                <configuration>
                    <docletArtifacts>
                        <docletArtifact>
                            <groupId>GROUP ID OF CUSTOM DOCLET</groupId>
                            <artifactId>ARTIFACT ID OF CUSTOM DOCLET</artifactId>
                            <version>VERSION OF CUSTOM DOCLET</version>
                        </docletArtifact>
                    </docletArtifacts>
                    <doclet>PACKAGE AND CLASS OF CUSTOM DOCLET</doclet>
                    <docletPath>path_to_jar/fileName.jar</docletPath>
                </configuration>
            </execution>
        </executions>
    </plugin>
    
    
    org.apache.maven.plugins
    
    还展示了如何使用它:我尝试了它,在我们公司内部的Artifactory上配置了依赖项,并且没有指定任何jar的路径,并且成功地解决了额外的依赖项,因此-再次-我还将检查Artifactory的配置,以及您的自定义doclet库是否可以从插件库访问y、

    Hi,哪一个?来自doclet还是来自工件/具有配置的父pom
    <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
        <version>2.10.1</version>
        <configuration>
            <show>public</show>
            <excludePackageNames>*.ws.jaxws.*</excludePackageNames>
            <additionalparam>-Xdoclint:none</additionalparam>
        </configuration>
        <executions>
            <execution>
                <id>default-cli</id>
                <goals>
                    <goal>javadoc</goal>
                </goals>
                <configuration>
                    <docletArtifacts>
                        <docletArtifact>
                            <groupId>GROUP ID OF CUSTOM DOCLET</groupId>
                            <artifactId>ARTIFACT ID OF CUSTOM DOCLET</artifactId>
                            <version>VERSION OF CUSTOM DOCLET</version>
                        </docletArtifact>
                    </docletArtifacts>
                    <doclet>PACKAGE AND CLASS OF CUSTOM DOCLET</doclet>
                </configuration>
            </execution>
        </executions>
        <dependencies>
            <dependency>
                <groupId>GROUP ID OF CUSTOM DOCLET</groupId>
                <artifactId>ARTIFACT ID OF CUSTOM DOCLET</artifactId>
                <version>VERSION OF CUSTOM DOCLET</version>
            </dependency>
        </dependencies>
    </plugin>
    
    <build>
       <extensions>
           <extension>
               <groupId>GROUP ID OF CUSTOM DOCLET</groupId>
               <artifactId>ARTIFACT ID OF CUSTOM DOCLET</artifactId>
               <version>VERSION OF CUSTOM DOCLET</version>
           </extension>
       </extensions>
    </build>
    
    <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
        <version>2.10.1</version>
        <configuration>
            <show>public</show>
            <excludePackageNames>*.ws.jaxws.*</excludePackageNames>
            <additionalparam>-Xdoclint:none</additionalparam>
        </configuration>
        <executions>
            <execution>
                <id>default-cli</id>
                <goals>
                    <goal>javadoc</goal>
                </goals>
                <configuration>
                    <docletArtifacts>
                        <docletArtifact>
                            <groupId>GROUP ID OF CUSTOM DOCLET</groupId>
                            <artifactId>ARTIFACT ID OF CUSTOM DOCLET</artifactId>
                            <version>VERSION OF CUSTOM DOCLET</version>
                        </docletArtifact>
                    </docletArtifacts>
                    <doclet>PACKAGE AND CLASS OF CUSTOM DOCLET</doclet>
                    <docletPath>path_to_jar/fileName.jar</docletPath>
                </configuration>
            </execution>
        </executions>
    </plugin>