-
1. Re: beanIOItemWriter Invalid writer property value for key resource
cfang Nov 7, 2018 7:07 PM (in response to richardmoore)what's the complete stacktrace? It could be some IOException as the root cause when accessing the writer output file.
-
2. Re: beanIOItemWriter Invalid writer property value for key resource
richardmoore Nov 8, 2018 8:33 AM (in response to cfang)Sorry about that, I knew I should send all of it.
2018-11-07 16:21:47.091 jberet-1 RPEThirdPartyDealsScanProcessor - INFO errorFile = RPE_ThirdPartyDealsScan_Sorted_20181105_105330.err
2018-11-07 16:21:47.328 jberet-1 jberet - ERROR item-count=1000, time-limit=0, skip-limit=-1, skipCount=0, retry-limit=-1, retryCount=0
2018-11-07 16:21:47.331 jberet-1 jberet - ERROR JBERET000007: Failed to run job RPE_Daily_ThirdPartyDealsScan, processData, org.jberet.job.model.Chunk@3987edb1
javax.batch.operations.BatchRuntimeException: JBERET060000: Invalid reader or writer property value mytest.out for key resource
at org.jberet.support.io.ItemReaderWriterBase.newFileOutputStream(ItemReaderWriterBase.java:222) ~[jberet-support-1.3.0.Final.jar:?]
at org.jberet.support.io.ItemReaderWriterBase.getOutputStream(ItemReaderWriterBase.java:183) ~[jberet-support-1.3.0.Final.jar:?]
at org.jberet.support.io.BeanIOItemWriter.open(BeanIOItemWriter.java:48) ~[jberet-support-1.3.0.Final.jar:?]
at org.jberet.runtime.runner.ChunkRunner.run(ChunkRunner.java:199) [jberet-core-1.3.0.Final.jar:1.3.0.Final]
at org.jberet.runtime.runner.StepExecutionRunner.runBatchletOrChunk(StepExecutionRunner.java:225) [jberet-core-1.3.0.Final.jar:1.3.0.Final]
at org.jberet.runtime.runner.StepExecutionRunner.run(StepExecutionRunner.java:144) [jberet-core-1.3.0.Final.jar:1.3.0.Final]
at org.jberet.runtime.runner.CompositeExecutionRunner.runStep(CompositeExecutionRunner.java:164) [jberet-core-1.3.0.Final.jar:1.3.0.Final]
at org.jberet.runtime.runner.CompositeExecutionRunner.runFromHeadOrRestartPoint(CompositeExecutionRunner.java:88) [jberet-core-1.3.0.Final.jar:1.3.0.Final]
at org.jberet.runtime.runner.JobExecutionRunner.run(JobExecutionRunner.java:60) [jberet-core-1.3.0.Final.jar:1.3.0.Final]
at org.jberet.spi.JobExecutor$1.run(JobExecutor.java:99) [jberet-core-1.3.0.Final.jar:1.3.0.Final]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [?:1.8.0_121]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [?:1.8.0_121]
at java.lang.Thread.run(Thread.java:745) [?:1.8.0_121]
-
3. Re: beanIOItemWriter Invalid writer property value for key resource
cfang Nov 8, 2018 11:53 AM (in response to richardmoore)looks like the writer class is trying to get the parent directory of your output file, which returns null, because you've specified "mytest.out" for it.
jberet-support/ItemReaderWriterBase.java at master · jberet/jberet-support · GitHub
The file "mytest.out" will be created under the current working directory. As a workaround, you can include the path prefix, for example,
"./mytest.out", or "/users/abc/test/mytest.out"
-
4. Re: beanIOItemWriter Invalid writer property value for key resource
cfang Nov 8, 2018 1:55 PM (in response to cfang)This issue is tracked in JBERET-460
-
5. Re: beanIOItemWriter Invalid writer property value for key resource
cfang Dec 1, 2018 8:56 AM (in response to cfang)the fix is included in jberet-support 1.3.3.Final release (released on 2018-11-29), and jberet-support 1.4.0.Beta1 release (released on 2018-11-26).