错误日志:

2014-09-24 10:50:16 [org.springframework.context.support.FileSystemXmlApplicationContext]-[INFO] Refreshing org.springframework.context.support.FileSystemXmlApplicationContext@19b8e059: startup date [Wed Sep 24 10:50:16 CST 2014]; root of context hierarchy
2014-09-24 10:50:16 [org.springframework.beans.factory.xml.XmlBeanDefinitionReader]-[INFO] Loading XML bean definitions from URL [file:/D:/Worksapce/chongqing/cqetlserver1/target/classes/conf/spring/applicationContext.xml]
2014-09-24 10:50:16 [org.springframework.beans.factory.support.DefaultListableBeanFactory]-[INFO] Overriding bean definition for bean 'cacheManager': replacing [Generic bean: class [com.asiainfo.cache.CacheManager]; scope=singleton; abstract=false; lazyInit=false; autowireMode=0; dependencyCheck=0; autowireCandidate=true; primary=false; factoryBeanName=null; factoryMethodName=null; initMethodName=null; destroyMethodName=null; defined in file [D:\Worksapce\chongqing\cqetlserver1\target\classes\com\asiainfo\cache\CacheManager.class]] with [Generic bean: class [org.springframework.cache.support.SimpleCacheManager]; scope=; abstract=false; lazyInit=false; autowireMode=0; dependencyCheck=0; autowireCandidate=true; primary=false; factoryBeanName=null; factoryMethodName=null; initMethodName=null; destroyMethodName=null; defined in URL [file:/D:/Worksapce/chongqing/cqetlserver1/target/classes/conf/spring/applicationContext.xml]]
2014-09-24 10:50:16 [org.springframework.beans.factory.xml.XmlBeanDefinitionReader]-[INFO] Loading XML bean definitions from URL [file:/D:/Worksapce/chongqing/cqetlserver1/target/classes/conf/spring/rabitmq.xml]
2014-09-24 10:50:16 [org.springframework.context.support.PropertySourcesPlaceholderConfigurer]-[INFO] Loading properties file from file [D:\Worksapce\chongqing\cqetlserver1\target\classes\conf\rabbitmq.properties]
2014-09-24 10:50:16 [org.springframework.context.support.PropertySourcesPlaceholderConfigurer]-[INFO] Loading properties file from file [D:\Worksapce\chongqing\cqetlserver1\target\classes\conf\system.properties]
2014-09-24 10:50:17 [org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor]-[INFO] Initializing ExecutorService
2014-09-24 10:50:17 [org.springframework.context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker]-[INFO] Bean 'executor' of type [class org.springframework.scheduling.config.TaskExecutorFactoryBean] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2014-09-24 10:50:17 [org.springframework.context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker]-[INFO] Bean 'executor' of type [class org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2014-09-24 10:50:17 [org.springframework.scheduling.concurrent.ThreadPoolTaskScheduler]-[INFO] Initializing ExecutorService 'scheduler'
2014-09-24 10:50:17 [org.springframework.context.support.PostProcessorRegistrationDelegate$BeanPostProcessorChecker]-[INFO] Bean 'scheduler' of type [class org.springframework.scheduling.concurrent.ThreadPoolTaskScheduler] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
init cache.......
Sep 24, 2014 10:50:17 AM com.asiainfo.dao.impl.SuperDao queryForList
INFO: select FUNC_TYPE,DLL_DEF,DLL_FUNC FROM proc_func_def_java
2014-09-24 10:50:17 [com.mchange.v2.log.MLog]-[INFO] MLog clients using log4j logging.
2014-09-24 10:50:17 [com.mchange.v2.c3p0.C3P0Registry]-[INFO] Initializing c3p0-0.9.1.1 [built 15-March-2007 01:32:31; debug? true; trace: 10]
2014-09-24 10:50:17 [com.mchange.v2.c3p0.impl.AbstractPoolBackedDataSource]-[INFO] Initializing c3p0 pool... com.mchange.v2.c3p0.ComboPooledDataSource [ acquireIncrement -> 3, acquireRetryAttempts -> 30, acquireRetryDelay -> 1000, autoCommitOnClose -> false, automaticTestTable -> null, breakAfterAcquireFailure -> false, checkoutTimeout -> 0, connectionCustomizerClassName -> null, connectionTesterClassName -> com.mchange.v2.c3p0.impl.DefaultConnectionTester, dataSourceName -> 1hgez9d9419xsp1gq3x0c7|6c5b675e, debugUnreturnedConnectionStackTraces -> false, description -> null, driverClass -> com.mysql.jdbc.Driver, factoryClassLocation -> null, forceIgnoreUnresolvedTransactions -> false, identityToken -> 1hgez9d9419xsp1gq3x0c7|6c5b675e, idleConnectionTestPeriod -> 0, initialPoolSize -> 1, jdbcUrl -> jdbc:mysql://localhost:3306/md?useUnicode=true&characterEncoding=utf8&mysqlEncoding=utf8, lastAcquisitionFailureDefaultUser -> null, maxAdministrativeTaskTime -> 0, maxConnectionAge -> 0, maxIdleTime -> 60, maxIdleTimeExcessConnections -> 0, maxPoolSize -> 2, maxStatements -> 0, maxStatementsPerConnection -> 0, minPoolSize -> 1, numHelperThreads -> 3, numThreadsAwaitingCheckoutDefaultUser -> 0, preferredTestQuery -> null, properties -> {user=******, password=******}, propertyCycle -> 0, testConnectionOnCheckin -> false, testConnectionOnCheckout -> false, unreturnedConnectionTimeout -> 0, usesTraditionalReflectiveProxies -> false ]
Sep 24, 2014 10:50:17 AM com.asiainfo.dao.impl.SuperDao queryForList
INFO: select * from data_trans_ftpserv
2014-09-24 10:50:17 [org.springframework.scheduling.concurrent.ThreadPoolTaskScheduler]-[INFO] Shutting down ExecutorService 'scheduler'
2014-09-24 10:50:17 [org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor]-[INFO] Shutting down ExecutorService
Exception in thread "main" java.lang.ExceptionInInitializerError
at com.asiainfo.main.SpringApplication.getInstance(SpringApplication.java:13)
at com.asiainfo.main.Main.main(Main.java:7)
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataTransTask': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private com.asiainfo.service.impl.DataTransServiceImpl com.asiainfo.proc.DataTransTask.dataTransService; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataTransServiceImpl': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private com.asiainfo.dao.impl.DataTransDaoImpl com.asiainfo.service.impl.DataTransServiceImpl.dataTranDao; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [com.asiainfo.dao.impl.DataTransDaoImpl] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:292)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1185)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:537)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:475)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:302)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:228)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:298)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:703)
at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:760)
at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:482)
at org.springframework.context.support.FileSystemXmlApplicationContext.<init>(FileSystemXmlApplicationContext.java:140)
at org.springframework.context.support.FileSystemXmlApplicationContext.<init>(FileSystemXmlApplicationContext.java:94)
at com.asiainfo.main.SpringApplication$LOAD.<clinit>(SpringApplication.java:9)
... 2 more
Caused by: org.springframework.beans.factory.BeanCreationException: Could not autowire field: private com.asiainfo.service.impl.DataTransServiceImpl com.asiainfo.proc.DataTransTask.dataTransService; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataTransServiceImpl': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private com.asiainfo.dao.impl.DataTransDaoImpl com.asiainfo.service.impl.DataTransServiceImpl.dataTranDao; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [com.asiainfo.dao.impl.DataTransDaoImpl] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:508)
at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:87)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:289)
... 15 more
Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'dataTransServiceImpl': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private com.asiainfo.dao.impl.DataTransDaoImpl com.asiainfo.service.impl.DataTransServiceImpl.dataTranDao; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [com.asiainfo.dao.impl.DataTransDaoImpl] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:292)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1185)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:537)
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:475)
at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:302)
at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:228)
at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:298)
at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.findAutowireCandidates(DefaultListableBeanFactory.java:1017)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:960)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:858)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:480)
... 17 more
Caused by: org.springframework.beans.factory.BeanCreationException: Could not autowire field: private com.asiainfo.dao.impl.DataTransDaoImpl com.asiainfo.service.impl.DataTransServiceImpl.dataTranDao; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [com.asiainfo.dao.impl.DataTransDaoImpl] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:508)
at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:87)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:289)
... 28 more
Caused by: org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [com.asiainfo.dao.impl.DataTransDaoImpl] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}
at org.springframework.beans.factory.support.DefaultListableBeanFactory.raiseNoSuchBeanDefinitionException(DefaultListableBeanFactory.java:1103)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:963)
at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:858)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:480)
... 30 more

找到了这里:

Caused by: org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [com.asiainfo.dao.impl.DataTransDaoImpl] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency.

原来只是这类没有添加注解,疯了!!!!!!!!!!

import java.util.List;
import java.util.Map; public class DataTransDaoImpl extends SuperDao implements DataTransDao {
// ……
}

加上@Repository,解决,这样的错误除了粗心还能再粗心点么。。。。。。。。。。。

import java.util.List;
import java.util.Map; @Repository
public class DataTransDaoImpl extends SuperDao implements DataTransDao {
// ……
}

  

  

Spring工程报错的更多相关文章

  1. 解决eclipse spring配置报错:cvc-elt.1: Cannot find the declaration of element

    解决eclipse spring配置报错:cvc-elt.1: Cannot find the declaration of element 'beans'.Referenced file conta ...

  2. Spring Boot报错 MultipartException The temporary upload...

    Spring Boot报错:尤其是在处理Ribbon这类接口调用型的负载均衡组件,常见问题 ERROR o.a.c.c.C.[.[.[.[dispatcherServlet] - Servlet.se ...

  3. android studio java工程 报错

    作者:韩梦飞沙 Author:han_meng_fei_sha 邮箱:313134555@qq.com E-mail: 313134555 @qq.com  android studio java工程 ...

  4. 导入android sdk samples工程报错"did you mean to use @+id instead of @+android:id?"

    导入“D:\adt-bundle-windows-x86_64-20140702\sdk\samples\android-15”中的工程报错 did you mean to use @+id inst ...

  5. Spring Boot 报错记录

    Spring Boot 报错记录 由于新建的项目没有配置数据库连接启动报错,可以通过取消自动数据源自动配置来解决 解决方案1: @SpringBootApplication(exclude = Dat ...

  6. Spring.之.报错:Caused by: java.lang.IllegalArgumentException: No Spring Session store is configured: set the 'spring.session.store-type' property

    Spring.之.报错 No Spring Session store is configured springboot在启动的时候报如下错误: Error starting ApplicationC ...

  7. 通过struts2-spring-plugin集成Struts2和Spring,报错:ClassNotFound:*Interceptor.......

    集成Struts2和Spring的时候,出现错误,ClassNotFound: *interceptor,之所以是*interceptor是因为报了好多个这样的错误,而且类名都不一样. 集成方法是通过 ...

  8. IDEA中创建父子工程与maven打包Springboot聚合工程报错程序包不存在问题处理

    公司新项目需使用java技术栈,便使用IDEA搭建了一个多SpringBoot项目的聚合工程,因为初次使用,遇到了很多问题,maven打包时各种报错,在网上查了好多终于解决了,为巩固记忆,特作此记录. ...

  9. Eclipse创建Maven工程报错

    问题 用Eclipse创建maven工程的时候,总是会报错,例如提示: Unable to create project from archetype [org.apache.maven.archet ...

随机推荐

  1. 什么是响应式设计?响应式设计的基本原理是什么?如何兼容低版本的 IE?

    响应式网站设计(Responsive Web design)的理念是:集中创建页面的图片排版大小,可以智能地根据用户行为以及 使用的设备环境(系统平台.屏幕尺寸.屏幕定向等)进行相对应的布局,无论用户 ...

  2. Python--day48--今日内容

  3. P1007 N钱M鸡问题

    题目描述 已知公鸡 \(5\) 元钱一只,母鸡 \(3\) 元钱一只,小鸡 \(3\) 只 \(1\) 元钱. 告诉你一个整数 \(n(1 \le n \le 1000)\) ,你现在要花 \(n\) ...

  4. GetDc函数与GetWindowDC函数的区别

    GetDc函数:用于获得hWnd参数所指定窗口的客户区域的一个设备环境 GetWindowDC函数:返回hWnd参数所指定的窗口的设备环境. 获得的设备环境覆盖了整个窗口(包括非客户区),例如标题栏. ...

  5. 【土旦】vue 解决ios H5底部输入框 获取焦点时弹出虚拟键盘挡住输入框 以及监听键盘收起事件

    问题描述 im聊天H5页面,在iOS系统下,inpu获取焦点弹出系统虚拟键盘时,会出现挡住input的情况,十分影响用户体验. bug图 解决方法: html: <input type=&quo ...

  6. koa2入门--03.koa中间件以及中间件执行流程

    //中间件:先访问app的中间件的执行顺序类似嵌套函数,由外到内,再由内到外 //应用级中间件 const koa = require('koa'); var router = require('ko ...

  7. ASP.NET MVC API以及.Core API进行安全拦截和API请求频率控制

    安全拦截思路: 根据IP以及请求次数,该IP超过规定请求次数,就有很大可能是非正常用户进行的请求(比如WEB攻击),这时候进行拦截,拦截成功会提示:The allowed number of requ ...

  8. axure公式的使用和局部变量简介

    什么时候有公式?当前面是值的时候后面都可以用公式 公式怎么用?1.公式里直接写入字符串 2.变量([变量])加上字符串 3.[[]]里面运算 外面字符串 两个中括号里的变量就可以计算或者显示默认值而不 ...

  9. 记一次linux磁盘清理 - 已经删除的文件占用了大量磁盘空间

    今天开发环境磁盘占满了,导致开发环境上的 nginx .redis 等组件总是报异常. 跳到系统根目录下 cd / 检查磁盘占用情况 df -h 哇,40G硬盘全用完了.看看是哪些文件占了那么多内存. ...

  10. Java第一次创建对象速度比之后慢的原因

    类的对象在第一次创建的时候,Java虚拟机(JVM)首先检查是否所要加载的类对应的Class对象是否已经加载.如果没有加载,JVM就会根据类名查找.class文件,并将其Class对象载入.一般某个类 ...