![](/img/trans.png)
[英]How to build nifi processor nar file and dependencies from maven central
[英]Trouble with ehcache dependencies from Maven Central
我正在嘗試在具有空.m2 /存儲庫目錄的新筆記本電腦上構建項目。 我收到以下錯誤:
BUILD FAILED
/home/awills/Dropbox/Jasig/portal/uPortal/build.xml:635: The following error occurred while executing this line:
/home/awills/Dropbox/Jasig/portal/uPortal/build.xml:1437: The following error occurred while executing this line:
/home/awills/Dropbox/Jasig/portal/uPortal/build.xml:1372: The following error occurred while executing this line:
/home/awills/Dropbox/Jasig/portal/uPortal/build.xml:1315: The following error occurred while executing this line:
/home/awills/Dropbox/Jasig/portal/uPortal/build.xml:1318: The following error occurred while executing this line:
/home/awills/Dropbox/Jasig/portal/uPortal/build.xml:1375: The following error occurred while executing this line:
/home/awills/Dropbox/Jasig/portal/uPortal/build.xml:1227: Unable to resolve artifact: Unable to get dependency information: Unable to read the metadata file for artifact 'net.sf.ehcache:ehcache-web:jar': Cannot find parent: net.sf.ehcache:ehcache-web-parent for project: null:ehcache-web:jar:null for project null:ehcache-web:jar:null
net.sf.ehcache:ehcache-web:jar:2.0.4
from the specified remote repositories:
central (http://repo1.maven.org/maven2),
sonatype-nexus-snapshots (https://oss.sonatype.org/content/repositories/snapshots),
apache-snapshots (http://repository.apache.org/snapshots)
Path to dependency:
1) org.jasig.portal:uportal-war:war:4.1.0-SNAPSHOT
2) org.jasig.resourceserver:resource-server-utils:jar:1.0.38
該項目已經成熟,並且這種依賴關系最近沒有改變。 該構建最近正在運行。
我不了解有關for project: null:ehcache-web:jar:null
它在哪里獲取null?
net.sf.ehcache:ehcache-web:2.0.4 pom開始如下...
<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/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>net.sf.ehcache</groupId>
<artifactId>ehcache-web-parent</artifactId>
<version>2.0.4</version>
</parent>
<name>Ehcache Web Filters</name>
<artifactId>ehcache-web</artifactId>
<packaging>jar</packaging>
<description><![CDATA[Web caching filters.]]> </description>
<licenses>
<license>
<name>The Apache Software License, Version 2.0</name>
<url>http://ehcache.org/license.html</url>
</license>
</licenses>
net.sf.ehcache:ehcache-web-parent:2.0.4 pom開始如下...
<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/maven-v4_0_0.xsd">
<properties>
<forgeTags>Integration Module</forgeTags>
<Bundle-RequiredExecutionEnvironment>J2SE-1.5</Bundle-RequiredExecutionEnvironment>
</properties>
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>net.sf.ehcache</groupId>
<artifactId>ehcache-parent</artifactId>
<version>2.3</version>
</parent>
<name>Ehcache Web Filters Parent</name>
<artifactId>ehcache-web-parent</artifactId>
<packaging>pom</packaging>
<version>2.0.4</version>
<description>parent pom for web module</description>
似乎有一個父pom,並且在子pom中定義了存儲庫(在這種情況下為ehcache-web),maven嘗試僅從子pom中定義的存儲庫中查找父依賴項。精通中央。
在ehcache-web pom中,您有以下內容:
<repositories>
<repository>
<id>sourceforge-snapshots</id>
<name>Sourceforge Snapshot Repository</name>
<url>http://oss.sonatype.org/content/repositories/sourceforge-snapshots</url>
</repository>
</repositories>
但是由於父級不再是快照,並且已被移至Maven中央,因此找不到該父級。 我通過從本地pom文件(〜/ .m2 / repository / net / sf / ehcache / ehcache-ehcache-web / 2.0.4 / ehcache-web-2.0.4.pom)中刪除存儲庫元素來解決此問題。
我還必須刪除存儲的ehcache-web-parent pom文件,該文件只是重定向。
我在網上發現了很少的有關此信息的信息,但也許這些信息對您有所幫助: https : //issues.sonatype.org/browse/MVNCENTRAL-468 http://jira.codehaus.org/browse/MANTTASKS-246
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.