我正在尝试从现有的Eclipse中的Maven项目构建一个捆绑包。虽然我已经有了大多数仓库依赖项,但它仍然尝试下载一些依赖项。之后它会给出下面的错误列表。有人能告诉我如何消除现有的错误并成功构建捆绑包吗?我正在为Adobe Aem aq5工具构建捆绑包,它接受jar文件作为要安装的捆绑包。
[ERROR] Unresolveable build extension: Plugin org.apache.felix:maven-bundle-plug
in:2.3.7 or one of its dependencies could not be resolved: The following artifac
ts could not be resolved: org.apache.maven:maven-core:jar:2.0.7, org.apache.mave
n:maven-settings:jar:2.0.7, org.apache.maven:maven-plugin-parameter-documenter:j
ar:2.0.7, org.apache.maven:maven-profile:jar:2.0.7, org.apache.maven:maven-model
:jar:2.0.7, org.apache.maven:maven-artifact:jar:2.0.7, org.codehaus.plexus:plexu
s-container-default:jar:1.0-alpha-9-stable-1, org.apache.maven:maven-repository-
metadata:jar:2.0.7, org.apache.maven:maven-error-diagnostics:jar:2.0.7, org.apac
he.maven:maven-project:jar:2.0.7, org.apache.maven:maven-plugin-registry:jar:2.0
.7, org.apache.maven:maven-plugin-descriptor:jar:2.0.7, org.apache.maven:maven-a
rtifact-manager:jar:2.0.7, org.apache.maven:maven-monitor:jar:2.0.7, classworlds
:classworlds:jar:1.1: Could not transfer artifact org.apache.maven:maven-core:ja
r:2.0.7 from/to adobe (http://repo.adobe.com/nexus/content/groups/public/): sun.
security.validator.ValidatorException: PKIX path building failed: sun.security.p
rovider.certpath.SunCertPathBuilderException: unable to find valid certification
path to requested target @
[ERROR] Unknown packaging: bundle @ com.lundbeck.master.nohmatters:nohmatters-bu
ndle:[unknown-version], D:\CODEBASE\nohmatters\bundle\pom.xml, line 19, column 1
6
@
[ERROR] The build could not read 1 project -> [Help 1]
[ERROR]
[ERROR] The project com.lundbeck.master.nohmatters:nohmatters-bundle:1.0.0-SNA
PSHOT (D:\CODEBASE\nohmatters\bundle\pom.xml) has 2 errors
[ERROR] Unresolveable build extension: Plugin org.apache.felix:maven-bundle-
plugin:2.3.7 or one of its dependencies could not be resolved: The following art
ifacts could not be resolved: org.apache.maven:maven-core:jar:2.0.7, org.apache.
maven:maven-settings:jar:2.0.7, org.apache.maven:maven-plugin-parameter-document
er:jar:2.0.7, org.apache.maven:maven-profile:jar:2.0.7, org.apache.maven:maven-m
odel:jar:2.0.7, org.apache.maven:maven-artifact:jar:2.0.7, org.codehaus.plexus:p
lexus-container-default:jar:1.0-alpha-9-stable-1, org.apache.maven:maven-reposit
ory-metadata:jar:2.0.7, org.apache.maven:maven-error-diagnostics:jar:2.0.7, org.
apache.maven:maven-project:jar:2.0.7, org.apache.maven:maven-plugin-registry:jar
:2.0.7, org.apache.maven:maven-plugin-descriptor:jar:2.0.7, org.apache.maven:mav
en-artifact-manager:jar:2.0.7, org.apache.maven:maven-monitor:jar:2.0.7, classwo
rlds:classworlds:jar:1.1: Could not transfer artifact org.apache.maven:maven-cor
e:jar:2.0.7 from/to adobe (http://repo.adobe.com/nexus/content/groups/public/):
sun.security.validator.ValidatorException: PKIX path building failed: sun.securi
ty.provider.certpath.SunCertPathBuilderException: unable to find valid certifica
tion path to requested target -> [Help 2]
[ERROR] Unknown packaging: bundle @ com.lundbeck.master.nohmatters:nohmatter
s-bundle:[unknown-version], D:\CODEBASE\nohmatters\bundle\pom.xml, line 19, colu
mn 16
我这个pom.xml文件如下所示:
<?xml version="1.0" encoding="UTF-8"?>
<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>
<!-- ====================================================================== -->
<!-- P A R E N T P R O J E C T D E S C R I P T I O N -->
<!-- ====================================================================== -->
<parent>
<groupId>com.lundbeck.master.nohmatters</groupId>
<artifactId>nohmatters</artifactId>
<version>1.0.0-SNAPSHOT</version>
</parent>
<!-- ====================================================================== -->
<!-- P R O J E C T D E S C R I P T I O N -->
<!-- ====================================================================== -->
<artifactId>nohmatters-bundle</artifactId>
<packaging>bundle</packaging>
<name>nohmatters Bundle</name>
<dependencies>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.compendium</artifactId>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.core</artifactId>
</dependency>
<dependency>
<groupId>org.apache.felix</groupId>
<artifactId>org.apache.felix.scr.annotations</artifactId>
</dependency>
<dependency>
<groupId>biz.aQute</groupId>
<artifactId>bndlib</artifactId>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
</dependency>
<dependency>
<groupId>javax.jcr</groupId>
<artifactId>jcr</artifactId>
</dependency>
<dependency>
<groupId>org.apache.sling</groupId>
<artifactId>org.apache.sling.api</artifactId>
</dependency>
<dependency>
<groupId>org.apache.sling</groupId>
<artifactId>org.apache.sling.jcr.api</artifactId>
</dependency>
<dependency>
<groupId>com.day.cq.wcm</groupId>
<artifactId>cq-wcm-workflow-api</artifactId>
<version>5.3.0</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.day.cq.wcm</groupId>
<artifactId>cq-wcm-api</artifactId>
<version>5.5.0</version>
</dependency>
<dependency>
<groupId>com.day.cq</groupId>
<artifactId>cq-commons</artifactId>
<version>5.5.0</version>
</dependency>
<dependency>
<groupId>commons-lang</groupId>
<artifactId>commons-lang</artifactId>
<version>2.4</version>
</dependency>
<dependency>
<groupId>org.apache.sling</groupId>
<artifactId>org.apache.sling.commons.json</artifactId>
<version>2.0.6</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.day.cq</groupId>
<artifactId>cq-mailer</artifactId>
<version>5.5.0</version>
</dependency>
<dependency>
<groupId>com.day.cq</groupId>
<artifactId>cq-search</artifactId>
<version>5.5.4</version>
</dependency>
<dependency>
<groupId>com.adobe.granite</groupId>
<artifactId>com.adobe.granite.xssprotection</artifactId>
</dependency>
<dependency>
<groupId>org.apache.sling</groupId>
<artifactId>org.apache.sling.resourceresolver</artifactId>
</dependency>
<dependency>
<groupId>org.apache.sling</groupId>
<artifactId>org.apache.sling.api</artifactId>
<version>2.9.0</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.itextpdf</groupId>
<artifactId>itextpdf</artifactId>
<version>5.5.6</version>
</dependency>
<dependency>
<groupId>com.itextpdf.tool</groupId>
<artifactId>xmlworker</artifactId>
<version>5.5.6</version>
</dependency>
<dependency>
<groupId>com.jcraft</groupId>
<artifactId>jsch</artifactId>
<version>0.1.53</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>com.jcraft</groupId>
<artifactId>jzlib</artifactId>
<version>1.1.3</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-io</artifactId>
<version>1.3.2</version>
</dependency>
<dependency>
<groupId>com.google.code.gson</groupId>
<artifactId>gson</artifactId>
<version>2.3</version>
</dependency>
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>uber-jar</artifactId>
<version>6.1.0</version>
<classifier>obfuscated-apis</classifier>
<scope>provided</scope>
</dependency>
</dependencies>
<!-- ====================================================================== -->
<!-- B U I L D D E F I N I T I O N -->
<!-- ====================================================================== -->
<build>
<plugins>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-scr-plugin</artifactId>
<executions>
<execution>
<id>generate-scr-descriptor</id>
<goals>
<goal>scr</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<extensions>true</extensions>
<configuration>
<instructions>
<Bundle-SymbolicName>com.lundbeck.master.nohmatters.nohmatters-bundle</Bundle-SymbolicName>
<Import-Package>org.osgi.framework,*</Import-Package>
<Export-Package>com.lundbeck.master.nohmatters.*,com.lundbeck.master.nohmatters.servlet.EmailServlet,com.jcraft.*;com.jcraft.jzlib</Export-Package>
<Include-Resource>{maven-resources}</Include-Resource>
<Import-Bundle>*</Import-Bundle>
<Embed-Dependency>gson</Embed-Dependency>
<Embed-Transitive>true</Embed-Transitive>
<Private-Package>com.lundbeck.master.nohmatters.servlet.*,com.jcraft.*</Private-Package>
</instructions>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.sling</groupId>
<artifactId>maven-sling-plugin</artifactId>
<configuration>
<slingUrl>http://${crx.host}:${crx.port}/apps/nohmatters/install</slingUrl>
<usePut>true</usePut>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<configuration>
<excludePackageNames>
*.impl
</excludePackageNames>
</configuration>
</plugin>
</plugins>
</build>
</project>
<?xml version="1.0" encoding="UTF-8"?>
<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>
<!-- ====================================================================== -->
<!-- P A R E N T P R O J E C T D E S C R I P T I O N -->
<!-- ====================================================================== -->
<parent>
<groupId>com.lundbeck.master.nohmatters</groupId>
<artifactId>nohmatters</artifactId>
<version>1.0.0-SNAPSHOT</version>
</parent>
<!-- ====================================================================== -->
<!-- P R O J E C T D E S C R I P T I O N -->
<!-- ====================================================================== -->
<artifactId>nohmatters-bundle</artifactId>
<packaging>bundle</packaging>
<name>nohmatters Bundle</name>
<dependencies>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.compendium</artifactId>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.core</artifactId>
</dependency>
<dependency>
<groupId>org.apache.felix</groupId>
<artifactId>org.apache.felix.scr.annotations</artifactId>
</dependency>
<dependency>
<groupId>biz.aQute</groupId>
<artifactId>bndlib</artifactId>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>servlet-api</artifactId>
</dependency>
<dependency>
<groupId>javax.jcr</groupId>
<artifactId>jcr</artifactId>
</dependency>
<dependency>
<groupId>org.apache.sling</groupId>
<artifactId>org.apache.sling.api</artifactId>
</dependency>
<dependency>
<groupId>org.apache.sling</groupId>
<artifactId>org.apache.sling.jcr.api</artifactId>
</dependency>
<dependency>
<groupId>com.day.cq.wcm</groupId>
<artifactId>cq-wcm-workflow-api</artifactId>
<version>5.3.0</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.day.cq.wcm</groupId>
<artifactId>cq-wcm-api</artifactId>
<version>5.5.0</version>
</dependency>
<dependency>
<groupId>com.day.cq</groupId>
<artifactId>cq-commons</artifactId>
<version>5.5.0</version>
</dependency>
<dependency>
<groupId>commons-lang</groupId>
<artifactId>commons-lang</artifactId>
<version>2.4</version>
</dependency>
<dependency>
<groupId>org.apache.sling</groupId>
<artifactId>org.apache.sling.commons.json</artifactId>
<version>2.0.6</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.day.cq</groupId>
<artifactId>cq-mailer</artifactId>
<version>5.5.0</version>
</dependency>
<dependency>
<groupId>com.day.cq</groupId>
<artifactId>cq-search</artifactId>
<version>5.5.4</version>
</dependency>
<dependency>
<groupId>com.adobe.granite</groupId>
<artifactId>com.adobe.granite.xssprotection</artifactId>
</dependency>
<dependency>
<groupId>org.apache.sling</groupId>
<artifactId>org.apache.sling.resourceresolver</artifactId>
</dependency>
<dependency>
<groupId>org.apache.sling</groupId>
<artifactId>org.apache.sling.api</artifactId>
<version>2.9.0</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.itextpdf</groupId>
<artifactId>itextpdf</artifactId>
<version>5.5.6</version>
</dependency>
<dependency>
<groupId>com.itextpdf.tool</groupId>
<artifactId>xmlworker</artifactId>
<version>5.5.6</version>
</dependency>
<dependency>
<groupId>com.jcraft</groupId>
<artifactId>jsch</artifactId>
<version>0.1.53</version>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>com.jcraft</groupId>
<artifactId>jzlib</artifactId>
<version>1.1.3</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-io</artifactId>
<version>1.3.2</version>
</dependency>
<dependency>
<groupId>com.google.code.gson</groupId>
<artifactId>gson</artifactId>
<version>2.3</version>
</dependency>
<dependency>
<groupId>com.adobe.aem</groupId>
<artifactId>uber-jar</artifactId>
<version>6.1.0</version>
<classifier>obfuscated-apis</classifier>
<scope>provided</scope>
</dependency>
</dependencies>
<!-- ====================================================================== -->
<!-- B U I L D D E F I N I T I O N -->
<!-- ====================================================================== -->
<build>
<plugins>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-scr-plugin</artifactId>
<executions>
<execution>
<id>generate-scr-descriptor</id>
<goals>
<goal>scr</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-bundle-plugin</artifactId>
<extensions>true</extensions>
<configuration>
<instructions>
<Bundle-SymbolicName>com.lundbeck.master.nohmatters.nohmatters-bundle</Bundle-SymbolicName>
<Import-Package>org.osgi.framework,*</Import-Package>
<Export-Package>com.lundbeck.master.nohmatters.*,com.lundbeck.master.nohmatters.servlet.EmailServlet,com.jcraft.*;com.jcraft.jzlib</Export-Package>
<Include-Resource>{maven-resources}</Include-Resource>
<Import-Bundle>*</Import-Bundle>
<Embed-Dependency>gson</Embed-Dependency>
<Embed-Transitive>true</Embed-Transitive>
<Private-Package>com.lundbeck.master.nohmatters.servlet.*,com.jcraft.*</Private-Package>
</instructions>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.sling</groupId>
<artifactId>maven-sling-plugin</artifactId>
<configuration>
<slingUrl>http://${crx.host}:${crx.port}/apps/nohmatters/install</slingUrl>
<usePut>true</usePut>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<configuration>
<excludePackageNames>
*.impl
</excludePackageNames>
</configuration>
</plugin>
</plugins>
</build>
</project>