Eclipse STS报告我的春季项目有问题.
这是从Spring Web MVC项目模板(文件->新建-> Spring模板项目-> Spring Web MVC)生成的新项目.
当我创建项目时,它没有任何问题-只有在我修改pom(通过添加休眠依赖项)后,STS才会处理d簧问题.
奇怪的是,如果我还原pom,问题仍然存在.
我也可以在spring tc服务器上运行项目,并且一切正常.
有什么想法可以满足我的问题报告吗?
“Class
‘org.springframework.http.converter.ResourcehttpMessageConverter’
not found”mvc-config.xml /src/main/webapp/WEB-INF/spring line
9 Spring Beans Problem
mvc-config.xml:
<?xml version="1.0" enCoding="UTF-8"?><beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:mvc="http://www.springframework.org/schema/mvc" xsi:schemaLocation=" http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc-3.0.xsd"> <mvc:annotation-driven /> <!-- <= PROBLEMATIC liNE REPORTED BY STS --> <!-- Resolves vIEw names to protected .Jsp resources within the /WEB-INF/vIEws directory --> <bean > <property name="prefix" value="/WEB-INF/vIEws/"/> <property name="suffix" value=".Jsp"/> </bean></beans>
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> <groupID>net.rosteredon</groupID> <artifactID>spring23</artifactID> <name>test23</name> <packaging>war</packaging> <version>1.0.0-SNAPSHOT</version> <propertIEs> <org.springframework.version>3.0.1.RELEASE</org.springframework.version> <org.slf4j.version>1.5.10</org.slf4j.version> </propertIEs> <dependencIEs> <!-- Spring --> <dependency> <groupID>org.springframework</groupID> <artifactID>spring-context</artifactID> <version>${org.springframework.version}</version> <exclusions> <!-- Exclude Commons Logging in favor of SLF4j --> <exclusion> <groupID>commons-logging</groupID> <artifactID>commons-logging</artifactID> </exclusion> </exclusions> </dependency> <dependency> <groupID>org.springframework</groupID> <artifactID>spring-webmvc</artifactID> <version>${org.springframework.version}</version> </dependency> <!-- Logging --> <dependency> <groupID>org.slf4j</groupID> <artifactID>slf4j-api</artifactID> <version>${org.slf4j.version}</version> </dependency> <dependency> <groupID>org.slf4j</groupID> <artifactID>jcl-over-slf4j</artifactID> <version>${org.slf4j.version}</version> <scope>runtime</scope> </dependency> <dependency> <groupID>org.slf4j</groupID> <artifactID>slf4j-log4j12</artifactID> <version>${org.slf4j.version}</version> <scope>runtime</scope> </dependency> <dependency> <groupID>log4j</groupID> <artifactID>log4j</artifactID> <version>1.2.15</version> <exclusions> <exclusion> <groupID>javax.mail</groupID> <artifactID>mail</artifactID> </exclusion> <exclusion> <groupID>javax.jms</groupID> <artifactID>jms</artifactID> </exclusion> <exclusion> <groupID>com.sun.jdmk</groupID> <artifactID>jmxtools</artifactID> </exclusion> <exclusion> <groupID>com.sun.jmx</groupID> <artifactID>jmxri</artifactID> </exclusion> </exclusions> <scope>runtime</scope> </dependency> <!-- URL Rewrite --> <dependency> <groupID>org.tuckey</groupID> <artifactID>urlrewritefilter</artifactID> <version>3.1.0</version> <scope>runtime</scope> </dependency> <!-- Servlet --> <dependency> <groupID>javax.servlet</groupID> <artifactID>servlet-API</artifactID> <version>2.5</version> <scope>provIDed</scope> </dependency> <dependency> <groupID>javax.servlet.Jsp</groupID> <artifactID>Jsp-API</artifactID> <version>2.1</version> <scope>provIDed</scope> </dependency> <dependency> <groupID>javax.servlet</groupID> <artifactID>Jstl</artifactID> <version>1.2</version> </dependency> <!-- Test --> <dependency> <groupID>junit</groupID> <artifactID>junit</artifactID> <version>4.7</version> <scope>test</scope> </dependency> </dependencIEs> <build> <plugins> <plugin> <groupID>org.apache.maven.plugins</groupID> <artifactID>maven-compiler-plugin</artifactID> <configuration> <source>1.5</source> <target>1.5</target> </configuration> </plugin> <plugin> <groupID>org.apache.maven.plugins</groupID> <artifactID>maven-dependency-plugin</artifactID> <executions> <execution> <ID>install</ID> <phase>install</phase> <goals> <goal>sources</goal> </goals> </execution> </executions> </plugin> </plugins> </build></project>
SpringSource工具套件
版本:2.3.3.M1
建立编号:201005180035
*** 作系统:windows Vista HP SP1最佳答案它只是Spring WEB 3.0.2构建的一部分.
您可以在SpringSource的存储库中自己查看它:
http://www.springsource.com/repository/app/search?query=ResourceHttpMessageConverter 总结
以上是内存溢出为你收集整理的蚀-未找到类’org.springframework.http.converter.ResourceHttpMessageConverter’-如何纠正? 全部内容,希望文章能够帮你解决蚀-未找到类’org.springframework.http.converter.ResourceHttpMessageConverter’-如何纠正? 所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)