-
Bug
-
Resolution: Done
-
Major
-
1.3.0.Beta2
-
None
current impl of jmsItemReader, jmsItemWriter requires JMS 2.0. But some lib/framework supports JMS 1.1, and when work with jmsItemReader, jmsItemWriter, will cause errors like the following:
Unable to find source-code formatter for language: text. Available languages are: actionscript, ada, applescript, bash, c, c#, c++, cpp, css, erlang, go, groovy, haskell, html, java, javascript, js, json, lua, none, nyan, objc, perl, php, python, r, rainbow, ruby, scala, sh, sql, swift, visualbasic, xml, yaml
java.lang.AbstractMethodError: org.apache.qpid.jms.JmsConnection.createSession()Ljavax/jms/Session; at org.jberet.support.io.JmsItemReaderWriterBase.open(JmsItemReaderWriterBase.java:122) at org.jberet.support.io.JmsItemWriter.open(JmsItemWriter.java:53) at org.jberet.runtime.runner.ChunkRunner.run(ChunkRunner.java:192) at org.jberet.runtime.runner.StepExecutionRunner.runBatchletOrChunk(StepExecutionRunner.java:226) at org.jberet.runtime.runner.StepExecutionRunner.run(StepExecutionRunner.java:147) at org.jberet.runtime.runner.CompositeExecutionRunner.runStep(CompositeExecutionRunner.java:164) at org.jberet.runtime.runner.CompositeExecutionRunner.runFromHeadOrRestartPoint(CompositeExecutionRunner.java:88) at org.jberet.runtime.runner.JobExecutionRunner.run(JobExecutionRunner.java:60) at org.jberet.spi.JobExecutor$1.run(JobExecutor.java:99) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:745)
this is because JMS 1.1 has javax.jms.Connection#createSession(boolean, int), and JMS 2.0 added two overloaded variations:
javax.jms.Connection#createSession()
javax.jms.Connection#createSession(int)
Currently jmsItemReader, jmsItemWriter call javax.jms.Connection#createSession(),which will fail with JMS 1.1 client, like qpid-jms-client