eclipse中创建Maven项目时
pom.xml报错:com.thoughtworks.xstream.io.HierarchicalStreamDriver。
解决方案如下:
1 在pom文件中加入maven-war-plugin
<build> <finalName>myWeb</finalName> <plugins> <plugin> <artifactId>maven-eclipse-plugin</artifactId> <configuration> <downloadSources>true</downloadSources> <downloadJavadocs>true</downloadJavadocs> </configuration> </plugin> </plugins> </build>
2 在pom中配置依赖
<dependency> <groupId>com.thoughtworks.xstream</groupId> <artifactId>xstream</artifactId> <version>1.4.9</version> </dependency>