您的位置:程序门 -> java -> web 开发



我在做定时器时出现了下面的问题,如果解决。


[收藏此页] [打印本页]选择字色:背景色:字体:[][][]


我在做定时器时出现了下面的问题,如果解决。
发表于:2007-06-22 11:18:54 楼主
我这里有这样一个类
public   class   schedulejob   implements   serializable
{
      方法是;
              public   void   insertschedulearrange()
              {
                //方法里的代码没有问题
                }
}
配置文件是
          <bean     id   = "scheduleaction4 "  
                class   = "com.smartdot.javaoa.modules.schedule.action.schedulejob "   >  
</bean>
  <bean     id   = "comparejob4 "  
                class   = "org.springframework.scheduling.quartz.methodinvokingjobdetailfactorybean "   >  
                  <property     name   = "targetobject "     ref   = "scheduleaction4 "       />  
                  <property     name   = "targetmethod "     value   = "insertschedulearrange "       />  
                  <property     name   = "concurrent "     value   = "false "       />  
          </bean   >    

          <bean     id   = "comparetrigger4 "  
                class   = "org.springframework.scheduling.quartz.crontriggerbean "   >  
                  <property     name   = "jobdetail "     ref   = "comparejob4 "       />  
                  <property     name   = "cronexpression "   >                            
                          <value>   0   *   9   *   *   ?   </value   >  
                  </property   >  
          </bean>  
 
  <bean     id   = "schedulerfactory "  
                class   = "org.springframework.scheduling.quartz.schedulerfactorybean "   >  
                  <property     name   = "triggers "   >  
                          <list   >                                          
                                          <ref     local   = "comparetrigger4 "       />  
                          </list   >  
                  </property   >  
          </bean   >  
这样写报错   是:
          couldn 't   store   job:   org.springframework.scheduling.quartz.methodinvokingjobdetailfactorybean   [see   nested   exception:   java.io.notserializableexception:   org.springframework.scheduling.quartz.methodinvokingjobdetailfactorybean


caused   by:   org.springframework.beans.factory.beancreationexception:   error   creating   bean   with   name   'schedulerfactory '   defined   in   class   path   resource   [spring/news_context.xml]:   initialization   of   bean   failed;   nested   exception   is   org.quartz.jobpersistenceexception:   couldn 't   store   job:   org.springframework.scheduling.quartz.methodinvokingjobdetailfactorybean


急急急急急急急。。。。谢谢了


快速检索

最新资讯
热门点击