I have created the Spring Batch Job through My Eclipse and Schedule through Quartz and It is working fine but when i tried to run the same quartz job through command line i am getting the error as below
I have added the commons-logging-1.0.4.jar in my classpath but still i am getting the error. Please helpCode:Exception in thread "Thread-0" org.springframework.beans.factory.BeanCreationExc eption: Error creating bean with name 'org.springframework.scheduling.quartz.Sch edulerFactoryBean#0' defined in class path resource [quartz-job-launcher-context .xml]: Invocation of init method failed; nested exception is java.lang.NoClassDe fFoundError: org/apache/commons/logging/Log at org.springframework.beans.factory.support.AbstractAutowireCapableBean Factory.initializeBean(AbstractAutowireCapableBeanFactory.java:1337) at org.springframework.beans.factory.support.AbstractAutowireCapableBean Factory.doCreateBean(AbstractAutowireCapableBeanFactory.java:473) at org.springframework.beans.factory.support.AbstractAutowireCapableBean Factory$1.run(AbstractAutowireCapableBeanFactory.java:409) at java.security.AccessController.doPrivileged(Native Method) at org.springframework.beans.factory.support.AbstractAutowireCapableBean Factory.createBean(AbstractAutowireCapableBeanFactory.java:380) at org.springframework.beans.factory.support.AbstractBeanFactory$1.getOb ject(AbstractBeanFactory.java:264) at org.springframework.beans.factory.support.DefaultSingletonBeanRegistr y.getSingleton(DefaultSingletonBeanRegistry.java:221) at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBe an(AbstractBeanFactory.java:261) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean (AbstractBeanFactory.java:185) at org.springframework.beans.factory.support.AbstractBeanFactory.getBean (AbstractBeanFactory.java:164) at org.springframework.beans.factory.support.DefaultListableBeanFactory. preInstantiateSingletons(DefaultListableBeanFactory.java:423) at org.springframework.context.support.AbstractApplicationContext.finish BeanFactoryInitialization(AbstractApplicationContext.java:729) at org.springframework.context.support.AbstractApplicationContext.refres h(AbstractApplicationContext.java:381) at org.springframework.context.support.ClassPathXmlApplicationContext.<i nit>(ClassPathXmlApplicationContext.java:139) at org.springframework.context.support.ClassPathXmlApplicationContext.<i nit>(ClassPathXmlApplicationContext.java:83) at us.tn.state.trust.batch.emissions.scheduler.QuartzBatchLauncher.run(Q uartzBatchLauncher.java:99) at us.tn.state.trust.batch.emissions.scheduler.QuartzBatchLauncher.acces s$000(QuartzBatchLauncher.java:32) at us.tn.state.trust.batch.emissions.scheduler.QuartzBatchLauncher$1.run (QuartzBatchLauncher.java:76)


Reply With Quote