PDA

View Full Version : No setter found for property


mark.smithson
Sep 8th, 2005, 05:43 AM
I am getting this validation error

No setter found for property 'cronExpression' in class 'org.springframework.scheduling.quartz.CronTrigger Bean'

For this bean definition:

<bean id="sendMailingsJob" class="org.springframework.scheduling.quartz.CronTriggerB ean">
<property name="jobDetail">
<bean class="org.springframework.scheduling.quartz.MethodInvoki ngJobDetailFactoryBean">
<property name="targetObject"><ref bean="mailingSender" /></property>
<property name="targetMethod"><value>sendPendingMailsBatch</value></property>
<property name="concurrent"><value>false</value></property>
</bean>
</property>
<property name="cronExpression">
<!-- run once an hour at quarter past the hour -->
<value>0 15 * * * ?</value>
</property>
</bean>

I have checked that org.springframework.scheduling.quartz.CronTriggerB ean does have a setCronExpression property, and this works when loaded in spring.

Can anyone suggest what is happening.

I am using Spring IDE 1.2.3 and spring 1.2.3

Torsten Juergeleit
Sep 8th, 2005, 06:36 PM
Mark,

I can second your observation.

This is due to the setter for the property "cronExpression" is not defined in "org.springframework.scheduling.quartz.CronTriggerB ean" but in it's super class "org.quartz.CronTrigger". To validate this property you have to add "quartz.jar" to the corresponding Spring project's build path.

Cheers,
Torsten

mark.smithson
Sep 9th, 2005, 02:05 AM
Thanks Torsten,

That has sorted my problems

Regards

Mark Smithson

kajh
Oct 2nd, 2005, 11:13 AM
Mark,

I can second your observation.

This is due to the setter for the property "cronExpression" is not defined in "org.springframework.scheduling.quartz.CronTriggerB ean" but in it's super class "org.quartz.CronTrigger". To validate this property you have to add "quartz.jar" to the corresponding Spring project's build path.


Thanks for posting this solution!

I had this problem on eclipse 3.2M2, eclipseide 1.2.3 and spring 1.2.4. I tried to add quarz-1.4.2.jar to the project's build path, but that didn't help. I havn't managed to reproduce this issue on eclipse 3.1.

Anyone else seen this on eclipse 3.2M2?


-Kaj :)