NoSuchMethodError: org.springframework.util.Assert.noNullElements([Ljava/lan....
....
分析:
Caused by: java.lang.NoSuchMethodError: org.apache.commons.collections.SetUtils.orderedSet(Ljava/util/Set;)Ljava/util/Set;的原因是由于使用的commons-collections.jar版本太低导致的要使用3.*的才行。对于使用MyEclipse的,如果导入了commons-collections.jar 3.*的包还不行,而且没有找到其他的包的话很可能是MyEclipse自带的Liberary中包括了版本低的包而你导入了这个lib。比如MyEclipse的Hibernate的Lib中包括commons-collections.jar但是版本是2.*。Window->Preferences->Myeclipse->Project Capabilities->Hibernate从lib中删除此包即可。
附:applicationContext.xml配置 <bean name="feeTrigger" class="cn.org.msa.kwms.vo.FeeTrigger"> <property name="commonService"> <ref local="commonService" /> </property> <property name="payFeeService"> <ref bean="payFeeService" /> </property> </bean> <bean id="feeJob" class="org.springframework.scheduling.quartz.MethodInvokingJobDetailFactoryBean"> <property name="targetObject"> <ref bean="feeTrigger" /> </property> <property name="targetMethod"> <value>execute</value> </property> </bean> <bean id="triggerBean" class="org.springframework.scheduling.quartz.SimpleTriggerBean"> <!-- <bean id="triggerBean" class="org.springframework.scheduling.quartz.CronTriggerBean">--> <property name="jobDetail"> <ref bean="feeJob" /> </property> <property name="startDelay"> <value>20000</value> </property> <property name="repeatInterval"> <value>10000</value> </property> </bean> <bean id="scheduler" class="org.springframework.scheduling.quartz.SchedulerFactoryBean"> <property name="triggers"> <ref local="triggerBean" /> </property> </bean>