安装CAS服务器:缺少必需的类:org/apache/maven/surefire/util/NestedCheckedException
我不熟悉Tomcat,但我遵循了一个教程。在我发布maven clean包之前,一切都运行良好。 输出显示以下错误:安装CAS服务器:缺少必需的类:org/apache/maven/surefire/util/NestedCheckedException,maven,cas,maven-surefire-plugin,Maven,Cas,Maven Surefire Plugin,我不熟悉Tomcat,但我遵循了一个教程。在我发布maven clean包之前,一切都运行良好。 输出显示以下错误: [INFO] Internal error in the plugin manager executing goal 'org.apache.maven.plugins:maven-surefire-plugin:2.10:test': Unable to load the mojo 'org.apache.maven.plugins:maven-surefire-plugin:
[INFO] Internal error in the plugin manager executing goal 'org.apache.maven.plugins:maven-surefire-plugin:2.10:test': Unable to load the mojo 'org.apache.maven.plugins:maven-surefire-plugin:2.10:test' in the plugin 'org.apache.maven.plugins:maven-surefire-plugin'. A required class is missing: org/apache/maven/surefire/util/NestedRuntimeException
org.apache.maven.surefire.util.NestedRuntimeException
我在网上查过了,这个错误似乎很常见,但没有一个方法有效:我有rm-Rf the.m2/repository/org/
我的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/xsd/maven-4.0.0.xsd ">
<modelVersion>4.0.0</modelVersion>
<groupId>sso.mydomain.com</groupId>
<artifactId>local-cas</artifactId>
<packaging>war</packaging>
<version>1.0-SNAPSHOT</version>
<build>
<plugins>
<plugin>
<artifactId>maven-war-plugin</artifactId>
<configuration>
<warName>cas</warName>
</configuration>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>org.jasig.cas</groupId>
<artifactId>cas-server-webapp</artifactId>
<version>${cas.version}</version>
<type>war</type>
<scope>runtime</scope>
</dependency>
</dependencies>
<properties>
<cas.version>3.5.2</cas.version>
</properties>
<repositories>
<repository>
<id>ja-sig</id>
<url>http://oss.sonatype.org/content/repositories/releases/ </url>
</repository>
</repositories>
4.0.0
sso.mydomain.com
本地cas
战争
1.0-快照
maven战争插件
中科院
org.jasig.cas
cas服务器webapp
${cas.version}
战争
运行时
3.5.2
ja信号
http://oss.sonatype.org/content/repositories/releases/
我的配置:ubuntu,maven 2.2.1
我在这上面花了一个小时。有什么想法吗?我还试图通过将它添加到我的pom.xml:org.apache.maven.plugins-maven-surefire-plugin 2.4.2-methods 10中来强制更新surefire版本,但没有成功。但是这个版本是加载的。在使用Maven 2时,我遇到了同样的问题。使用Maven3,问题就消失了。Ubuntu有两个包,Maven(最新版本)和Maven2(最新版本2.x)。您可以尝试卸载
maven2
并使用apt-get
安装maven
包。我还尝试通过将其添加到pom.xml:org.apache.maven.plugins-maven-surefire-plugin 2.4.2-methods 10中来强制更新版本的surefire,但没有成功。但是这个版本是加载的。在使用Maven 2时,我遇到了同样的问题。使用Maven3,问题就消失了。Ubuntu有两个包,Maven(最新版本)和Maven2(最新版本2.x)。您可以尝试卸载maven2
并使用apt-get