开发者

Convert Spring Batch from 1.1.3 to 2.0.0

开发者 https://www.devze.com 2022-12-17 16:04 出处:网络
I\'m trying 开发者_运维百科to convert Spring Batch jobs from version 1.1.3 to 2.0.0 and have gotten numerous errors.Managed to resolve most of these, but not the following:In my QuartzBatchLauncher, t

I'm trying 开发者_运维百科to convert Spring Batch jobs from version 1.1.3 to 2.0.0 and have gotten numerous errors. Managed to resolve most of these, but not the following: In my QuartzBatchLauncher, the code invokes "new ClassPathXmlApplicationContextJobFactory(bean, path, parent)" and I've had no luck discovering what is the 2.0 equivalent to this class. Appreciate any help pointing me in the right direction. Thanks.


May be, this?

ClassPathXmlApplicationContextFactory f = new ClassPathXmlApplicationContextFactory(new ClassPathResource(path));
f.setApplicationContext(parent);

JobFactory j = new ApplicationContextJobFactory(name, f);
0

精彩评论

暂无评论...
验证码 换一张
取 消