org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find class [com.my.service.ProductService] for bean with name 'productService' defi报错解决方法
javaweb项目报错org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find class [XXX]
最近在webService服务,在CXF方面自己写了一个测试的小服务程序,发布到本地主机上边,程序大致框架是通过spring框架对数据库进行连接从而操作数据库,有一个接口,一个实现类,一个实体类,接口上边有WebSerivce注解,实现类通过在cxf.xml文件中进行配置,在类中用的是注解方法来操作事务。在发布程序的过程中出现来标题相关的内容,原来的错误是找不到ContextLoaderListener,通过重启服务器,重新builder一下,最终这个错误消失 ,接下来就是下边的错误,搞了半天,各种百度,最终在一个博客上,看到关于编译JDK和系统的jdk版本不一样等说法,自己就去慢慢尝试,果然搞定
从别的地方导入一个项目的时候,经常会遇到eclipse/Myeclipse报Description Resource Path Location Type Java compiler level does not match the version of the installed Java project facet.出现这个问题的原因是因为,eclipse/myeclipse的jdk编译版本与出现问题的项目JDK编译版本不一致所导致!
先设置好jdk,需要确定 项目,eclipse/myeclipse,系统 用的是同一个版本的JDK,我系统中安装的JDK是1.7,所以我把eclipse的jdk成1.7
进入 windows—proferences—java–compiler设置编译出来的文件使用的格式是 1.7版本的 (设置成多少都行,只要兼容,并且与你项目的编译版本一直就可以,我这里统一设置成1.7)
进入项目–properties—java Compiler 把项目编译版本也设置成 1.7
进入项目–properties—Myeclipse—project Facets设置java文件的版本为 1.7
完成以上所有步骤,重启服务,即可解决!别忘记点赞
org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find class [com.my.service.ProductService] for bean with name 'productService' defi报错解决方法的更多相关文章
- org.springframework.beans.factory.BeanCreationException: Could not autowire field org.springframework.beans.factory.CannotLoadBeanClassException: Error loading class [com.xxxx.service.sys.impl.ProcEn
七月 01, 2019 4:34:20 下午 org.apache.catalina.core.StandardContext listenerStart .....org.springframewo ...
- 报错org.springframework.beans.factory.CannotLoadBeanClassException: Error loading class [org.mybatis.spring.SqlSessionFactoryBean]
超级大坑 org.springframework.beans.factory.CannotLoadBeanClassException: Error loading class [org.mybati ...
- 异常:Struts:org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find BasicDataSource
org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find class [org.apache.common ...
- Spring:org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find class
很长时间没有使用Spring,Hibernate,Struts2等一些框架了,现在使用起来还是有点陌生,今天刚弄就在Tomcat在启动的时候是报的这个错误: org.springframework.b ...
- spring问题org.springframework.beans.factory.CannotLoadBeanClassException
1.看jdk是否配置正确 2.把MyEclipse里面的那个classes删除让他重新编译就没什么问题了,只要配置是对的 3.重新clean project
- tomcat启动错误org.springframework.beans.factory.CannotLoadBeanClassException的解决
tomcat启动时一直报这个错误,但是报错的类确实存在. 清空tomcat,更新maven项目,重配tomcat都没有解决. 最后解决办法: Eclipse环境:Project-->clean ...
- Spring报错: org.springframework.beans.factory.CannotLoadBeanClassException: Cannot find class [xxx]
如果确实没有这个类,就挨个将总项目,子项目clean,install一下,注意他们的依赖关系.
- org.springframework.beans.factory.CannotLoadBeanClassException-估计mapper出参 和 po字段不对应了
DEBUG [localhost-startStop-1] - Ignoring bean class loading failure for bean 'itemsService'org.sprin ...
- 出现org.springframework.beans.factory.NoSuchBeanDefinitionException 的解决思路
Caused by: org.springframework.beans.factory.BeanCreationException: Could not autowire field: privat ...
随机推荐
- Android 解决手机unauthorized错误
转自:http://blog.csdn.net/quicksand201/article/details/19190821 手机开发者选项中USB调试已经打开,在电脑命令行下输入adb devices ...
- DLL入口函数
BOOL APIENTRY DllMain(HINSTANCE hInst /* Library instance handle. */, DWORD reason /* Rea ...
- height:calc(100% - 40px)
在移动端开发的过程中,常常会遇到头部高度是40px,而内容页是除去头部,占满视窗的整个高度,有时候是用js来处理,现在用css的calc是非常方便的: .container{ height: calc ...
- JavaIo编程基础复习
什么是Io io是指Input和Output,指输入和输出 Input是指外部读入数据到内存,例如读取一个文件,或者从网络中读取 Output是指把内存中的数据输出到外部,例如写文件,输出到网络 什么 ...
- (转)OpenGL混合的基本知识
今天介绍关于OpenGL混合的基本知识.混合是一种常用的技巧,通常可以用来实现半透明.但其实它也是十分灵活的,你可以通过不同的设置得到不同的混合结果,产生一些有趣或者奇怪的图象. 混合是什么呢?混合就 ...
- PM 项目管理
BugTracker:http://www.ifdefined.com/bugtrackernet.html PM:http://www.zentao.net/download.html 51cto: ...
- Incompatible integer to pointer conversion assigning to 'NSInteger *' (aka 'int *') from 'NSInteger' (aka 'int')
遇到这样的问题: integer to pointer conversion assigning to 'NSInteger *' (aka 'int *') from 'NSInteger' (ak ...
- Python overall structer
在C/C++/Java中,main是程序执行的起点,Python中,也有类似的运行机制,但方式却截然不同:Python使用缩进对齐组织代码的执行,所有没有缩进的代码(非函数定义和类定义),都会在载入时 ...
- python基础-第四篇-4.1内置函数
lambda表达式 lambda表达式是对简单函数的精简化表达 语法结构:函数名 = lambda:运算表达式 def f1(a): a = a + 1 return a ret = f1(1) pr ...
- java基础02
使用 myeclipse写第一个java程序 之后 右键 点击 src 创建 Class /** * package:包的声明! * 代表我们当前的java源文件在项目中的位置! * 必须位于除了 ...